Package org.smpp.pdu

Examples of org.smpp.pdu.SubmitSMResp


                    LOGGER.debug("Submit request " + request.debugString());
                }

                // Get a session from the pool and attempt to send the message.
                boolean submitted = false;
                SubmitSMResp response = null;
                while (!submitted) {
                    Session SMSSession = (Session) sessionPool.borrowObject();
                    try {
                        response = SMSSession.submit(request);
                        submitted = true;
                        sessionPool.returnObject(SMSSession);
                    } catch (Exception e) {
                        LOGGER.warn("message-submit-failure-retrying", e.getMessage());
                        sessionPool.invalidateObject(SMSSession);
                    }
                }

                if(response!=null){
                    if(LOGGER.isDebugEnabled()) {
                        LOGGER.debug("Submit response " +
                                response.debugString());
                    }
                    if (response.getCommandStatus() != Data.ESME_ROK) {
                        final MessageRecipient failedRecipient =
                            message.getMessageRecipient(i);
                        failedRecipient.setFailureReason(
                            localizer.format("message-submit-failure-with-status",
                                new Integer(response.getCommandStatus())));
                        failedRecipients.add(failedRecipient);
                    }
                }
            } catch (Exception e) {
                final MessageRecipient failedRecipient =
View Full Code Here

TOP

Related Classes of org.smpp.pdu.SubmitSMResp

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.