Juju should report open-port failures more visibly (than just controller logs)

Bug #2009102 reported by Ben Hoyt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Triaged
Medium
Unassigned

Bug Description

I was playing with open-port on a K8s sidecar charm, and apparently K8s doesn't support the ICMP protocol (VM charms do). However, open-port didn't return a failure, and even later there was no visible sign that something was wrong, except in the controller logs:

$ juju debug-log -m controller
...
controller-0: 15:00:50 ERROR juju.worker.dependency "caas-firewaller-embedded" manifold worker returned unexpected error: cannot update service port for application "database": protocol "icmp" for service "icmp" not valid
...

So I think there are two things we could do here to improve this:

1) Have the open-port / close-port hook tools reject protocol "icmp" early if it's a K8s sidecar charm.
2) In general, have a way for Juju to report firewaller worker errors more visibly. For example, setting a short error message in application status?

As it was, it took me a while to figure out what was going on, because "kubectl get svc" didn't show any of the ports opened (because K8s rejected the ICMP port, it rejected all the ports I asked for, so no changes were made -- that's probably good though that it does it atomically).

Revision history for this message
Harry Pidcock (hpidcock) wrote :

Thanks for the report. I think it makes sense for the hook tool to error, as a means to create robust charms.

Changed in juju:
assignee: nobody → Yang Kelvin Liu (kelvin.liu)
importance: Undecided → High
milestone: none → 3.1.2
status: New → Triaged
Changed in juju:
milestone: 3.1.2 → 3.1.3
Changed in juju:
milestone: 3.1.3 → 3.1.4
Changed in juju:
milestone: 3.1.4 → 3.1.5
Changed in juju:
milestone: 3.1.5 → 3.1.6
Changed in juju:
milestone: 3.1.6 → 3.1.7
Changed in juju:
milestone: 3.1.7 → 3.1.8
Harry Pidcock (hpidcock)
Changed in juju:
assignee: Yang Kelvin Liu (kelvin.liu) → nobody
importance: High → Medium
milestone: 3.1.8 → 3.5-beta1
Changed in juju:
milestone: 3.5-beta1 → 3.5-beta2
Harry Pidcock (hpidcock)
Changed in juju:
milestone: 3.5-beta2 → 3.5.1
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.