"Golang_CSClient/4.0" is used when hitting the store meta/resources endpoint

Bug #1913754 reported by Guillermo Gonzalez
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Canonical Juju
Fix Released
Medium
Simon Richardson

Bug Description

While testing the compat API in charmhub we spotted different User-Agents being used from the same "client", e.g: Golang_CSClient/4.0, Juju/3.0-beta1.

We believe the same UA should be used.

I tracked the CSClient string to: https://github.com/juju/charmrepo/blob/af3d6b52f7de3768ec8b05964e42744857942352/csclient/csclient.go#L41

the access log from that request is:

10.172.66.2 - - [29/Jan/2021:14:43:49 +0000] "GET /charms/v5/postgresql/meta/resources?channel=stable HTTP/1.1" 200 191 "-" "Golang_CSClient/4.0"

to reproduce:

$ juju charm-resources postgresql

We are using: charmstore-url=https://api.staging.charmhub.io/charms, which we believe is not required to reproduce.

Changed in juju:
milestone: none → 2.9-rc6
importance: Undecided → High
status: New → Triaged
Revision history for this message
Maximiliano Bertacchini (maxiberta) wrote :

Also, `juju deploy cs:postgresql` produces these logs:

"GET /charms/v5/postgresql/meta/any?include=id&include=supported-series&include=published HTTP/1.1" 200 273 "-" "Golang_CSClient/4.0"
"GET /charms/v5/postgresql-215/archive?channel=stable HTTP/1.1" 302 887 "-" "Golang_CSClient/4.0"
"GET /charms/v5/postgresql-215/meta/resources?channel=stable HTTP/1.1" 200 191 "-" "Golang_CSClient/4.0"

Revision history for this message
Heather Lanigan (hmlanigan) wrote :

Working on the juju charm-resources command for charmhub is in play for this cycle. Will take look at changing this at that time. Note: this is a day 1 thing I believe.

I would not expect `juju charm-resources postgresql` to work right now on 2.9 or 3.0-beta1 as it should query charmhub and that has not been implemented yet.

As mentioned in #1, I do expect `juju charm-resources cs:postgresql` to work and query the charmstore.

Changed in juju:
milestone: 2.9-rc6 → 3.0.0
importance: High → Medium
Changed in juju:
status: Triaged → In Progress
Revision history for this message
Simon Richardson (simonrichardson) wrote :

PR https://github.com/juju/juju/pull/12682
Additionally, ongoing work is to address the juju charm-resources command https://github.com/juju/juju/pull/12683

Changed in juju:
status: In Progress → Fix Committed
milestone: 3.0.0 → 2.9-rc7
assignee: nobody → Simon Richardson (simonrichardson)
Changed in juju:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.