-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
S3 Peer UI #668
S3 Peer UI #668
Conversation
154c216
to
02ca098
Compare
flow/connectors/s3/s3.go
Outdated
@@ -85,6 +93,48 @@ func (c *S3Connector) Close() error { | |||
return nil | |||
} | |||
|
|||
func ValidCheck(s3Client *s3.S3, bucketUrl string, metadataDB *metadataStore.PostgresMetadataStore) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [golangci] reported by reviewdog 🐶
ST1003: func parameter bucketUrl should be bucketURL (stylecheck)
fa11e9f
to
44ab4c4
Compare
70163ff
to
afdef01
Compare
flow/connectors/s3/s3.go
Outdated
return fmt.Errorf("failed to list buckets: %w", listErr) | ||
} | ||
|
||
reader := strings.NewReader("hello world") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
put something like a timestamp string
flow/connectors/s3/s3.go
Outdated
bucketName := aws.String(bucketPrefix.Bucket) | ||
_, putErr := s3Client.PutObject(&s3.PutObjectInput{ | ||
Bucket: bucketName, | ||
Key: aws.String("peerdb_check"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make this a const in the file and call it __peerdb_check
flow/connectors/s3/s3.go
Outdated
"github.com/aws/aws-sdk-go/service/s3" | ||
log "github.com/sirupsen/logrus" | ||
) | ||
|
||
const ( | ||
CHECK_OBJECT_KEY = "peerdb_check" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚫 [golangci] reported by reviewdog 🐶
ST1003: should not use ALL_CAPS in Go names; use CamelCase instead (stylecheck)
fa323e6
to
b1db091
Compare
b1db091
to
4b831cd
Compare
metadataDb: { | ||
host: '', | ||
port: 5432, | ||
user: 'postgres', | ||
password: '', | ||
database: 'postgres', | ||
transactionSnapshot: '', | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't expose metadata db to the user, just use catalog.
Region
andRole ARN
fields will not be shown as they have fixed values for GCS