-
Notifications
You must be signed in to change notification settings - Fork 121
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
docs: clarify distinction between maintenance and waiting status #1148
Conversation
I think this wording is definitely much better and it's clear on the meaning that the Juju team is attaching to these terms. Two thoughts:
It's fine if we really want |
Hmm, yeah, thanks Tony -- I think we need more thought here. The Juju docs (and as Tony shows, existing charm usage) is definitely not in line with @jameinel's comment. In addition to the ones Tony linked, more here: https://juju.is/docs/juju/status, "waiting" is defined as "The charm is alive and well, and is waiting for some event to occur. No human intervention required." -- nothing to do with integrations/relations. I think it's partly the name that's confusing -- "waiting" is so nice and simple and the word does really mean "waiting for some event to occur". I'd like to hear @tmihoc's thoughts on the docs side of things, but I've also put this as my list to discuss with the Juju team next Tuesday. |
💯 |
We need to sit down (maybe 20 minutes on a video call or in Madrid) with Ian, John, Tony, Dora, me, and come to consensus on this. It seems there's a bit of discrepancy in how the Juju team think about this and what our docs say:
Update: I've put this on our list to discuss in Madrid. |
We met today in Madrid, and the decision was to use "John's take" that Waiting is when the charm is waiting for an application it's related to, and Maintenance is when the charm is itself doing something. We'll change the wording of all places to be consistent (Juju source, Ops source / reference docs, Juju doc, Juju SDK doc -- maybe the latter can link to the Juju doc). Something like this:
In addition, add to Active something like "If the unit or application is operational but something (like high availability) is in a degraded state, set Active with an appropriate message." |
I've updated the PR title to match our conventional commit settings. |
In case it's of use, these are the docs I wrote for Scenario (before we decided to implement a copy-docstring-from-ops approach instead): unknown: """The unit status is unknown.
A unit-agent has finished calling install, config-changed, and start, but the
charm has not called status-set yet.
This status is read-only; trying to set unit or application status to ``UnknownStatus`` will raise
:class:`ModelError`.
""" error: """The unit status is error.
The unit-agent has encountered an error (the application or unit requires
human intervention in order to operate correctly).
This status is read-only; trying to set unit or application status to ``ErrorStatus`` will raise
:class:`ModelError`.
""" active: """The unit/app is ready.
Use the :attr:`message` to provide details when the unit/app is operational
but in a degraded state (such as lacking high availability).
""" blocked: """The unit/app requires manual intervention.
An admin has to manually intervene to unblock the unit/app and let it proceed.
""" maintenance: """The unit/app is performing maintenance tasks.
The unit/app is performing an operation such as ``apt install`` or waiting for
something under its control, such as ``pebble-ready`` or an ``exec``
operation in the workload container.
In constrast to :class:`WaitingStatus`, ``MaintenanceStatus`` reflects
activity on this unit or charm, not on peers or related units.
""" waiting: """The unit/app is waiting on an integration.
The unit/app is waiting on a charm with which it is integrated, such as
waiting for an integrated database charm to provide credentials.
In contrast to :class:`MaintenanceStatus`, ``WaitingStatus`` reflects
activity on integrated units, not on this unit or charm.
""" |
I've updated this based on my comment above (which was based on our discussion in Madrid). |
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.
LGTM!
I also made some clarifications to https://juju.is/docs/juju/status, and it looks like Dora already updated https://juju.is/docs/sdk/status. So I think we're all in sync now. |
Per discussion with @jameinel,
Maintenance
means "I'm not ready because of work that I need to do", versusWaiting
, which is "I'm not ready because of work that other things need to do".Also clarify when you should use a message for Active, and make wording a bit more consistent between docstrings.