格式修改

This commit is contained in:
2026-08-05 10:35:07 +08:00
parent 81c9c92f5d
commit 496fc58a90
241 changed files with 5600 additions and 2088 deletions
@@ -13,11 +13,8 @@ import java.security.MessageDigest;
*/
@Component
public class InternalServiceTokenGuard {
private final String expectedToken;
public InternalServiceTokenGuard(@Value("${baiyue.security.internal-service-token:}") String expectedToken) {
this.expectedToken = expectedToken;
}
@Value("${baiyue.security.internal-service-token:}")
private String expectedToken;
public void verify(String actualToken) {
if (expectedToken == null || expectedToken.isBlank()) {
@@ -1,5 +1,7 @@
package com.baiyue.eventbridge.service;
import jakarta.annotation.Resource;
import com.baiyue.common.event.EventEnvelope;
import com.baiyue.common.event.EventPayloadCanonicalizer;
import com.baiyue.common.event.EventPayloadHash;
@@ -19,16 +21,12 @@ import java.time.LocalDateTime;
*/
@Service
public class EventInboxService {
private final InboxStore inboxStore;
private final ObjectMapper objectMapper;
private final String localRegion;
public EventInboxService(InboxStore inboxStore, ObjectMapper objectMapper,
@Value("${baiyue.region:CN}") String localRegion) {
this.inboxStore = inboxStore;
this.objectMapper = objectMapper;
this.localRegion = localRegion;
}
@Resource
private InboxStore inboxStore;
@Resource
private ObjectMapper objectMapper;
@Value("${baiyue.region:CN}")
private String localRegion;
@Transactional
public EventReceiveResult receive(EventEnvelope envelope) {