Skip to content

Commit 1f2b397

Browse files
yiweichicolinlyguo
andauthored
feat(bridge-history): add aws s3 blob client (#1716)
Co-authored-by: yiweichi <[email protected]> Co-authored-by: colin <[email protected]> Co-authored-by: colinlyguo <[email protected]>
1 parent ae791a0 commit 1f2b397

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

bridge-history-api/internal/config/config.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ type FetcherConfig struct {
3838
BeaconNodeAPIEndpoint string `json:"BeaconNodeAPIEndpoint"`
3939
BlobScanAPIEndpoint string `json:"BlobScanAPIEndpoint"`
4040
BlockNativeAPIEndpoint string `json:"BlockNativeAPIEndpoint"`
41+
AwsS3Endpoint string `json:"AwsS3Endpoint"`
4142
}
4243

4344
// RedisConfig redis config

bridge-history-api/internal/controller/fetcher/l1_fetcher.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@ type L1MessageFetcher struct {
3939
// NewL1MessageFetcher creates a new L1MessageFetcher instance.
4040
func NewL1MessageFetcher(ctx context.Context, cfg *config.FetcherConfig, db *gorm.DB, client *ethclient.Client) (*L1MessageFetcher, error) {
4141
blobClient := blob_client.NewBlobClients()
42+
if cfg.AwsS3Endpoint != "" {
43+
blobClient.AddBlobClient(blob_client.NewAwsS3Client(cfg.AwsS3Endpoint))
44+
}
4245
if cfg.BeaconNodeAPIEndpoint != "" {
4346
beaconNodeClient, err := blob_client.NewBeaconNodeClient(cfg.BeaconNodeAPIEndpoint)
4447
if err != nil {

common/version/version.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import (
55
"runtime/debug"
66
)
77

8-
var tag = "v4.5.40"
8+
var tag = "v4.5.41"
99

1010
var commit = func() string {
1111
if info, ok := debug.ReadBuildInfo(); ok {

0 commit comments

Comments
 (0)