Repository navigation
Answer the open API questions against a real tenant - #11
Merged
Merged
Conversation
The CSP API reference describes the address field only as a.b.c.d or a.b.c.d/n, yet every next-available create puts a parent id plus a nextavailable suffix there. Add it as an open question in docs/uddi-api-notes.md and DESIGN.md section 14, with why the documented next-available endpoints cannot replace it (no tags, so a two-call create can leak an untagged object) and the missing concurrency guarantee. Also correct the notes: the nextavailablesubnet and nextavailableaddressblock endpoints take cidr, count, name and comment, not only count and contiguous.
Ran the integration suite against a tenant on 2026-11-30 and wrote the verdicts back: every **verify** item in docs/uddi-api-notes.md is now settled, and DESIGN.md open questions 6, 7 and 8 are resolved. New tests in test/integration/openquestions_test.go cover what had none: the nextavailableaddressblock form, concurrent next-available creates from independent clients, whether _limit is capped and _offset pages cleanly, and the path parameter of the dedicated next-available endpoints. The concurrency result changes the reasoning behind the per-parent mutex. With 8 clients racing for one subnet, 4 got distinct addresses and 4 failed with HTTP 400 "already exists". The API never hands out a duplicate, but it gives racing callers the same candidate and fails all but the first. That and the missing tags on the documented next-available endpoints are raised with Infoblox product management. The suite can now run on the JWT of an interactive portal login (UDDI_BEARER_TOKEN) as well as an API key; bearer_test.go swaps the header for the suite's own requests only.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The operator's next-available allocation depends on a Universal DDI API form the CSP API reference doesn't document. This records that, then settles every verify item in the API notes against a real tenant (2026-11-30).
Next-available is undocumented. Every next-available create puts
<parent id>/nextavailableip,/nextavailablesubnetor/nextavailableaddressblockin theaddressfield of a normal create. The API reference describesaddressonly asa.b.c.dora.b.c.d/n. The Infoblox Terraform provider and Ansible collection rely on the same form. The documented next-available endpoints can't replace it because none of them takes tags, and a two-call create can leak an untagged object. This is now open question 9 inDESIGN.mdand Open questions 1 indocs/uddi-api-notes.md, and has been raised with Infoblox product management.What the tenant run settled:
The address … already exists.No duplicates_limit/_offset{"error":[{"message": ...}]}dhcp/option_code/<uuid>anddhcp/option_space/<uuid>, as assumedThe concurrency result changes why the per-parent mutex exists. The API never hands out a duplicate. It gives racing callers the same candidate and fails all but the first, so the mutex saves failed requests rather than preventing duplicates. Across processes the operator still gets the 400. It reports
APIError, retries with backoff and picks a new address.Tests.
test/integration/openquestions_test.goadds the four checks that had no test: the address block form, concurrent clients (each with its own client, so the operator's mutex doesn't serialise them),_limit/_offset, and the dedicated endpoint's path parameter.test/integration/bearer_test.golets the suite run on the JWT of an interactive portal login (UDDI_BEARER_TOKEN) as well as an API key. It swaps the header for the suite's own requests only, and the deliberate bad-key test is left alone.Verification.
make test-integrationagainst a real tenant: 26 tests, all pass in 76 s. Afterwards no object carrying the run's tag was left in the tenant.go vet -tags integration ./test/integration/...is clean. No operator code changes.🤖 Generated with Claude Code