-
-
Notifications
You must be signed in to change notification settings - Fork 77
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Does not allow you to create Failover MT Route #48
Comments
Hey @RyanPrice-King |
main/core/smpp/mtrouter.py
I noticed with this that the code allows for accidental overwrites of an existing route that has the same order number. Up to you, but I would prefer myself to prevent accidental route replacement.
To get the try/catch to work you may have to remove ', None' from: You can either do this change or not, or even code it to handle the None response. That is up to you. The FailoverMTRoute is configured exactly the same as the RoundRobinMTroute and also requires at least 2 connectors.
This might not be a complete copy/paste for you and the morouter.py would require the same kind of changes, but gives you an idea :). It is not possible to use a FailoverMORoute with a mix of connectors, example: connectors smpps(user_1);http(http_1);http(http_3), so you would only have HTTP MO connectors assigned to the FailoverMORoute and use a filter for SMPP connectors. When an MO is received from one of the SMPP connectors, it validates against the connector filter assigned to the FailoverMORoute and sends down one of the HTTP connectors. You can do this with the RoundRobinMORoute though, but I do not see a problem with still using filters for the smpp connectors that route to multiple HTTP based on the MO filters. Then the new options need to be added to frontends I assume: and I think you have to add to models. I have not done a lot of python and especially front end with python, so I am hoping you would be able to take it from here. |
|
Hi @RyanPrice-King |
OK for some reason with the old master branch and 2.0.2, I cannot create RoundRobinMTRoute or FailoverMTRoute as it says requires 2 connectors error. Even when I drag highlight both connectors. I have printed the connectors from mtrouter.py and it is only passing the second choice in the list from the frontend. So the connectors being passed is only 1, even though I select more than 1 in the front end. |
DefaultRoute: A route without a filter, this one can only set with the lowest order to be a default/fallback route
StaticMTRoute: A basic route with Filters and one Connector
RandomRoundrobinMTRoute: A route with Filters and many Connectors, will return a random Connector if its Filters are matching, can be used as a load balancer route
FailoverMTRoute: A route with Filters and many Connectors, will return an available (connected) Connector if its Filters are matched
The text was updated successfully, but these errors were encountered: