Skip to content

Remove dead code and tested changes using OnRamp#528

Merged
gab-arrobo merged 1 commit intoomec-project:mainfrom
gab-arrobo:remove-deadcode
Mar 9, 2026
Merged

Remove dead code and tested changes using OnRamp#528
gab-arrobo merged 1 commit intoomec-project:mainfrom
gab-arrobo:remove-deadcode

Conversation

@gab-arrobo
Copy link
Contributor

No description provided.

Signed-off-by: Arrobo, Gabriel <gabriel.arrobo@intel.com>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes unused/dead code paths across the SMF codebase (QoS helpers, router constructors, PFCP datapath helpers, NGAP utilities, and assorted context/DB helpers) and relocates sample SM Policy Decision builder logic into a dedicated test file.

Changes:

  • Deleted multiple unused functions/stubs (QoS rule/flow helpers, PFCP datapath helpers, router constructors, NGAP/context/db helpers).
  • Removed obsolete files (pdusession/dummy_server.go, context/traffic_control_data.go).
  • Added a new QoS test helper module (qos/policy_builders_test.go) with sample policy decision builders and a small sanity test.

Reviewed changes

Copilot reviewed 19 out of 19 changed files in this pull request and generated no comments.

Show a summary per file
File Description
qos/qos_utility.go Removes unused String() methods and in-file sample/test data builders.
qos/qos_rule.go Removes unused default QoS rule builder and unimplemented modify/delete stubs.
qos/qos_flow.go Removes unused QoS flow description helper/stub functions and unused E-bit setters.
qos/policy_builders_test.go Adds test-only sample policy decision builders and a sanity test.
producer/datapath.go Removes unused PFCP rule send/update helpers; keeps consolidated SendPFCPRules.
pdusession/routers.go Removes unused NewRouter constructor (service wiring uses AddService).
pdusession/dummy_server.go Deletes unused dummy server implementation.
oam/routers.go Removes unused NewRouter constructor.
eventexposure/routers.go Removes unused NewRouter constructor.
callback/routers.go Removes unused NewRouter constructor.
logger/logger.go Removes unused GetLogger() accessor.
fsm/handler.go Removes unused active-state create handler stub.
context/traffic_control_data.go Deletes unused TrafficControlData wrapper type/file.
context/sm_context.go Removes unused SM context counter and accessor.
context/ngap_handler.go Removes unused NGAP unsuccessful-transfer handler.
context/ngap_build.go Removes unused NGAP unsuccessful-transfer builder.
context/db.go Removes unused DB helper and test-only in-memory cleanup utilities.
context/context.go Removes unused UPF extraction helper.
consumer/sm_policy.go Removes unused modify stub.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link

@andybavier andybavier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@gab-arrobo gab-arrobo merged commit d1a6f9d into omec-project:main Mar 9, 2026
16 checks passed
@gab-arrobo gab-arrobo deleted the remove-deadcode branch March 9, 2026 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants