RestComm / smscgateway

RestComm SMS Gateway (SMSC) to send/receive SMS from/to Operators Network (GSM)
http://www.restcomm.com/
GNU Affero General Public License v3.0
127 stars 111 forks source link

mproc rules: adding drop / reject actions #227

Closed vetss closed 7 years ago

vetss commented 7 years ago

We need to add 2 actions for mproc rules:

1) dropOnArrival true|false - lead PostArrivalProcessor.dropMessage() if "true" (false == disabling) 2) rejectOnArrival none | default | unexpectedDataValue | systemFailure | throttling | facilityNotSupported - leads:

Meaning of "dropOnArrival" - message will be dropped but a sender receives a success response Meaning of "rejectOnArrival" - message will be dropped but a sender receives an error response

Values for "reject" unexpectedDataValue:

systemFailure:

throttling:

facilityNotSupported:

default (only for info, we reuse a method without parameters):

vetss commented 7 years ago

Partly fixed by:

https://github.com/RestComm/smscgateway/commit/7fa889de8bfb5d80bf4041d9a575c4444b14ed66

vetss commented 7 years ago

Hello @satanatoly

I agree with functionality implementation but I have one remark for configuring of "Reject upon arrival to the server".

1) At the creating rule part (GUI) you allow "" and "NONE" values for "no reject action". And I do not see how can I remove the option in the rule update. I can configure "NONE" but this "NONE" value will still present in xml config (the proper behaviour is when we turn off the option then no option mentioning in xml config / CLI show commans - else we will have bery unclear to read)

I suggest that for both null / NONE option we will not have write data into xml / show in CLI.

2) GUI edit part HELP must contain a list of possible values - check "Destination Type Of Number (TON)" help for example.

satanatoly commented 7 years ago

Fixed by: 7fa889de8bfb5d80bf4041d9a575c4444b14ed66 75da1286dd9a5fc3cb27b4bdb6be080cb9794dcb