Skip to content
This repository was archived by the owner on Feb 27, 2020. It is now read-only.

Conversation

@richardwhiuk
Copy link
Contributor

Seb,

We'd like to allow non default sproutlets to have their URI and Port be listened on by the stack.

To do this, we split startup of the PJSIP into two sections, init_stack and start_stack, where start_stack is responsible for creation of transports including ports.

Instead of setting up sproutlet_ports and sproutlet_uris primarily via the configuration options, we use the ->port() and ->uri() options on Sproutlet.

Also including in this pull request is some generic tidying up in main.cpp:

  • Moving address family determination out of the stack and into main.cpp
  • Separating out defaulting and validating options into separate functions to make the code neater

I've tested Sprout and Bono on EC2, ensuring that they spin up correctly and listen on the correct ports.

Copy link
Contributor

@sebrexmetaswitch sebrexmetaswitch left a comment

Choose a reason for hiding this comment

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

I think this looks fine, but it's quite hard to spot the actual changes because so much code has just moved.

Have you tested using non-default hostnames and ports for the various default sproutlets still works?

And have you tested that setting the hostname and port for a non-default sproutlet actually opens that port up?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants