having same delivery_sm with same MessageId every time

226 Views Asked by At

I'm trying to implement smpp solution using opensmpp. Messages are sent succefully but for delivery receipts, I get only for some submited message and the same delivery receipts came several times. Can someone help me please.

private void receiveSms() {
    try {
        if (session != null && session.isBound()) {
            PDU pdu = session.receive(1500);

            if (pdu instanceof DeliverSM) {
                DeliverSM received = (DeliverSM) pdu;
                if (received.getEsmClass() == 0) {                                                          
                  // new message
                    System.out.println("RECEIVE NEW MESSAGE " + received.debugString());
                } else {
                 //delivry Repport
                    System.out.println("RECEIVE NEW DELIVERED REPORT: " + received.debugString());

                }
            }
        }

...

1

There are 1 best solutions below

0
On

I am not familliar with opensmpp, but note that the messageId in norm smpp34 is still NULL, The messageId associated to SUBMIT_SM is in DELIVER_SM "receipted_message_id" field, or in the short_message if the appendixB is used,

If the "receipted_message_id" field has always the same value, you should check about the SMSC configuration/code, the DELIVER_SM is generated there