Scenarios — python-octaviaclient — branch stable/2026.2
Branch
stable/2026.2@b37975ec8f2d(tag3.15.0+ 2 commits) — repository https://opendev.org/openstack/python-octaviaclient — analysed on 2026-11-01
The request sequences are [observed] against the local stub. Statuses and timing on a real service are not observed here. The asynchronous work on the service side belongs to reverse-spec-octavia/.
1. Create a load balancer and wait
openstack loadbalancer create --vip-subnet-id <subnet> --wait (octaviaclient/osc/v2/load_balancer.py:155-190).
sequenceDiagram
autonumber
actor U as User
participant C as openstack
participant K as Keystone
participant N as Neutron
participant O as Octavia
U->>C: loadbalancer create --vip-subnet-id S --wait
C->>K: GET /identity, POST /v3/auth/tokens
K-->>C: token and catalog
C->>N: GET /v2.0/subnets?id=S or ?name=S
N-->>C: one subnet
C->>O: POST /v2.0/lbaas/loadbalancers
O-->>C: 201 loadbalancer with id
loop every 3 s, no limit
C->>O: GET /v2.0/lbaas/loadbalancers/ID
O-->>C: provisioning_status
end
alt ACTIVE
C->>O: GET /v2.0/lbaas/loadbalancers/ID
C-->>U: table, exit 0
else ERROR
C-->>U: did not successfully reach ACTIVE status, exit 1
else missing field
C-->>U: NoneType has no attribute lower, exit 1
endDiagnostics: Service 'network' is disabled… means no network entry in the catalog. A hang means the load balancer stays in PENDING_*: look at the Octavia worker. With --debug, the request IDs are printed.
2. Show by name, and the fallback of a missing UUID
loadbalancer show <value> (octaviaclient/osc/v2/load_balancer.py:385-417, octaviaclient/osc/v2/utils.py:68-105).
sequenceDiagram
autonumber
participant C as openstack
participant O as Octavia
alt the value looks like a UUID
C->>O: GET /lbaas/loadbalancers/UUID
alt 200
O-->>C: loadbalancer
else 404 or 400
O-->>C: fault
C->>O: GET /lbaas/loadbalancers?id=UUID
O-->>C: empty
C->>O: GET /lbaas/loadbalancers?name=UUID
O-->>C: empty
C-->>C: Unable to locate UUID in loadbalancers, exit 1
else 403 or other
O-->>C: fault
C-->>C: faultstring (HTTP code), exit 1
end
else a name
C->>O: GET /lbaas/loadbalancers?name=N
alt one match
O-->>C: one row
C->>O: GET /lbaas/loadbalancers/ID
else several
C-->>C: 2 loadbalancers found with name or ID of N, exit 1
else none
C-->>C: Unable to locate N in loadbalancers, exit 1
end
endDiagnostics: Unable to locate also appears when the project in the token cannot see the resource. A KeyError-style message such as 'loadbalancers' means the service sent a list without its key.
3. Add a member and wait
loadbalancer member create <pool> --address A --protocol-port 80 --wait (octaviaclient/osc/v2/member.py:211-246). The member has its own status, but the command waits on the load balancer.
sequenceDiagram
autonumber
participant C as openstack
participant O as Octavia
C->>O: GET /lbaas/pools?name=P
O-->>C: pool id
C->>C: check port and weight
C->>O: POST /lbaas/pools/ID/members
O-->>C: 201 member
C->>O: GET /lbaas/pools/ID
O-->>C: loadbalancers list
loop until ACTIVE or ERROR
C->>O: GET /lbaas/loadbalancers/LB
end
C->>O: GET /lbaas/pools/ID/members/MEMBER
O-->>C: memberDiagnostics: if the pool's loadbalancers is empty, the command ends with list index out of range although the member exists (02 § 5 item 11).
4. Delete with cascade and wait
loadbalancer delete <lb> --cascade --wait (octaviaclient/osc/v2/load_balancer.py:219-232, octaviaclient/osc/v2/utils.py:801-821).
sequenceDiagram
autonumber
participant C as openstack
participant O as Octavia
C->>O: GET /lbaas/loadbalancers?name=N
O-->>C: id
C->>O: DELETE /lbaas/loadbalancers/ID?cascade=True
O-->>C: 204
loop every 3 s, at most 300 s
C->>O: GET /lbaas/loadbalancers/ID
alt 404
O-->>C: fault
C-->>C: done, exit 0
else status error
O-->>C: ERROR
C-->>C: could not be successfully deleted, exit 1
else other status
O-->>C: PENDING_DELETE
end
end
C-->>C: could not be successfully deleted, exit 1Diagnostics: a 409 on the DELETE usually means a parent is immutable; its faultstring is displayed. A 403 during polling stops the wait [observed].
5. A filtered list across pages
loadbalancer list --project P when the filter fills a page (octaviaclient/api/v2/octavia.py:82-102).
sequenceDiagram autonumber participant C as openstack participant O as Octavia C->>O: GET /lbaas/loadbalancers?project_id=P O-->>C: rows of page 1, next link with limit and marker only C->>O: GET /lbaas/loadbalancers?limit=L&marker=M Note over C,O: project_id is gone: the service filters only by its own rules O-->>C: next rows, not restricted to P C-->>C: prints both pages, exit 0
Diagnostics: more rows than expected on a large deployment, or rows of another project for an admin. Client side [observed]; Octavia's link was read (octavia:octavia/api/common/pagination.py:151-172). The two were not run together.
Source: reverse-spec-python-octaviaclient/04-scenarios_stable-2026.2.md. The _rewrite/ and _inventory/ files are not published on the site.