[HWORKS-2457] Support for versioning in serving deployments - #679
javierdlrm wants to merge 1 commit into
Conversation
robzor92
left a comment
There was a problem hiding this comment.
Reads well. I checked it against ee#3412 and api#1225 at their heads:
-
Deprecated API in the examples. Both use
predictor.resources.num_instances = 2(deployment-versions.md:89,python-deployment.md:251), which is deprecated and emits aDeprecationWarning. Use the scaling configuration instead. -
Restarts (
deployment-versions.md:21). "Running instances restart only when the active configuration changes, so a save without changes does not restart the deployment" is true forSave. Two consequences need saying:Saveno longer restarts a deployment after you edit a script on the HopsFS mount or add libraries to its environment. Userestart(), or stop and start.Save as new versionalways creates a version and restarts the deployment, even with no change.
-
Scripts in a version (
:28). "A version holds … the predictor and transformer scripts" doesn't hold for Python deployments that read the script from the HopsFS mount or from git. Their version stores the path, not the file, so rolling back doesn't bring the old code back. Worth a note in the Python deployment section too. -
Version number on in-place saves. An in-place
Savekeeps the version number, soDEPLOYMENT_VERSIONand the feature-loggingdeployment_versioncolumn stay the same across a script change. Logs from before and after the change can't be told apart. Before this change, uploading a new script bumped the number. -
CI. CI is red only on the three unresolved
hsmlreferences. Merge after api#1225, as the description says.
c5e76ff to
779d047
Compare
|
@robzor92 Thanks. Changes:
Also added the new serving error codes 240052-240055 to the REST error code reference, and that rollback stays available while a version is updating. |
https://hopsworks.atlassian.net/browse/HWORKS-2457 Deployments now keep a numbered history of their configuration. A save either edits the active version in place or stores a new version, and a rollback reactivates an earlier one without copying files. This applies to model deployments and to Python deployments. A new Deployment Versions guide describes what a version holds and what belongs to the deployment instead, how to save a new version, inspect the versions and roll back from the web UI and the Python API, the conflict a concurrent change raises, and where the files of each version are stored. The serving overview and the deployment guide link to it, and the Python deployment guide gains a short Versions section. The guide states when a save restarts the deployment and when it does not, that an in-place save keeps the version number seen by the deployment and by feature logging, that a script read from a HopsFS path or git is stored as that path, and that a rollback stays available while a version is updating. The examples set the instance count through the scaling configuration. The REST error code reference lists the new serving codes 240052 to 240055. The web UI steps show the save menu, the Details button and the Roll back button, and what a version holds is a table. It also says that a rollback while updating starts a new rollout while the current instances keep serving, and that an edit saved in place cannot be rolled back. Signed-off-by: Javier de la Rúa Martínez <javier@logicalclocks.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
779d047 to
f6d9565
Compare
https://hopsworks.atlassian.net/browse/HWORKS-2457
Documents versioning in serving deployments, for model deployments and Python deployments.
user_guides/mlops/serving/deployment-versions.md: what a version holds and what belongs to the deployment instead, saving a new version, inspecting the versions and rolling back (web UI and Python API), the conflict raised by concurrent changes, and where each version's files are stored.serving/index.mdandserving/deployment.mdlink to the guide.python-deployment.mdgains a short Versions section.mkdocs.ymladds the nav entry.DEPLOYMENT_VERSIONand thedeployment_versionlogging column, scripts from a HopsFS path or git are stored as that path, rollback stays available while a version is updating, the scaling example, screenshots of the three UI actions, and the new serving error codes 240052 to 240055 in the REST error code reference.Merge order
The guide's API reference links to
Deployment.get_versions,Deployment.rollbackandDeploymentVersion, which come with logicalclocks/hopsworks-api#1225. Merge after that PR, or the strict build fails on the unresolved references.Related: logicalclocks/hopsworks-ee#3412, logicalclocks/hopsworks-front#2139, logicalclocks/loadtest#1085, logicalclocks/hopsworks-helm#2435.
Verification
hopsworks-docs check,markdownlintandsnakeoilpass locally, with hopsworks-api installed from the HWORKS-2457 branch.🤖 Generated with Claude Code