• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

noironetworks / aci-containers / 11978
64%
master: 63%

Build:
Build:
LAST BUILD BRANCH: conflicting-named-port-resolutions
DEFAULT BRANCH: master
Ran 22 May 2026 09:40AM UTC
Jobs 1
Files 48
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

22 May 2026 09:24AM UTC coverage: 63.935% (+0.2%) from 63.735%
11978

push

travis-pro

jeffinkottaram
Resolve named port conflicts across sibling NPs in shared HPP

When HPP optimization is enabled, multiple NetworkPolicies with
identical specs (same hash excluding PodSelector) share a single HPP
object. If these sibling NPs have named ports that resolve to different
numeric ports (e.g., NP1's "http" -> 80, NP2's "http" -> 8080), only the
last-processed NP's rules survived — the other sibling's rules were
silently dropped on each rebuild.

This happened because the shared HPP was rebuilt from scratch each time
any sibling NP was reprocessed, with no mechanism to preserve rules
contributed by other siblings.

Changes:
- Rule naming uses ingress-rule-index + proto-port (e.g.,
  "0-ipv4__tcp-80") instead of NP name, so sibling NPs produce stable,
  identical names for the same port
- Added per-NP ingress rule caching in hppReference.NpIngressRules to
  track which rules belong to which NP
- After generating rules for an NP, merges cached sibling NP rules into
  the subject before writing
- On NP deletion, requeues a sibling so the HPP is rewritten without
  stale entries
- Fixed MO leak: ClearApicObjects when removeFromHppCache returns no
  remaining hppRef
- Fixed nil-pointer panic in networkPolicyDeleted when
  DeletedFinalStateUnknown wraps a non-NetworkPolicy object
- Removed unused np parameter from buildLocalNetPolSubjRules

Test changes:
- Added TestNetworkPolicyMultipleNPsSharedHPPNamedPorts and
  TestNetworkPolicyMultipleNPsSharedHPPNamedPortsDirect covering the
  sibling-NP merge for both APIC and HPP-Direct paths
- Updated existing HppOptimize test expectations for new rule naming
  and buildLocalNetPolSubjRules signature

136 of 151 new or added lines in 1 file covered. (90.07%)

5 existing lines in 2 files now uncovered.

13675 of 21389 relevant lines covered (63.93%)

0.73 hits per line

Uncovered Changes

Lines Coverage ∆ File
15
83.12
0.78% pkg/controller/network_policy.go

Coverage Regressions

Lines Coverage ∆ File
3
83.12
0.78% pkg/controller/network_policy.go
2
71.25
0.0% pkg/hostagent/snats.go
Jobs
ID Job ID Ran Files Coverage
1 11978.1 (DEFAULT_BRANCH=master GOPROXY=https://proxy.golang.org|https://goproxy.io|direct) 22 May 2026 09:40AM UTC 48
63.93
Travis Job 11978.1
Source Files on build 11978
  • Tree
  • List 48
  • Changed 3
  • Source Changed 0
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Travis Build #11978
  • d3a814b7 on github
  • Prev Build on conflicting-named-port-resolutions (#11974)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc