Skip to content

Conversation

@Pearl1594
Copy link
Contributor

@Pearl1594 Pearl1594 commented Feb 24, 2025

Description

This PR adds a new network plugin - Netris

The Netris Plugin introduces Netris as a network service provider in CloudStack to be able to create and manage Virtual Private Clouds (VPCs) in CloudStack, being able to orchestrate the following network functionalities:

  • Network segmentation with Netris-VXLAN isolation method
  • Routing between "public" IP and network segments with an ACS ROUTED mode offering
  • SourceNAT, DNAT, 1:1 NAT between "public" IP and network segments with an ACS NATTED mode offering
  • Routing between VPC network segments (tiers in ACS nomenclature)
  • Access Lists (ACLs) between VPC tiers and "public" network (TCP, UDP, ICMP) both as global egress rules and "public" IP specific ingress rules.
  • ACLs between VPC network tiers (TCP, UDP, ICMP)
  • External load balancing – between VPC network tiers and "public" IP
  • Internal load balancing – between VPC network tiers
  • CloudStack Virtual Router services (DHCP, DNS, UserData, Password Injection, etc…)

Doc PR: apache/cloudstack-documentation#482

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • build/CI
  • test (unit or integration test code)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Screenshots (if appropriate):

How Has This Been Tested?

How did you try to break this feature and the system with this change?

@codecov
Copy link

codecov bot commented Feb 24, 2025

Codecov Report

❌ Patch coverage is 29.93161% with 2664 lines in your changes missing coverage. Please review.
✅ Project coverage is 16.76%. Comparing base (22b753e) to head (b333d06).
⚠️ Report is 123 commits behind head on main.

Files with missing lines Patch % Lines
...a/org/apache/cloudstack/service/NetrisElement.java 11.84% 435 Missing and 4 partials ⚠️
...g/apache/cloudstack/service/NetrisServiceImpl.java 4.28% 333 Missing and 2 partials ⚠️
...ain/java/com/cloud/network/vpc/VpcManagerImpl.java 1.56% 311 Missing and 3 partials ⚠️
...org/apache/cloudstack/resource/NetrisResource.java 43.28% 144 Missing and 8 partials ⚠️
...va/com/cloud/network/element/NetrisProviderVO.java 0.00% 135 Missing ⚠️
...che/cloudstack/service/NetrisGuestNetworkGuru.java 32.98% 101 Missing and 27 partials ⚠️
...java/com/cloud/network/SDNProviderNetworkRule.java 46.25% 122 Missing ⚠️
...tack/agent/api/CreateOrUpdateNetrisACLCommand.java 0.00% 65 Missing ⚠️
.../cloudstack/service/NetrisProviderServiceImpl.java 44.14% 58 Missing and 4 partials ⚠️
...va/com/cloud/network/netris/NetrisNetworkRule.java 3.77% 51 Missing ⚠️
... and 96 more
Additional details and impacted files
@@             Coverage Diff              @@
##              main   #10458       +/-   ##
============================================
+ Coverage     3.89%   16.76%   +12.86%     
- Complexity       0    14285    +14285     
============================================
  Files          417     5767     +5350     
  Lines        33973   512731   +478758     
  Branches      6097    62391    +56294     
============================================
+ Hits          1324    85953    +84629     
- Misses       32491   417180   +384689     
- Partials       158     9598     +9440     
Flag Coverage Δ
uitests 3.85% <ø> (-0.05%) ⬇️
unittests 17.68% <29.93%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions
Copy link

This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch.

@borisstoyanov
Copy link
Contributor

@blueorangutan package

@blueorangutan
Copy link

@borisstoyanov a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 12617

Pearl1594 and others added 11 commits February 28, 2025 09:30
…d API class through CloudStack (#7)

* Delegate API classes creation to the SDK and simply invoke the desired API class through CloudStack

* Pass default auth scheme for now
)

* Support adding netris provider to CloudStack

* revert marvin change

* add license and perform session check when provider is added

* add license and remove unused import

* fix build failure - uunused imports

* address comments

* fix provider name

* add Netris network element

* add license

* Add netris management APIs and netris service provider

* add license

* revert change

* remove other network elements from Netris element

* fix api name in doc generator

* remove logs

* move session alive check to CheckHealthCommand exec

* Fix zone creation wizard to configure netris provider

* Upgrade GSON version - from PR 8756

* Add additional parametes to the add Netris provider API

* add netris as a host

* add additional params to the resoponse and update UI

* Rename site to site_name

* Create Netris VPC (#8)

* Delegate API classes creation to the SDK and simply invoke the desired API class through CloudStack (#7)

* Delegate API classes creation to the SDK and simply invoke the desired API class through CloudStack

* Pass default auth scheme for now

* Drop for_nsx and for_tungten columns in favour of checking the provider on the ntwserviceprovider map table

* Remove missing setForTungsten occurrence

* Remove forNsx from VPC offerings

* Create Netris VPC

* Fix VPC offerings listing and remove unused dao

* Create VPC fixes

* Upgrade GSON version - from PR 8756

* Fix VPC creation response by using the latest SDK code

* Fix unit test

* Remove unused import

* Fix NSX unit tests after refactoring

* Add Netris key to the VLAN Details table (#10)

* Add Netris key to the VLAN Details table

* update for_<provider> column to be generic

* Fix VPC and add IPAM allocation for the VPC CIDR (#9)

* Fix VPC and add IPAM allocation for the VPC CIDR

* Remove VPC logic

* Use zoneId accountId and domainId on resources creation

* Fix naming

* Fix VR public nic issue

* Fix Netris Public IP for VPC source NAT allocation

* Add Netris VPC Subnets and vNets (#11)

* Add Netris VPC Subnets and vNets

* fix compilation errors

* Add netris subnet

* refactor naming convention to differentiate between VPC tiers and Isolated networks

* revert marvin change

* fix constructor - build failure

* Add support to filter netris offerings, delete netris provider when zone is being deleted

* Fix build

* Fix VPC creation

* Fix vnet creation

* unnecesary log

Authored-by: Pearl Dsilva <[email protected]>
* Add support to delete VNets and Subnets

* Add support to delete vnet resources

* Add support to delete vnet resources

* extract code to method

---------

Co-authored-by: nvazquez <[email protected]>
* Set up Netris Public range on new zone addition

* Add dependency to calculate subnet containing a start and end IP

* Remove unused import

* Move dependency to the netris module

* Rename Netris IP range

* Refactor logic

* Revert "Refactor logic"

This reverts commit 7ec36a81320444c37e7bb914dd895060b663411b.

* Fix setup range after adding Netris Provider

* Fix VXLAN range adding on zone creation
* add zone params to accepts management vnet

* Release vxlan associated to the netris broadcast domain type

* handle update network broadcast uri
* Update Subnet purpose for Netris Public Traffic

* search for existing subnet of common purpose type
@github-actions
Copy link

This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch.

@Pearl1594
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@Pearl1594 a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

[SF] Trillian test result (tid-13864)
Environment: kvm-ol8 (x2), Advanced Networking with Mgmt server ol8
Total time taken: 63520 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr10458-t13864-kvm-ol8.zip
Smoke tests completed. 134 look OK, 8 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_01_non_strict_host_anti_affinity Failure 150.91 test_nonstrict_affinity_group.py
test_02_non_strict_host_affinity Error 91.05 test_nonstrict_affinity_group.py
test_01_add_primary_storage_disabled_host Error 39.70 test_primary_storage.py
test_01_primary_storage_scope_change Error 0.10 test_primary_storage_scope.py
test_01_sys_vm_start Failure 0.10 test_secondary_storage.py
ContextSuite context=TestCpuCapServiceOfferings>:setup Error 0.00 test_service_offerings.py
test_01_deploy_vm_on_specific_host Error 0.15 test_vm_deployment_planner.py
test_04_deploy_vm_on_host_override_pod_and_cluster Error 0.15 test_vm_deployment_planner.py
ContextSuite context=TestDeployVMFromSnapshotOrVolume>:setup Error 0.00 test_vm_lifecycle_with_snapshot_or_volume.py
test_06_download_detached_volume Failure 318.89 test_volumes.py

@blueorangutan
Copy link

Packaging result [SF]: ✖️ el8 ✖️ el9 ✔️ debian ✖️ suse15. SL-JID 14348

@Pearl1594 Pearl1594 closed this Jul 24, 2025
@github-project-automation github-project-automation bot moved this from In Progress to Done in Apache CloudStack 4.21.0 Jul 24, 2025
@Pearl1594 Pearl1594 reopened this Jul 24, 2025
@Pearl1594 Pearl1594 moved this from Done to In Progress in Apache CloudStack 4.21.0 Jul 24, 2025
@Pearl1594
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@Pearl1594 a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 14354

@sureshanaparti
Copy link
Contributor

@blueorangutan test

@blueorangutan
Copy link

@sureshanaparti a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests

@blueorangutan
Copy link

[SF] Trillian test result (tid-13878)
Environment: kvm-ol8 (x2), Advanced Networking with Mgmt server ol8
Total time taken: 60543 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr10458-t13878-kvm-ol8.zip
Smoke tests completed. 141 look OK, 1 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_list_zones_metrics Error 0.25 test_metrics_api.py

@github-project-automation github-project-automation bot moved this from In Progress to Done in Apache CloudStack 4.21.0 Jul 25, 2025
@sureshanaparti sureshanaparti moved this from Done to In Progress in Apache CloudStack 4.21.0 Jul 25, 2025
@sureshanaparti sureshanaparti merged commit 0d4147f into main Jul 25, 2025
96 of 115 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in Apache CloudStack 4.21.0 Jul 25, 2025
@sureshanaparti sureshanaparti deleted the netris-integration-upstream branch July 25, 2025 09:57
@sonarqubecloud
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
15.2% Coverage on New Code (required ≥ 40%)

See analysis details on SonarQube Cloud

dhslove pushed a commit to ablecloud-team/ablestack-cloud that referenced this pull request Aug 1, 2025
The Netris Plugin introduces Netris as a network service provider in CloudStack to be able to create and manage Virtual Private Clouds (VPCs) in CloudStack, being able to orchestrate the following network functionalities:

- Network segmentation with Netris-VXLAN isolation method
- Routing between "public" IP and network segments with an ACS ROUTED mode offering
- SourceNAT, DNAT, 1:1 NAT between "public" IP and network segments with an ACS NATTED mode offering
- Routing between VPC network segments (tiers in ACS nomenclature)
- Access Lists (ACLs) between VPC tiers and "public" network (TCP, UDP, ICMP) both as global egress rules and "public" IP specific ingress rules.
- ACLs between VPC network tiers (TCP, UDP, ICMP)
- External load balancing – between VPC network tiers and "public" IP
- Internal load balancing – between VPC network tiers
- CloudStack Virtual Router services (DHCP, DNS, UserData, Password Injection, etc…)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

No open projects
Status: Done

Development

Successfully merging this pull request may close these issues.

7 participants