Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In this example I have used an identifier of PRIMARY but you can use whatever you prefer.

Note:  I included the "sslmode=disable" parameter in the Postgres connection string as I'm not running Postgres over HTTPS.

When Minio starts you should see the following line in your log: SQS ARNs: arn:minio:sqs::PRIMARY:postgresql.

...

The second command lists the events minio Minio will notify on.

When you upload a file:

...

You see a new record in the minioevents table in your Postgres database

KeyValue
py-bucket/test.txt{"Records": [{"s3": {"bucket": {"arn": "arn:aws:s3:::py-bucket", "name": "py-bucket", "ownerIdentity": {"princi
palId": "minio"}}, "object": {"key": "test.txt", "eTag": "8ddd8be4b179a529afa5f2ffae4b9858", "size": 13, "sequencer": "17552EACF7D25C
F0", "contentType": "text/plain", "userMetadata": {"content-type": "text/plain"}}, "configurationId": "Config", "s3SchemaVersion": "1
.0"}, "source": {"host": "172.17.0.1", "port": "", "userAgent": "MinIO (linux; amd64) minio-go/v7.0.31 mc/RELEASE.2022-07-24T02-25-13
Z"}, "awsRegion": "", "eventName": "s3:ObjectCreated:Put", "eventTime": "2023-04-12T12:09:16.319Z", "eventSource": "minio:s3", "event
Version": "2.0", "userIdentity": {"principalId": "minio"}, "responseElements": {"content-length": "0", "x-amz-request-id": "17552EACF
779E1C4", "x-minio-deployment-id": "689c3baf-ebc6-4df8-ae4e-a09b333ed9b3", "x-minio-origin-endpoint": "http://172.17.0.12:9000"}, "re
questParameters": {"region": "", "principalId": "minio", "sourceIPAddress": "172.17.0.1"}}]}

Note: The minioevents table will be created if it does not already exists

Links

Monitoring Bucket and Object Events