Skip to content

Conversation

@JamesMcDermott
Copy link
Contributor

As in the AMF and UPF blueprints, add one more call of the nfdeploy-fn kpt function at the end of the Kpt pipeline to make it become ready more reliably.

When deploying the SMF blueprint package through Porch (for example, in the case of the free5gc test flow), the final mutations for the resulting downstream package revision to be ready (and eligible for propose-and-approve) are done by one last run of nfdeploy-fn.
Currently this last run occurs in the course of a Kpt render triggered by Porch performing one last update to the package revision's Kptfile, to reorganise several sections (without any actual changes to the content) including the order of fields and the sorting of the readiness conditions in the status.conditions section.

I suspect Porch's current inconsistent handling of Kptfile structure (field order, condition sorting, etc.) has been concealing the reliance on a final Kpt render, by making Porch update the package revision frequently enough that it regularly triggers a render anyway causes that render's first run of nfdeploy-fn to perform the required updates.

However, ongoing work on Porch issue 615 includes improvements to Porch to make its parsing of Kptfiles more consistent and unified. This results in significantly fewer such "busywork" updates to the Kptfile, and correspondingly less chance of having an update trigger the Kpt render and perform the final mutations. As a consequence, the SMF package's deployment effectively becomes increasingly flaky (with the few successful deployments requiring a wait of anything from 5 to 20 minutes or a restart of Porch pods), and the free5gc test flow along with it.

- add another call of Kpt function nfdeploy-fn to pkg-example-smf-bp
  blueprint package
  - this allows the package to undergo final updates, executed by the final
    run of this function, immediately
  - rather than relying on having another pipeline run triggered by Porch pushing
    a change to shuffle Kptfile fields around
    - a result of inconsistent Kptfile parsing being improved as part of Porch issue
      nephio-project/nephio#615
@efiacor
Copy link
Collaborator

efiacor commented May 23, 2025

/approve

We prob should do a few verify runs of both free5gc and oai

@nephio-prow nephio-prow bot added the approved label May 23, 2025
@JamesMcDermott
Copy link
Contributor Author

Thanks, @efiacor. I've run the free5gc suite a few times with and without the (partially-implemented) changes for issue 615. 6 runs in total, all passing on test case 006.sh (where the SMF blueprint is used). Summaries are below in the expandable section:

TEST SUMMARY (click to expand)
(with partially-complete readiness-gate changes for issue 615)

TEST SUMMARY
------------
001.sh: PASS in 225 seconds
002.sh: PASS in 617 seconds
003.sh: PASS in 73  seconds
004.sh: PASS in 267 seconds
005.sh: PASS in 384 seconds
006.sh: PASS in 235 seconds
007.sh: PASS in 315 seconds
008.sh: PASS in 307 seconds

TEST SUMMARY
------------
001.sh: PASS in 159 seconds
002.sh: PASS in 523 seconds
003.sh: PASS in 72  seconds
004.sh: PASS in 213 seconds
005.sh: PASS in 548 seconds
006.sh: PASS in 63  seconds
007.sh: PASS in 335 seconds
008.sh: PASS in 31  seconds

TEST SUMMARY
------------
001.sh: PASS in 174 seconds
002.sh: PASS in 621 seconds
003.sh: PASS in 65  seconds
004.sh: PASS in 259 seconds
005.sh: PASS in 281 seconds
006.sh: PASS in 229 seconds
007.sh: PASS in 219 seconds
008.sh: PASS in 305 seconds

TEST SUMMARY
------------
001.sh: PASS in 159 seconds
002.sh: PASS in 681 seconds
003.sh: PASS in 68 seconds
004.sh: PASS in 220 seconds
005.sh: PASS in 325 seconds
006.sh: PASS in 316 seconds
007.sh: PASS in 218 seconds
008.sh: FAIL (intermittent mutex/session-conflict issue with updating package revision, not related to readiness-gate changes)
Porch main branch (without readiness-gate changes)

TEST SUMMARY
------------
001.sh: PASS in 156 seconds
002.sh: PASS in 496 seconds
003.sh: PASS in 65  seconds
004.sh: PASS in 104 seconds
005.sh: PASS in 85  seconds
006.sh: PASS in 49  seconds
007.sh: PASS in 72  seconds
008.sh: PASS in 320 seconds

TEST SUMMARY
------------
001.sh: PASS in 164 seconds
002.sh: PASS in 505 seconds
003.sh: PASS in 55 seconds
004.sh: PASS in 94 seconds
005.sh: PASS in 145 seconds
006.sh: PASS in 42 seconds
007.sh: PASS in 182 seconds
008.sh: PASS in 317 seconds

The oai suite is not affected by this change - its SMF test uses a different SMF blueprint package (oai-smf) whose pipeline already includes the second call of nfdeploy-fn.

@efiacor
Copy link
Collaborator

efiacor commented May 26, 2025

/approve
/lgtm

@nephio-prow
Copy link
Contributor

nephio-prow bot commented May 26, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: efiacor, JamesMcDermott

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@nephio-prow nephio-prow bot merged commit 9f6af8c into nephio-project:main May 26, 2025
2 checks passed
@efiacor efiacor deleted the free5gc-smf-fix branch May 26, 2025 10:38
JamesMcDermott added a commit to Nordix/porch that referenced this pull request May 30, 2025
- was dependent on debugging to find and fix an issue in a test artefact
  - see nephio-project/catalog#110
- resolved performance degradation in packagevariant_controller
  - added too many calls to re-read package revisions or resources
    - should have it pared down to the minimum to work OK
- detection of pipeline now works as intended to set the "waiting
  for pipeline run" readiness condition only if the package has a
  pipeline that will do anything in the render

nephio-project/nephio#615
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants