Issue
Bugreport to Postgresql: canonical/postgresql-operator#1043 (PG failed to work with s3-integrator 2/edge rev167)
Steps to reproduce
- juju deploy mysql # or postgresql
- juju deploy s3-integrator --channel 2/edge
- juju config s3-integrator endpoint="https://s3.amazonaws.com" region="us-east-1" bucket="mybucket" path="mypath"
- jujusecret=$(juju add-secret s3-integrator access-key=myaccess secret-key=mysecret)
- juju grant-secret ${jujusecret} s3-integrator
- juju config s3-integrator credentials=${jujusecret}
- juju relate s3-integrator mysql
Actual behavior
Error on MySQL side:
unit-mysql-0: 16:12:30 INFO unit.mysql/0.juju-log Listing subdirectories from S3 bucket=relation-9, path=alutay_1755180485
unit-mysql-0: 16:12:31 ERROR unit.mysql/0.juju-log Bucket relation-9 does not exist
It happens because s3-integrator returned bucket as relations-9 and not pre-configured mybucket.
Which happends because s3-lib LIBAPI=6 set bucket = relation-id here.
Expected behaviour
S3 library should NOT set bucket name by default, as it is optional.
Versions
Juju CLI: 3.6.8
Juju agent: 3.6.8
ubuntu@juju366:~$ juju status
Model Controller Cloud/Region Version SLA Timestamp
test67 lxd localhost/localhost 3.6.8 unsupported 17:13:09+02:00
App Version Status Scale Charm Channel Rev Exposed Message
mysql 8.0.41-0ubun... active 1 mysql 8.0/stable 366 no
postgresql 16.9 active 1 postgresql 16/edge 874 no
s3-new active 1 s3-integrator 2/edge 167 no
Unit Workload Agent Machine Public address Ports Message
mysql/0* active idle 1 10.176.3.183 3306,33060/tcp Primary
postgresql/0* active idle 0 10.176.3.223 5432/tcp Primary
s3-new/0* active idle 3 10.176.3.82
Machine State Address Inst id Base AZ Message
0 started 10.176.3.223 juju-cbd943-0 ubuntu@24.04 Running
1 started 10.176.3.183 juju-cbd943-1 ubuntu@22.04 Running
3 started 10.176.3.82 juju-cbd943-3 ubuntu@24.04 Running
Additional context
Proposal: change the presidency order in s3-integrator channel 2/edge.
Use requester-bucket value IF no bucket set in s3-charm-config only.
It will keep compatibility with old behavior, allows requester charm request default bucket name (e.g. workdpress charm may request wordpress bucket by default) and Juju Admins can overwrite the request using s3-integrator config bucket='wordpress-test-bucket'.
If bucket is empty in relation and config, either:
- return no bucket in relation => requester charm decide on name
- continue returning relation-$id like now
P.S. bucket name in relation sets by requestor and not insistor ;-)
Issue
Bugreport to Postgresql: canonical/postgresql-operator#1043 (PG failed to work with s3-integrator 2/edge rev167)
Steps to reproduce
Actual behavior
Error on MySQL side:
It happens because s3-integrator returned bucket as
relations-9and not pre-configuredmybucket.Which happends because s3-lib LIBAPI=6 set bucket = relation-id here.
Expected behaviour
S3 library should NOT set bucket name by default, as it is optional.
Versions
Juju CLI: 3.6.8
Juju agent: 3.6.8
Additional context
Proposal: change the presidency order in s3-integrator channel 2/edge.
Use requester-bucket value IF no bucket set in s3-charm-config only.
It will keep compatibility with old behavior, allows requester charm request default bucket name (e.g. workdpress charm may request
wordpressbucket by default) and Juju Admins can overwrite the request using s3-integrator config bucket='wordpress-test-bucket'.If bucket is empty in relation and config, either:
P.S. bucket name in relation sets by
requestorand notinsistor;-)