Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
379 commits
Select commit Hold shift + click to select a range
bb0a4db
Fixup pep8 for device resource type
Jun 23, 2021
8840b51
Fixup: use hostname not name of Zun node
Jun 23, 2021
aa4f532
fixup: temp disable placement provider syncing
Jun 23, 2021
1bbbe27
fix cleanup device on lease terminating (#41)
zhenz Jul 16, 2021
17fd229
check if reservation provider created in placement (#40)
zhenz Jul 16, 2021
743df54
Add project-restricted devices (#42)
Mark-Powers Jul 16, 2021
5a42e3f
handling device reservation trait not exist
zhenz Jul 23, 2021
dd1c7f7
get context from trust for end_lease (#43)
zhenz Jul 27, 2021
e2cc2ee
Handle error retrieving device
Jul 27, 2021
b03a077
Filter out containers on target host in caller
Jul 27, 2021
bacf3a4
Add 'extras' field when getting allocations
Mark-Powers Aug 6, 2021
e05e160
Get extras from config
Mark-Powers Aug 11, 2021
9d4951d
Remove unused import
Mark-Powers Aug 11, 2021
484d782
Gather KS users all at once
Mark-Powers Aug 23, 2021
c47f925
add device healing capability
zhenz Aug 11, 2021
d1968f3
Move allocations extras to api section of config (#48)
Mark-Powers Sep 3, 2021
925f877
fixup: reference before assignment in device plugin
Sep 9, 2021
21ad225
Add default resource properties
Mark-Powers Oct 7, 2021
07bc26b
keep enforcement filters in order
zhenz Oct 19, 2021
f47e433
fix pep8
zhenz Oct 22, 2021
3bac453
Fix device query to get only reservable devices (#53)
Mark-Powers Oct 26, 2021
d463403
Refactor RPC layer so it is not used in API
Mark-Powers Oct 8, 2021
a300765
Use partial function to call manager when applicable
Mark-Powers Oct 20, 2021
12c1ef9
Fix typos
Mark-Powers Oct 21, 2021
a9838c4
Refactor to remove call_manager
Mark-Powers Nov 3, 2021
e53ce09
Fix typo
Mark-Powers Nov 3, 2021
76a5d65
fix for new balance service system
zhenz Dec 2, 2021
4a5bcb2
fix pep8
zhenz Dec 9, 2021
5a107ed
Fix notifier and lease_id error
Mark-Powers Dec 9, 2021
9977748
Fix pep8
Mark-Powers Dec 9, 2021
a578cfb
Fix manager singleton instance
Mark-Powers Dec 10, 2021
8445312
Fix pep8
Mark-Powers Dec 9, 2021
db3c726
Fix rebase issues
Mark-Powers Dec 13, 2021
901fbf6
Generalize HostHavingServers exception
Mark-Powers Dec 13, 2021
485cd0b
Merge pull request #60 from ChameleonCloud/bugfix/reallocate_check_se…
Mark-Powers Dec 14, 2021
e39a015
Merge pull request #59 from ChameleonCloud/bugfix_project_id
Mark-Powers Dec 15, 2021
044cef8
Fix failing tests
Mark-Powers Dec 15, 2021
e8ceac4
Merge branch 'chameleoncloud/train' into upstream_merge
Mark-Powers Dec 15, 2021
1dff00f
Update retry allocation logic
Mark-Powers Dec 16, 2021
7242bb9
Merge branch 'chameleoncloud/train' into update_default_properties
Mark-Powers Dec 16, 2021
350d382
Fix typo with default properties
Mark-Powers Dec 16, 2021
62e6a79
Fix network extra capability query
Mark-Powers Dec 17, 2021
69bade0
Merge pull request #61 from ChameleonCloud/upstream_merge
Mark-Powers Dec 17, 2021
49f934a
Update upper constraints to xena
Mark-Powers Dec 17, 2021
78a9182
Revert constraints back to train
Mark-Powers Dec 20, 2021
90c21d0
Merge pull request #63 from ChameleonCloud/revert_constraints
Mark-Powers Dec 20, 2021
6323976
Merge pull request #57 from ChameleonCloud/update_default_properties
Mark-Powers Dec 20, 2021
f966149
Merge pull request #62 from ChameleonCloud/bugfix/network_capabilities
Mark-Powers Dec 20, 2021
f6b5ff9
Handle missing/deleted nova hypervisor on host-delete (#64)
diurnalist Jan 6, 2022
dd15b44
Fix typo in max_lease_duration filter
Mark-Powers Jan 7, 2022
84e35c7
Fix floating IP conf error when not enough IPs
Mark-Powers Jan 7, 2022
d7e2b19
Merge pull request #65 from ChameleonCloud/bugfix/max_reservation_ex
Mark-Powers Jan 10, 2022
9697ef7
Merge pull request #66 from ChameleonCloud/bugfix/lease_retry
Mark-Powers Jan 10, 2022
a758688
Change how lease status is restored
Mark-Powers Jan 11, 2022
720df72
Fix lease update duration error message
super-cooper Jan 21, 2022
4b7e35f
Fix lease update when resource_type parameter is missing
priteau Jan 13, 2022
9a3033a
Change to use isinstance for checking type, and fix pep
Mark-Powers Jan 21, 2022
16025e8
Remove unused restore_lease_status
Mark-Powers Jan 21, 2022
72f7757
Merge pull request #67 from ChameleonCloud/enforcement-exception
Mark-Powers Jan 25, 2022
be84dc3
Merge pull request #68 from ChameleonCloud/restore_lease_status
Mark-Powers Jan 27, 2022
e952ef1
Add k3s device plugin (#69)
Mark-Powers Feb 7, 2022
d6d4e4c
Allow removing active floating ips from a lease
Mark-Powers Feb 18, 2022
9cfc82b
Forbid setting certain extra capabilities
Mark-Powers Feb 18, 2022
b7a0712
Apply suggestions from code review
Mark-Powers Feb 21, 2022
d73fab3
Merge pull request #71 from ChameleonCloud/forbidden_extra
Mark-Powers Feb 21, 2022
63eb019
Refactor to check for reservation status in deallocate
Mark-Powers Feb 21, 2022
2e0fc2a
Merge pull request #70 from ChameleonCloud/floating_ip_reduce
Mark-Powers Feb 21, 2022
e540acb
rename k3s to k8s
Feb 21, 2022
d2e130b
Handle node missing from k8s
Feb 25, 2022
a9ed3d4
Handle k8s node rebuild case
Mar 11, 2022
a82ec55
Add soft delete behavior to resources and capabilities (#73)
super-cooper May 11, 2022
3117765
Update .gitreview for stable/xena
openstackadmin Sep 17, 2021
ab7ea4c
Update TOX_CONSTRAINTS_FILE for stable/xena
openstackadmin Sep 17, 2021
e68ab5a
Allow clients to unset resource properties (#74)
super-cooper Jun 6, 2022
59c502e
Allow hosts to be restricted to certain projects (#76)
super-cooper Jun 10, 2022
b96e33f
Allow reallocate to limit scope to a single lease for non-admin users…
super-cooper Jun 13, 2022
dd3c1eb
storage vlan reservation
zhenz May 2, 2022
42f2b77
Merge pull request #78 from ChameleonCloud/filesystem2
zhenz Jun 27, 2022
d285bc9
Monitor should not reallocate for an active reservation (#79)
super-cooper Jul 15, 2022
4216bf0
fixes
zhenz Jul 19, 2022
09cf8ee
Merge pull request #80 from ChameleonCloud/api-fix
zhenz Aug 9, 2022
980e043
Fetch project ID from lease instead of reservation in `_update_alloca…
super-cooper Nov 8, 2022
dac64f4
we're running v18 of the client now, update import
msherman64 Mar 20, 2023
7d714dd
Run unit tests in GitHub actions (#84)
AnishReddyRavula Jun 27, 2023
6d7b50c
Fix Blazar unit tests (#85)
AnishReddyRavula Jul 5, 2023
7dd868f
Enforcement non fatal (#86)
AnishReddyRavula Jul 13, 2023
5ecdc85
update soft delete for device extra capabilities
msherman64 Jul 25, 2023
88ae76c
Removing the call to ironic to detach the port
AnishReddyRavula Sep 26, 2023
baa7c8c
Add check for improperly torn-down host aggregates (#91)
AnishReddyRavula Nov 7, 2023
7d5ccec
[Host clean up]remove the active filter as we need reservation with a…
AnishReddyRavula Nov 7, 2023
e907584
Remove unwanted columns in select, replace unexpected cross joins wit…
AnishReddyRavula Nov 9, 2023
6a6010f
Host aggregate cleanup - UTC time fix and better logging (#96)
AnishReddyRavula Nov 14, 2023
6ca1758
Monitor for FloatingIPs to make the resources reservable (#93)
AnishReddyRavula Nov 20, 2023
21c5a9e
Disabled field in compute host (#97)
AnishReddyRavula Nov 20, 2023
968431a
Fix the error when monitor calls _is_admin with context not available
AnishReddyRavula Nov 20, 2023
a855147
Use threads to add and remove hosts to/from aggregate (#92)
AnishReddyRavula Dec 2, 2023
593b101
Column name typo in drop column for soft delete resources db migratio…
AnishReddyRavula Dec 12, 2023
d7e130a
Network cleanup (#103)
AnishReddyRavula Dec 14, 2023
b6c92ac
refactor network operations in NetworkMonitorPlugin (#105)
AnishReddyRavula Dec 21, 2023
fcfd841
Add Python3 yoga unit tests
openstackadmin Sep 17, 2021
44e20d4
CI: Fix breakage following devstack changes
priteau Nov 5, 2021
9df7c51
Updating python testing classifier as per Yoga testing runtime
Nov 25, 2021
95667b5
Fix list_allocations for multi-host reservations
priteau Jan 18, 2022
3dd8591
Restore lease status during a non fatal lease update exception
Mark-Powers Sep 20, 2021
1dbc63c
Fix lease update when resource_type parameter is missing
priteau Jan 13, 2022
659735f
Update Nova scheduler filter configuration
priteau Feb 7, 2022
a56453a
Switch to using internal endpoints
priteau Feb 10, 2022
dc808b8
Use configured endpoint type in url_for
priteau Feb 11, 2022
e583d0e
Add resource properties discovery API
Mark-Powers Sep 21, 2021
867969e
Use built-in oslo context de/serialization
May 27, 2020
7addfa5
Prevent conflicting events from running concurrently
priteau Aug 8, 2018
0d51b9e
Update .gitreview for stable/yoga
openstackadmin Mar 8, 2022
2636ebc
Update TOX_CONSTRAINTS_FILE for stable/yoga
openstackadmin Mar 8, 2022
e1f55fb
Fix references to start and end dates
priteau Mar 10, 2022
f1b17fc
Synchronise tox.ini with changes from other branches
priteau Aug 25, 2022
4e9f669
[CI] Move queue setting to project level
priteau May 20, 2022
412b1e1
Add soft delete mixin to ResourceProperty
AnishReddyRavula Jan 8, 2024
dd5ca60
Resource property migration (#107)
AnishReddyRavula Jan 9, 2024
b2b1fc2
remove unused imports in service.py
AnishReddyRavula Jan 9, 2024
45a2b3f
Update master for stable/yoga
openstackadmin Mar 8, 2022
6c1c15d
Add Python3 zed unit tests
openstackadmin Mar 8, 2022
feece28
Skip blazar install in docs and pep8 jobs
priteau Mar 24, 2022
964b623
Drop lower-constraints.txt and its testing
Apr 30, 2022
a35071c
Remove reference to lower-constraints job
priteau May 5, 2022
e3514f6
Update IRC meeting information
priteau Jun 7, 2022
0614663
Update keystone client to use base client kwargs
Apr 14, 2021
22bbb5a
Update configuration for compatibility with Sphinx 5
priteau Jun 6, 2022
4e24a88
Update python testing as per zed cycle testing runtime
Jun 4, 2022
f5ed698
Add WebTest as a test dependency
yoctozepto Aug 3, 2022
ab6cd1e
[docs] Install blazar to generate proper docs
yoctozepto Aug 3, 2022
0c13a8e
Add enforcement filter using an external HTTP service
priteau Aug 30, 2022
e73215e
Fix misuse of assert statements
takanattie Sep 11, 2022
6cdbfc1
Improve ExternalServiceFilter
yoctozepto Sep 8, 2022
c957616
Update .gitreview for stable/zed
openstackadmin Sep 16, 2022
3b3b7a5
Update TOX_CONSTRAINTS_FILE for stable/zed
openstackadmin Sep 16, 2022
fde094b
Update master for stable/zed
openstackadmin Sep 16, 2022
af0d136
Switch to 2023.1 Python3 unit tests and generic template name
openstackadmin Sep 16, 2022
85a80d8
Update copyright date for release notes
priteau Sep 23, 2022
85663a3
[docs] Rewrite the architecture description
yoctozepto Aug 6, 2022
af6988e
Fix tox.ini for tox4
priteau Feb 24, 2023
30ed6e5
Add randomness to physical host selection
jakecoll Sep 10, 2018
86572bb
Update .gitreview for stable/2023.1
openstackadmin Feb 28, 2023
50eaacb
Update TOX_CONSTRAINTS_FILE for stable/2023.1
openstackadmin Feb 28, 2023
4093396
fix softdelete for blazar network capability
AnishReddyRavula Feb 7, 2024
f412ebe
Fix before lease end event error when user email is not set
AnishReddyRavula Feb 22, 2024
a20ba99
Add validation to ensure unique capabilities when needed and device n…
AnishReddyRavula Mar 25, 2024
c4661d6
Add validation for capability value - updating the value (#112)
AnishReddyRavula Mar 25, 2024
b700714
Resource details in a lease (#113)
AnishReddyRavula Apr 10, 2024
5f881ba
Merge remote-tracking branch 'origin/chameleoncloud/xena' into chamel…
msherman64 Jul 16, 2024
7023bb5
reorder alembic migrations to avoid multiple heads
msherman64 Jul 16, 2024
bcd5579
fix alembic constraint names
msherman64 Jul 16, 2024
c121fe0
Rename unique property validation
Mark-Powers Jul 18, 2024
2c03820
Fix device/netework property creation
Mark-Powers Jul 18, 2024
d14c107
Use user token in external enforcement if not configured
Mark-Powers Jul 23, 2024
6ae25b1
Use external endpoint for enforcement
Jul 23, 2024
f29ab3d
Merge pull request #116 from ChameleonCloud/wip/external_enforcement_fix
Mark-Powers Jul 23, 2024
862c65f
Fix healing during a lease
Mark-Powers Jul 23, 2024
1e96933
Merge pull request #117 from ChameleonCloud/fix_healing_during_lease
Mark-Powers Jul 23, 2024
1378fac
Fix token expiring in external enforcement
Mark-Powers Jul 25, 2024
24234c3
Merge pull request #118 from ChameleonCloud/fix_external_token
Mark-Powers Jul 25, 2024
b4449e5
Properly check non fatal exception subclasses
Mark-Powers Oct 22, 2024
0e8a539
Include reservation ID information in check_create
Mark-Powers Oct 22, 2024
b7b3fc6
Fix unit tests
Mark-Powers Oct 22, 2024
bbd20e8
Merge pull request #119 from ChameleonCloud/non_fatal_updates
Mark-Powers Oct 24, 2024
cacd72b
Return res id in create_reservation
Mark-Powers Oct 24, 2024
12ea51c
Fix exception parent class
Mark-Powers Oct 31, 2024
d89ab78
Merge pull request #120 from ChameleonCloud/res_id_enforcement
Mark-Powers Nov 4, 2024
fbbb9a0
add basic linting using ruff (#122)
msherman64 Jan 13, 2025
7523048
Fix is_project_allowed param (#121)
Mark-Powers Jan 13, 2025
6eef0d4
Fix linting and GHA tests
Mark-Powers Jan 28, 2025
71d7c66
Fix undefined variable cap_name
Mark-Powers Mar 5, 2025
b184598
Fix host randomization
Mark-Powers Feb 17, 2025
e45cd6c
Improve host reallocation
Mark-Powers Mar 6, 2025
6f90d3e
Remove reallocate-to param
Mark-Powers Mar 6, 2025
922add0
Fix redefinition
Mark-Powers Mar 6, 2025
6df098e
Improve _reallocate logic
Mark-Powers Mar 10, 2025
94b3900
Fix allocation list to use cleaning time
Mark-Powers Mar 4, 2025
64fcd0f
Fix allocations tests
Mark-Powers Mar 4, 2025
a3fed07
Fix tests
Mark-Powers Mar 4, 2025
1b0c4a0
Fix cleaning time for get_allocations
Mark-Powers Mar 10, 2025
ae2f2f9
Fix 500 error when updating network/device capabilities
Mark-Powers Apr 22, 2025
a2619d9
Add constraints to gha
Mark-Powers Apr 22, 2025
bf28bbf
Fix logging for tests
Mark-Powers Apr 22, 2025
a25bc05
Fix api header test
Mark-Powers Apr 22, 2025
c962ba0
Add additional invalid ironic provision states to monitor
Mark-Powers Apr 21, 2025
bed1bbd
Add device tests
Mark-Powers Apr 25, 2025
890ef35
Fix host plugin cleanup
Mark-Powers Apr 25, 2025
ba25974
Add teardown for host and app API test
Mark-Powers Apr 28, 2025
ec5a4b6
Fix matching devices test
Mark-Powers Apr 28, 2025
db323d2
Add usage CLI script
Mark-Powers Jun 11, 2025
49d21ac
Update usage to include node info
Mark-Powers Jun 11, 2025
7d5350b
Fix comment
Mark-Powers Jun 11, 2025
3d79d12
Add user ID
Mark-Powers Jun 11, 2025
9144d7f
Fix linting
Mark-Powers Jun 11, 2025
a9bdc55
Add support for 'servers in lease email' (#133)
Mark-Powers Jul 7, 2025
cb583aa
Update usage to include deleted info
Mark-Powers Jul 17, 2025
3baf99b
Fix owner policy enforcement
Mark-Powers Jul 24, 2025
b4c3fd3
fix renaming of k8s -> k3s (#138)
msherman64 Aug 28, 2025
90f2eef
Add lease list --all-tenants option
Mark-Powers Jul 31, 2025
6d4b705
Add --marker and --limit in lease list API
Mark-Powers Aug 1, 2025
500835d
Fix limit API
Mark-Powers Sep 4, 2025
dd039ac
Add filter API
Mark-Powers Sep 5, 2025
b666b51
clearly log when dry run is enabled instead of skipping silently
msherman64 Mar 5, 2026
5fc226f
Add cleaning time to flavor branch
Mark-Powers Mar 6, 2026
c342ec2
Update lease usage
Mark-Powers Mar 17, 2026
7b9eede
Add floating IP allocation API
Mark-Powers Apr 3, 2026
79a28b1
fix: ctx_from_trust drops roles and admin-ness
msherman64 Apr 10, 2026
caac7ed
Add required disabled_reason when setting disabled
Mark-Powers May 14, 2026
acd927d
Add last_error in host monitor
Mark-Powers May 14, 2026
2deba37
ci: Fix pkg_resources error
msherman64 Jun 3, 2026
fc2ff58
ci: pin versions to fix docs and pylint targets
msherman64 Jun 3, 2026
4a6414c
ci: add py310 to default envs
msherman64 Jun 3, 2026
dc7696e
ci: set basepython so docs,pep8 run even if system python newer
msherman64 Jun 3, 2026
4d454f9
ci(no-op): remove stestr_known_failing.txt
msherman64 Jun 3, 2026
db68277
ci: switch back to using tox now that it works
msherman64 Jun 3, 2026
2bf98a6
ci: bump gha versions
msherman64 Jun 3, 2026
6478d40
Cleanup lease during unexpected enforcement exceptions
Mark-Powers Jun 2, 2026
7d3c758
Add lease indexes
Mark-Powers Jun 4, 2026
4d9683e
Avoid joining on leases before filtering/pagination
Mark-Powers Jun 4, 2026
93135a1
perf(lease): move capabilities match into db
msherman64 Jun 1, 2026
213e92b
test: characterize extra-capability host filtering
msherman64 May 30, 2026
a22d0b7
Add computehost indexes
Mark-Powers Jun 4, 2026
f0a647f
fix(nova): brittleness in get_servers_per_host
msherman64 Jun 29, 2026
65e214c
fix(ci): disambiguate hypervisor_hostname and host
msherman64 Jun 29, 2026
333c8e5
tests(db): add tests for linear alembic history
msherman64 Jul 9, 2026
60fa1dc
fix(instance events): get project-id from lease
msherman64 Jul 9, 2026
f41b84d
Update host monitor to use hypervisor instead of ID
Mark-Powers Feb 9, 2026
737b00d
fix(devstack): revert pyproject.toml to fix build
msherman64 Jun 2, 2026
69a765e
fix(db) Don't create db schema at manager start
msherman64 Jul 9, 2026
70710a9
Revert "Delete instances running on reserved hosts when starting rese…
Mark-Powers Jun 2, 2025
9ce4e38
Delete preemptible instances on reservation start
priteau Feb 3, 2022
8b2ad82
fixup(7386403): fix instance nullable db migration
msherman64 Jul 23, 2026
3d6bcb9
db: add compute resources and traits
JohnGarbutt Apr 29, 2024
d9910d4
Add host_resource_inventory_get_all_per_host
JohnGarbutt May 2, 2024
4aebfaa
Fix InstanceReservations affinity nullable flag
priteau Feb 15, 2024
11091f5
Only create a server group when affinity is set
MoteHue Jul 3, 2024
8e9bbe3
Delete server group only if one was created
priteau Aug 26, 2024
6d0eea0
Write inventory and traits into DB
JohnGarbutt Apr 29, 2024
f2f9280
fix: define ResourceProviderNotFound exception
msherman64 Jul 9, 2026
425031c
Implement allocation_candidates for flavor-based reservation
JohnGarbutt Apr 29, 2024
302a457
Make flavor plugin usable
JohnGarbutt May 2, 2024
9d2b522
Document flavor-based instance reservations
MoteHue Aug 23, 2024
292d80b
Enable flavor:instance plugin in DevStack
priteau Aug 28, 2024
e82ddc0
Merge pull request #177 from ChameleonCloud/feat/backport_flavor_rese…
msherman64 Jul 24, 2026
75befbd
fix(flavor): fix crash in on_start and on_end
msherman64 Jul 24, 2026
3436713
feat(flavor): support before_end events
msherman64 Jul 24, 2026
d9705cb
feat: add filter_ironic_hosts config setting
msherman64 Jul 27, 2026
91014e4
feat: Restrict flavor reservation hosts by project
msherman64 Jul 27, 2026
588b9a5
feat: update_reservation for flavor plugin
msherman64 Jul 27, 2026
578ca55
nova: allow per-call client microversion
msherman64 Jul 23, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Unit tests

on: [push, pull_request]

jobs:
unittest:
runs-on: ubuntu-22.04
strategy:
matrix:
python-version:
- "3.9"
- "3.10"
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- run: pip install tox
- run: tox -e py
4 changes: 1 addition & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ pip-log.txt
# Unit test / coverage reports
.coverage
.tox
nosetests.xml
.stestr/
cover

# Translations
Expand All @@ -35,8 +35,6 @@ cover
AUTHORS
ChangeLog

.testrepository

# generated policy file
etc/blazar/policy.yaml.sample

Expand Down
1 change: 1 addition & 0 deletions .gitreview
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
host=review.opendev.org
port=29418
project=openstack/blazar.git
defaultbranch=stable/2023.1
3 changes: 3 additions & 0 deletions .stestr.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[DEFAULT]
test_path=${TEST_PATH:-./blazar/tests}
top_dir=./
7 changes: 0 additions & 7 deletions .testr.conf

This file was deleted.

30 changes: 24 additions & 6 deletions .zuul.yaml
Original file line number Diff line number Diff line change
@@ -1,21 +1,39 @@
- job:
name: blazar-tempest-py3
parent: blazar-tempest-plugin-base
description: |
Local variant of blazar-tempest-plugin-base which forces py3
(the default for this branch is py2)
vars:
devstack_localrc:
USE_PYTHON3: True

- job:
name: blazar-tempest-ipv6-only-py3
parent: blazar-tempest-plugin-ipv6-only
description: |
Local variant of blazar-tempest-plugin-ipv6-only which forces py3
(the default for this branch is py2)
vars:
devstack_localrc:
USE_PYTHON3: True

- project:
queue: blazar
templates:
- check-requirements
- openstack-cover-jobs
- openstack-lower-constraints-jobs
- openstack-python3-yoga-jobs
- openstack-python3-jobs
- publish-openstack-docs-pti
- release-notes-jobs-python3
check:
jobs:
- blazar-tempest-plugin-base
- blazar-tempest-plugin-ipv6-only
- openstack-tox-lower-constraints:
voting: false
- openstack-tox-pylint:
voting: false
gate:
queue: blazar
jobs:
- blazar-tempest-plugin-base
- blazar-tempest-plugin-ipv6-only
- blazar-tempest-py3
- blazar-tempest-ipv6-only-py3
35 changes: 35 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
pipeline {
agent any

options {
copyArtifactPermission(projectNames: 'blazar*')
}

stages {
stage('test') {
parallel {
stage('pep8') {
steps {
sh 'tox -e pep8'
}
}
// stage('py36') {
// steps {
// sh 'tox -e py36'
// }
// }
}
}

stage('package') {
steps {
dir('dist') {
deleteDir()
}
sh 'python setup.py sdist'
sh 'find dist -type f -exec cp {} dist/blazar.tar.gz \\;'
archiveArtifacts(artifacts: 'dist/blazar.tar.gz', onlyIfSuccessful: true)
}
}
}
}
2 changes: 1 addition & 1 deletion api-ref/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language = None
#language = None

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
Expand Down
88 changes: 88 additions & 0 deletions api-ref/source/v1/hosts.inc
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ Request
.. rest_parameters:: parameters.yaml

- host_id: host_id_path
- private: property_private

Response
--------
Expand Down Expand Up @@ -324,3 +325,90 @@ Response

.. literalinclude:: ../../../doc/api_samples/hosts/allocation-get-resp.json
:language: javascript

List Resource Properties
========================

.. rest_method:: GET v1/os-hosts/properties

Get all resource properties from host

**Response codes**

Normal response code: 200

Error response codes: Bad Request(400), Unauthorized(401), Forbidden(403),
Internal Server Error(500)

Request
-------

.. rest_parameters:: parameters.yaml

- detail: resource_property_detail
- all: resource_property_all

Response
--------

.. rest_parameters:: parameters.yaml

- resource_properties: resource_properties
- property: resource_properties_property
- private: resource_properties_private
- values: resource_properties_values

**Example of List Resource Properties Response**

.. literalinclude:: ../../../doc/api_samples/hosts/host-property-list.json
:language: javascript

**Example of List Resource Properties With Detail Response**

.. literalinclude:: ../../../doc/api_samples/hosts/host-property-list-detail.json
:language: javascript

Update Resource Properties
==========================

.. rest_method:: PATCH v1/os-hosts/properties/{property_name}

Update a host resource properties

**Response codes**

Normal response code: 200

Error response codes: Bad Request(400), Unauthorized(401), Forbidden(403),
Internal Server Error(500)

Request
-------

.. rest_parameters:: parameters.yaml

- property_name: property_name
- private: property_private

**Example of Update Resource Properties**

.. literalinclude:: ../../../doc/api_samples/hosts/host-property-update.json
:language: javascript

Response
--------

.. rest_parameters:: parameters.yaml

- created_at: created_at
- updated_at: updated_at
- id: resource_property_id
- resource_type: resource_property_resource_type
- property_name: resource_properties_property
- private: resource_property_private

**Example of List Resource Properties Response**

.. literalinclude:: ../../../doc/api_samples/hosts/host-property-update-res.json
:language: javascript

89 changes: 89 additions & 0 deletions api-ref/source/v1/parameters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@ lease_id_path:
in: path
required: true
type: string
property_name:
description: |
The name of the property.
in: path
required: true
type: string


# variables in query
Expand All @@ -57,6 +63,19 @@ allocation_reservation_id_query:
in: query
required: false
type: string
resource_property_all:
description: |
Whether to include all resource properties, public and private.
in: query
required: false
type: string
resource_property_detail:
description: |
Whether to include values along for each property and if the property
is private.
in: query
required: false
type: string


# variables in body
Expand Down Expand Up @@ -394,6 +413,13 @@ leases:
in: body
required: true
type: array
property_private:
description: |
Whether the property is private.

in: body
required: true
type: boolean
reservation:
description: |
A ``reservation`` object.
Expand Down Expand Up @@ -615,6 +641,69 @@ reservations_optional:
in: body
required: false
type: array
resource_properties:
description: |
A list of ``resource_property`` objects.

in: body
required: true
type: array
resource_properties_private:
description: |
Whether the property is private.

in: body
required: false
type: boolean
resource_properties_property:
description: |
The name of the property.

in: body
required: true
type: any
resource_properties_values:
description: |
A list of values for the property.

in: body
required: false
type: array
resource_property:
description: |
The updated ``resource_property`` object.

in: body
required: true
type: any
resource_property_id:
description: |
The updated ``resource_property`` UUID.

in: body
required: true
type: string
resource_property_private:
description: |
Whether the updated ``resource_property`` is private.

in: body
required: true
type: boolean
resource_property_property_name:
description: |
The updated ``resource_property`` property_name.

in: body
required: true
type: string
resource_property_resource_type:
description: |
The updated ``resource_property`` resource type.

in: body
required: true
type: string
updated_at:
description: |
The date and time when the object was updated.
Expand Down
17 changes: 2 additions & 15 deletions blazar/api/context.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,18 +27,5 @@ def ctx_from_headers(headers):
except TypeError:
raise exceptions.WrongFormat()

kwargs = {"user_id": headers['X-User-Id'],
"project_id": headers['X-Project-Id'],
"auth_token": headers['X-Auth-Token'],
"service_catalog": service_catalog,
"user_name": headers['X-User-Name'],
"project_name": headers['X-Project-Name'],
"roles": list(
map(str.strip, headers['X-Roles'].split(',')))}

# For v1 only, request_id and global_request_id will be available.
if headers.environ['PATH_INFO'].startswith('/v1'):
kwargs['request_id'] = headers.environ['openstack.request_id']
kwargs['global_request_id'] = headers.environ.get(
'openstack.global_request_id')
return context.BlazarContext(**kwargs)
return context.BlazarContext.from_environ(headers.environ,
service_catalog=service_catalog)
Empty file.
Loading