omec-project / pfcpsim

PFCP client simulator used for UPF testing
20 stars 18 forks source link

[SDFAB-1007] Drop CLI interactive mode in favor of gRPC and Protobuf #18

Closed EmanueleGallone closed 2 years ago

EmanueleGallone commented 2 years ago

Dropping interactive mode using CLI with stdIN in favor of a client-server CTL using protobuf and gRPC.

This would allow us to drop shell scripts in UP4 using screen while making mock-smf interaction easier. Should improve TestON tests as well.

EmanueleGallone commented 2 years ago

Basic Schema:

image

osinstom commented 2 years ago

hey @EmanueleGallone I think we should add the diagram to README

EmanueleGallone commented 2 years ago

hey @EmanueleGallone I think we should add the diagram to README

Yes. Will do

EmanueleGallone commented 2 years ago

manually tested with UP4 environment, using traffic test:

image

EmanueleGallone commented 2 years ago

I think we map the user interface of Python-based mock-smf pretty well. I'm ok to merge it and start using it in this shape, once review comments are addressed.

Nevertheless, I still think that we could improve the user interface in the future. I'm not sure if it makes a lot of sense to have separate create/modify, etc. commands. I see the issues with keeping the state, etc. I'm wondering if having a more abstracted usage model would make sense. For instance:

  • attach -n N command, where N means the number of UEs to attach. The pfcpsim service would have to deal with create/modify on its own, hiding it from a user. This command should also print IDs of created sessions.
  • detach all detach <list of IDs> - detaches (PFCP Session Deletion) all or selected sessions.

Anyway, this is just a rough idea for future.

I like it! I think it would be a great approach for future improvements