Skip to content

Commit 21c0672

Browse files
authored
Merge pull request #242 from lsst-dm/tickets/DM-48010
DM-48010: Add directions to playbook for Science Pipelines quick-builds
2 parents 7dd8cf7 + 0b0c977 commit 21c0672

File tree

1 file changed

+66
-46
lines changed

1 file changed

+66
-46
lines changed

doc/playbook.rst

Lines changed: 66 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,21 @@ Containers
2222
==========
2323

2424
The service consists of two containers.
25-
The first is a base container with the Science Pipelines "stack" code and networking utilities.
26-
The second is a service container made from the base that has the Prompt Processing service code.
25+
The first is a **base container** with the Science Pipelines "stack" code and networking utilities.
26+
The second is a **service container** made from the base that has the Prompt Processing service code.
2727
All containers are managed by `GitHub Container Registry <https://github.com/orgs/lsst-dm/packages?repo_name=prompt_processing>`_ and are built using GitHub Actions.
2828

2929
To build the base container:
3030

3131
* If there are changes to the container, push them to a branch, then open a PR.
32-
The container should be built automatically.
33-
* If there are no changes (typically because you want to use an updated Science Pipelines container), go to the repository's `Actions tab <https://github.com/lsst-dm/prompt_processing/actions/workflows/build-base.yml>`_ and select "Run workflow".
34-
From the dropdown, select the branch whose container definition will be used, and the label of the Science Pipelines container.
35-
* New containers built from ``main`` are tagged with the corresponding Science Pipelines release (plus ``w_latest`` or ``d_latest`` if the release was requested by that name).
32+
This will build the container automatically.
33+
* If there are no changes (typically because you want to use an updated Science Pipelines container), go to the repository's `Actions tab <https://github.com/lsst-dm/prompt_processing/actions/workflows/build-base.yml>`_ and select "**Run workflow**". From the dropdown menu, select:
34+
35+
#. The branch whose container definition will be used
36+
#. The label of the Science Pipelines container.
37+
#. If using a quick-stack build, the Science Pipelines Container should be set to `ghcr.io/lsst/quick-stack <https://ghcr.io/lsst/quick-stack>`_.
38+
39+
New containers built from ``main`` are tagged with the corresponding Science Pipelines release (plus ``w_latest`` or ``d_latest`` if the release was requested by that name).
3640
For automatic ``main`` builds, or if the corresponding box in the manual build is checked, the new container also has the ``latest`` label.
3741
Containers built from a branch use the same scheme, but prefixed by the ticket number or, for user branches, the branch topic.
3842

@@ -45,8 +49,8 @@ To build the base container:
4549
To build the service container:
4650

4751
* If there are changes to the service, push them to a branch, then open a PR.
48-
The container should be built automatically using the ``latest`` base container.
49-
* To force a rebuild manually, go to the repository's `Actions tab <https://github.com/lsst-dm/prompt_processing/actions/workflows/build-service.yml>`_ and select "Run workflow".
52+
This will build the container automatically using the ``latest`` base container.
53+
* To force a rebuild manually, go to the repository's `Actions tab <https://github.com/lsst-dm/prompt_processing/actions/workflows/build-service.yml>`_ and select "**Run workflow**".
5054
From the dropdown, select the branch whose code should be built.
5155
The container will be built using the ``latest`` base container, even if there is a branch build of the base.
5256
* To use a base other than ``latest``, edit ``.github/workflows/_matrix-gen.yaml`` on the branch and override the ``BASE_TAG_LIST`` variable.
@@ -68,6 +72,12 @@ Any subsequent builds of the service container will build against both bases.
6872

6973
This is the only situation in which a change to ``BASE_TAG_LIST`` should be committed to ``main``.
7074

75+
It will sometimes be necessary to compile a container with the LSST Science Pipelines manually (called a Quick-Stack build).
76+
Generally, this only occurs if the intended daily or weekly stack does not compile.
77+
In these cases, the Science Pipelines themselves must be built ahead of the base container.
78+
Instructions for building the Science Pipelines are `here <https://github.com/lsst/gha_build/blob/main/README.md>`_.
79+
For Prompt Processing, we only need to build ``lsst_distrib``.
80+
7181
Release Management
7282
==================
7383

@@ -79,48 +89,63 @@ From the ``main`` branch you can release a new major version (``X.0.0``), a new
7989
Release tags are semantic version identifiers following the `pep 440 <https://peps.python.org/pep-0440/>`_ specification.
8090
Please note that the tag does not include a ``v`` at the beginning.
8191

82-
1. Choose Version Number
92+
#. Choosing the Version Number
93+
94+
The first step in making a release is choosing an appropriate version number to describe it. This subsection offers guidance on this choice, as well as on differentiating between major and minor releases.
95+
96+
**To see which changes have occurred since the last release:**
97+
98+
On GitHub.com, navigate to the main page of the repository.
99+
To the right of the list of files, click the latest release.
100+
At the top of the page, click **## commits to main since this release**.
101+
(If there's no such link or it doesn't mention ``main``, the release is probably based off a branch; go up to Releases and try older versions until you find one.)
102+
This is the list of internal changes that will be included in the next release.
83103

84-
On GitHub.com, navigate to the main page of the repository.
85-
To the right of the list of files, click the latest release.
86-
At the top of the page, click **## commits to main since this release**.
87-
(If there's no such link or it doesn't mention ``main``, the release is probably based off a branch; go up to Releases and try older versions until you find one.)
88-
This is the list of internal changes that will be included in the next release.
104+
If you are planning to update the Science Pipelines tag, you should also check the `Science Pipelines changelog <https://lsst-dm.github.io/lsst_git_changelog/weekly/>`_.
105+
In practice, almost any Science Pipelines update is at least a minor version, because new features are added constantly.
106+
You may need to do a "Quick-Stack" build, or build the science pipelines manually. This would justify a patch version of Prompt Processing.
89107

90-
If you are planning to update the Science Pipelines tag, you should also check the `Science Pipelines changelog <https://lsst-dm.github.io/lsst_git_changelog/weekly/>`_.
91-
In practice, almost any Science Pipelines update is at least a minor version, because new features are added constantly.
92-
In the future, there may be "patched weekly" builds, which would justify a patch version of Prompt Processing.
108+
**The following changes will trigger a major release:**
93109

94-
For the ``prompt_processing`` service, a new major version is triggered by any of the following:
110+
For the ``prompt_processing`` service:
95111

96-
* Incompatibility with old fanned-out ``nextVisit`` messages (almost any change to ``Visit`` qualifies)
97-
* Incompatibility with an old `APDB schema`_, `ApdbSql`_, `ApdbCassandra`_, or `ApdbCassandraReplica`_ version (see `DMTN-269`_ for the distinction)
98-
* Incompatibility with an old `Butler dimensions-config`_ version
99-
* A new major version of the `Alerts schema`_ (see `DMTN-093`_ for details)
112+
* Incompatibility with old fanned-out ``nextVisit`` messages (almost any change to ``Visit`` qualifies)
113+
* Incompatibility with an old `APDB schema`_, `ApdbSql`_, `ApdbCassandra`_, or `ApdbCassandraReplica`_ version (see `DMTN-269`_ for the distinction)
114+
* Incompatibility with an old `Butler dimensions-config`_ version
115+
* A new major version of the `Alerts schema`_ (see `DMTN-093`_ for details)
100116

101-
For the `next_visit_fan_out`_ service, a new major version is triggered by any of the following:
117+
For the `next_visit_fan_out`_ service:
102118

103-
* Incompatibility with old Summit ``nextVisit`` messages
104-
* Breaking changes in the fanned-out ``nextVisit`` messages (almost any change to ``NextVisitModel`` qualifies)
119+
* Incompatibility with old Summit ``nextVisit`` messages
120+
* Breaking changes in the fanned-out ``nextVisit`` messages (almost any change to ``NextVisitModel`` qualifies)
105121

106-
2. Create a Release
122+
#. Create a Release
107123

108-
On GitHub.com, navigate to the main page of the repository.
109-
To the right of the list of files, click **Releases**.
110-
At the top of the page, click **Draft a new release**.
111-
Type a tag using semantic versioning described in the previous section.
112-
The Target should be the main branch.
124+
On GitHub.com, navigate to the main page of the repository.
125+
To the right of the list of files, click **Releases**.
126+
At the top of the page, click **Draft a new release**.
127+
Type a tag using semantic versioning described in the previous section.
128+
The Target should be the main branch.
113129

114-
Select **Generate Release Notes**.
115-
This will generate a list of commit summaries and of submitters.
116-
Add text as follows.
130+
.. note::
117131

118-
* Any specific motivation for the release (for example, including a specific feature, preparing for a specific observing run)
119-
* Science Pipelines version and rubin-env version
120-
* Supported `APDB schema`_ and `ApdbSql`_/`ApdbCassandra`_/`ApdbCassandraReplica`_ versions (see `DMTN-269`_ for rationale).
121-
A stack quoting a given minor version is compatible with *older* APDBs of that major version but not necessarily newer ones; for example, a release whose baseline is APDB schema 1.4.0 can access a schema 1.0.0 or 1.4.1 database, but not schema 1.5.
122-
* Supported `Butler dimensions-config`_ versions
123-
* The `Alerts schema`_ version used for output (see `DMTN-093`_ for details)
132+
The `auto` option is unreliable if there are no changes in Prompt Processing itself.
133+
In these cases, if there weren't any eligible Pull Requests since the last tag, it may choose an older version than the latest.
134+
Select **Generate Release Notes**.
135+
This will generate a list of commit summaries and of submitters.
136+
Add text as follows:
137+
138+
* Any specific motivation for the release (for example, including a specific feature, preparing for a specific observing run)
139+
* Science Pipelines version and rubin-env version
140+
* Supported `APDB schema`_ and `ApdbSql`_/ `ApdbCassandra`_/ `ApdbCassandraReplica`_ versions (see `DMTN-269`_ for rationale).
141+
A stack quoting a given minor version is compatible with *older* APDBs of that major version but not necessarily newer ones; for example, a release whose baseline is APDB schema 1.4.0 can access a schema 1.0.0 or 1.4.1 database, but not schema 1.5.
142+
* Supported `Butler dimensions-config`_ versions
143+
* The `Alerts schema`_ version used for output (see `DMTN-093`_ for details)
144+
145+
Select **Publish Release**.
146+
147+
The `Release CI <https://github.com/lsst-dm/prompt_processing/actions/workflows/ci-release.yaml>`_ GitHub Actions workflow uploads the new release to GitHub packages.
148+
This may take a few minutes, and the release is not usable until it succeeds.
124149

125150
.. _DMTN-093: https://dmtn-093.lsst.io/#alertmanagement
126151

@@ -132,17 +157,12 @@ Add text as follows.
132157

133158
.. _ApdbSql: https://github.com/lsst/dax_apdb/blob/main/python/lsst/dax/apdb/sql/apdbSql.py#L71-L75
134159

135-
.. _ApdbCassandra: https://github.com/lsst/dax_apdb/blob/main/python/lsst/dax/apdb/cassandra/apdbCassandra.py#L84-L88
160+
.. _ApdbCassandra: https://github.com/lsst/dax_apdb/blob/main/python/lsst/dax/apdb/cassandra/apdbCassandra.py#L87-L91
136161

137162
.. _ApdbCassandraReplica: https://github.com/lsst/dax_apdb/blob/main/python/lsst/dax/apdb/cassandra/apdbCassandraReplica.py#L52-L56
138163

139164
.. _Alerts schema: https://github.com/lsst/alert_packet/blob/main/python/lsst/alert/packet/schema/latest.txt
140165

141-
Select **Publish Release**.
142-
143-
The `Release CI <https://github.com/lsst-dm/prompt_processing/actions/workflows/ci-release.yaml>`_ GitHub Actions workflow uploads the new release to GitHub packages.
144-
This may take a few minutes, and the release is not usable until it succeeds.
145-
146166

147167
Patch Releases and Release Branches
148168
-----------------------------------

0 commit comments

Comments
 (0)