Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
101 commits
Select commit Hold shift + click to select a range
abb4195
Move new requests to its own directory
sajith Sep 3, 2024
44163e4
Drop importlib-resources dependency
sajith Sep 3, 2024
374396a
Call the test data files V1, not V2
sajith Sep 3, 2024
4f0fda6
Rename test requests for consistency
sajith Sep 3, 2024
846c974
Reformat v1 connection request files
sajith Sep 3, 2024
07ac1d6
Add the very basic pydantic ConnectionRequestV1 model
sajith Sep 3, 2024
8600def
Add the basic v1 connection request
sajith Sep 3, 2024
4338b87
Add a test case for connection request handling with pydantic
sajith Sep 3, 2024
1f48ffb
Reformat
sajith Sep 3, 2024
518caff
Update comment
sajith Sep 6, 2024
6fc9012
Only export the main model
sajith Sep 6, 2024
cfd0dff
Add a connection request test case
sajith Sep 6, 2024
8c2226b
Check that VLANs are in [1,4095] range
sajith Sep 6, 2024
6990bff
Add more checks on VLANs
sajith Sep 6, 2024
9f797db
Add some checks for endpoints
sajith Sep 6, 2024
9688f84
Add optional fields
sajith Sep 6, 2024
69eaba6
Add more tests
sajith Sep 6, 2024
d6181f8
Make fields frozen
sajith Sep 7, 2024
70b31e1
Reformat
sajith Sep 7, 2024
bee74e9
Fix typo
sajith Sep 7, 2024
d9a5427
Rename tests
sajith Sep 7, 2024
20f39b4
Test that connection request fields are not mutable
sajith Sep 7, 2024
f009631
Use parse_file() when possible
sajith Sep 10, 2024
6d55e4e
Test with invalid vlan strings
sajith Sep 10, 2024
16e17a9
Add more tests
sajith Sep 10, 2024
2909897
Return the string value after validation
sajith Sep 10, 2024
0dedb79
Remove dead code
sajith Sep 10, 2024
0253aa7
Avoid a redundant check
sajith Sep 10, 2024
5f8cd5e
Avoid redundant else arm
sajith Sep 10, 2024
4394bdb
Add another hint
sajith Sep 10, 2024
e5523b2
Reformat
sajith Sep 10, 2024
e289d31
Validate emails also
sajith Sep 10, 2024
336a759
Add tests for notification email validation
sajith Sep 10, 2024
3914803
Validate requests that contain "vlan": "all"
sajith Sep 10, 2024
ce7bc09
Require all requested VLAN ranges to be the same
sajith Sep 10, 2024
698351e
Really require all requested ranges to be the same
sajith Sep 10, 2024
06708cc
Update tests for requests containing VLAN ranges
sajith Sep 10, 2024
d6ce5f8
Add a TODO item
sajith Sep 10, 2024
bc48bc7
Use valid VLANs in example connection request
sajith Sep 10, 2024
30dd99c
Validate the example test request
sajith Sep 10, 2024
a120971
Use valid VLAN in sample connection request
sajith Sep 10, 2024
b40c8f3
Rename a test
sajith Sep 10, 2024
c8b7877
Add docstring
sajith Sep 10, 2024
63d2719
Describe tests
sajith Sep 10, 2024
e71cb36
Remove duplicate test
sajith Sep 10, 2024
128b835
Describe tests correctly
sajith Sep 10, 2024
fd79c49
Test with two notification emails
sajith Sep 10, 2024
5bafe5a
Test ranges like n1:n2 where n2 < n1
sajith Sep 10, 2024
1a1851a
Add a model to represent connection requests in original format
sajith Sep 10, 2024
4cda1c0
Add tests for the existing v0 connection request samples
sajith Sep 10, 2024
1f333e3
Update v0 fields
sajith Sep 10, 2024
84771ad
Handle more v0 connection request fields
sajith Sep 10, 2024
ca4338c
Move v0 connection request tests to its own class
sajith Sep 10, 2024
06da599
Avoid deprecated parse_file() in v0 tests
sajith Sep 10, 2024
ef2c250
Avoid deprecated parse_file()
sajith Sep 10, 2024
68cb5ee
Run isort
sajith Sep 10, 2024
f561b58
Rename a test case to avoid redefinition
sajith Sep 10, 2024
cfbf717
Require some values have to be positive integers
sajith Sep 14, 2024
89160a1
Mark non-optional fields as such
sajith Sep 14, 2024
9a45947
Mark optional fields as such
sajith Sep 14, 2024
7543d01
Rename a variable for clarity
sajith Sep 14, 2024
bf634dd
Move required fields up
sajith Sep 14, 2024
f161e1e
Switch required bandwidth to original default
sajith Sep 14, 2024
32f6ab4
Merge remote-tracking branch 'origin/main' into 148.pydantic-connecti…
sajith Dec 9, 2024
b3776ae
Merge remote-tracking branch 'origin/main' into 148.pydantic-connecti…
sajith Mar 12, 2025
b6851a2
Use correct assertion
sajith Mar 12, 2025
817b815
Move v0 requests to its own subdirectory
sajith Mar 12, 2025
16b4e52
Give v0 requests a suffix
sajith Mar 12, 2025
e17d17e
Remove Python 3.9 and 3.10 from tox env list
sajith Mar 13, 2025
4aa4d33
Validate start_time and end_time
sajith Mar 13, 2025
08dd4d3
Move v1.0 test request under v1.0 directory
sajith Mar 13, 2025
422aa63
Rename variables for consistency
sajith Mar 13, 2025
71cd6a5
Rename to avoid shadowing a variable
sajith Mar 13, 2025
fc180c1
Add missing import
sajith Mar 14, 2025
85aa2d0
Add another test: l2vpn-amlight-sax
sajith Mar 14, 2025
cf1bd9a
Make test pass with a workaround
sajith Mar 14, 2025
4af027e
Add some test cases for Scheduling
sajith Mar 14, 2025
654606f
Keep scheduling tests in its own class
sajith Mar 14, 2025
9f2e0e2
Run isort
sajith Mar 14, 2025
86a48df
Add a ConnectionRequest class
sajith Mar 14, 2025
9ac3249
Remove duplicated copy pasta
sajith Mar 14, 2025
3166f99
Run isort
sajith Mar 14, 2025
d0ff427
Fix copy-pasta mistake
sajith Mar 14, 2025
482c946
Run isort
sajith Mar 17, 2025
ceeff12
Add fields PCE needs to ConnectionRequestV1
sajith Mar 19, 2025
6f73f67
Add an optional id field to ConnectionRequestV1
sajith Mar 20, 2025
6d1124a
Handle vlan
sajith Mar 20, 2025
63eac90
Compute the remaining fields
sajith Mar 20, 2025
c9cad53
Add max_number_oxps
sajith Mar 20, 2025
d8455c7
Use better return types
sajith Mar 20, 2025
56d29db
Do more checks
sajith Mar 20, 2025
675a956
Make connection_request.Port consistent with models.port.Port
sajith Mar 21, 2025
dd3b0fb
Export more models
sajith Mar 21, 2025
f7fd7f1
Update a comment
sajith Mar 21, 2025
5accb79
Remove duplicated test
sajith Mar 21, 2025
1c90ef0
Remove commented out cruft
sajith Mar 21, 2025
31370c2
Revert to original max_delay value
sajith Mar 22, 2025
fe64a6f
Remove TODO
sajith Mar 22, 2025
994540a
Use generics for type hinting
sajith Mar 24, 2025
f86f93c
Pacify mypy
sajith Mar 24, 2025
2b3977b
Use correct type hints
sajith Mar 24, 2025
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
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ classifiers = [
dependencies = [
"grenml",
"networkx",
"pydantic[email]",
"transitions",
"fastapi",
"pytz",
"importlib-resources; python_version < '3.9'",
]

[project.urls]
Expand Down
34 changes: 0 additions & 34 deletions src/sdx_datamodel/data/requests/test-l2vpn-p2p-v2.json

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"name": "new-connection",
"id": "urn:sdx:connection:ampath.net:Ampath3:50-sax.net:Sax01:41",
"endpoints": [
{
"port_id": "urn:sdx:port:amlight.net:A1:3",
"vlan": "101"
},
{
"port_id": "urn:sdx:port:zaoxi:B2:1",
"vlan": "101"
}
],
"description": "a test circuit",
"scheduling": {
"start_time": "2024-06-24T01:00:00.000Z",
"end_time": "2024-06-26T01:00:00.000Z"
},
"qos_metrics": {
"min_bw": {
"value": 12,
"strict": true
},
"max_delay": {
"value": 50,
"strict": false
},
"max_number_oxps": {
"value": 7,
"strict": true
}
},
"notifications": [
{
"email": "muhaziz@fiu.edu"
}
]
}
38 changes: 38 additions & 0 deletions src/sdx_datamodel/data/requests/v1.0/test-request-l2vpn-p2p.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"name": "new-connection",
"id": "urn:sdx:connection:ampath.net:Ampath3:50-sax.net:Sax01:41",
"endpoints": [
{
"port_id": "urn:sdx:port:ampath.net:Ampath3:50",
"vlan": "100"
},
{
"port_id": "urn:sdx:port:sax.net:Sax01:41",
"vlan": "100"
}
],
"description": "a test circuit",
"scheduling": {
"start_time": "2024-06-24T01:00:00.000Z",
"end_time": "2024-06-26T01:00:00.000Z"
},
"qos_metrics": {
"min_bw": {
"value": 12,
"strict": true
},
"max_delay": {
"value": 4,
"strict": false
},
"max_number_oxps": {
"value": 7,
"strict": true
}
},
"notifications": [
{
"email": "muhaziz@fiu.edu"
}
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"name": "VLAN between AMPATH/300 and TENET/150",
"endpoints": [
{
"port_id": "urn:sdx:port:tenet.ac.za:Tenet03:50",
"vlan": "150"
},
{
"port_id": "urn:sdx:port:ampath.net:Ampath3:50",
"vlan": "300"
}
]
}
Loading