4 new revisions:

Revision: 5fc2c104b1a8
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 07:21:20 2013
Log: TCAP bug: possible double local transactionId assignment while high lo...
http://code.google.com/p/jss7/source/detail?r=5fc2c104b1a8

Revision: f2e6ceab23ac
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 07:22:31 2013
Log:      Simulator update: bulk Mt SMS mode for SmsClient
http://code.google.com/p/jss7/source/detail?r=f2e6ceab23ac

Revision: 8ea5ae8662cc
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 08:59:48 2013
Log:      Simulator update: bulk Mt SMS mode for SmsClient 2
http://code.google.com/p/jss7/source/detail?r=8ea5ae8662cc

Revision: 87cdc10e6bb6
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 09:22:33 2013
Log:      Merge remote-tracking branch 'origin/2.0.x_cap22' into 2.0.x
http://code.google.com/p/jss7/source/detail?r=87cdc10e6bb6

==============================================================================
Revision: 5fc2c104b1a8
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 07:21:20 2013
Log: TCAP bug: possible double local transactionId assignment while high load
case
http://code.google.com/p/jss7/source/detail?r=5fc2c104b1a8

Modified:
/tcap/tcap-impl/src/main/java/org/mobicents/protocols/ss7/tcap/TCAPProviderImpl.java

=======================================
--- /tcap/tcap-impl/src/main/java/org/mobicents/protocols/ss7/tcap/TCAPProviderImpl.java Fri Jan 4 10:52:03 2013 +++ /tcap/tcap-impl/src/main/java/org/mobicents/protocols/ss7/tcap/TCAPProviderImpl.java Sun May 26 07:21:20 2013
@@ -249,18 +249,18 @@
                        throw new NullPointerException("RemoteAddress must not be 
null");
                }

-               Long id = this.getAvailableTxId();
-               if (structured) {
-                       synchronized (this.dialogs) {
+               synchronized (this.dialogs) {
+                       Long id = this.getAvailableTxId();
+                       if (structured) {
DialogImpl di = new DialogImpl(localAddress, remoteAddress, id, structured, this._EXECUTOR, this, seqControl, this.stack.getPreviewMode());

                                this.dialogs.put(id, di);

                                return di;
+                       } else {
+ DialogImpl di = new DialogImpl(localAddress, remoteAddress, id, structured, this._EXECUTOR, this, seqControl, this.stack.getPreviewMode());
+                               return di;
                        }
-               } else {
- DialogImpl di = new DialogImpl(localAddress, remoteAddress, id, structured, this._EXECUTOR, this, seqControl, this.stack.getPreviewMode());
-                       return di;
                }
        }


==============================================================================
Revision: f2e6ceab23ac
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 07:22:31 2013
Log:      Simulator update: bulk Mt SMS mode for SmsClient
http://code.google.com/p/jss7/source/detail?r=f2e6ceab23ac

Modified:
/tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientConfigurationData.java /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientMan.java /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientManMBean.java /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientStandardManMBean.java /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsServerMan.java /tools/simulator/gui/src/main/java/org/mobicents/protocols/ss7/tools/simulatorgui/tests/sms/TestSmsClientParamForm.java

=======================================
--- /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientConfigurationData.java Thu Apr 18 09:01:44 2013 +++ /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientConfigurationData.java Sun May 26 07:22:31 2013
@@ -22,6 +22,7 @@

 package org.mobicents.protocols.ss7.tools.simulator.tests.sms;

+import javolution.text.CharArray;
 import javolution.xml.XMLFormat;
 import javolution.xml.stream.XMLStreamException;

@@ -52,6 +53,7 @@
protected static final String SRI_INFORM_SERVICE_CENTER = "sriInformServiceCenter"; protected static final String SRI_SC_ADDRESS_NOT_INCLUDED = "sriScAddressNotIncluded";
        protected static final String MT_FSM_REACTION = "mtFSMReaction";
+ protected static final String ONE_NOTIFICATION_FOR_100_DIALOGS = "oneNotificationFor100Dialogs";

protected AddressNature addressNature = AddressNature.international_number;
        protected NumberingPlan numberingPlan = NumberingPlan.ISDN;
@@ -68,6 +70,7 @@
protected SRIInformServiceCenter sriInformServiceCenter = new SRIInformServiceCenter(SRIInformServiceCenter.MWD_NO);
        protected boolean sriScAddressNotIncluded = false;
protected MtFSMReaction mtFSMReaction = new MtFSMReaction(MtFSMReaction.VAL_RETURN_SUCCESS);
+       protected boolean oneNotificationFor100Dialogs = false;

        public AddressNature getAddressNature() {
                return addressNature;
@@ -180,6 +183,14 @@
        public void setSmsCodingType(SmsCodingType smsCodingType) {
                this.smsCodingType = smsCodingType;
        }
+
+       public boolean isOneNotificationFor100Dialogs() {
+               return oneNotificationFor100Dialogs;
+       }
+
+ public void setOneNotificationFor100Dialogs(boolean oneNotificationFor100Dialogs) {
+               this.oneNotificationFor100Dialogs = 
oneNotificationFor100Dialogs;
+       }

protected static final XMLFormat<TestSmsClientConfigurationData> XML = new XMLFormat<TestSmsClientConfigurationData>(TestSmsClientConfigurationData.class) {

@@ -187,6 +198,8 @@
                        xml.setAttribute(SMSC_SSN, srv.smscSsn);
xml.setAttribute(SRI_SC_ADDRESS_NOT_INCLUDED, srv.sriScAddressNotIncluded);

+ xml.setAttribute(ONE_NOTIFICATION_FOR_100_DIALOGS, srv.oneNotificationFor100Dialogs);
+
                        xml.add(srv.serviceCenterAddress, 
SERVICE_CENTER_ADDRESS, String.class);
                        xml.add(srv.sriResponseImsi, SRI_RESPONSE_IMSI, 
String.class);
                        xml.add(srv.sriResponseVlr, SRI_RESPONSE_VLR, 
String.class);
@@ -207,6 +220,10 @@
                        srv.smscSsn = xml.getAttribute(SMSC_SSN).toInt();
srv.sriScAddressNotIncluded = xml.getAttribute(SRI_SC_ADDRESS_NOT_INCLUDED).toBoolean();

+                       CharArray chArr = 
xml.getAttribute(ONE_NOTIFICATION_FOR_100_DIALOGS);
+                       if (chArr != null)
+                               srv.oneNotificationFor100Dialogs = 
chArr.toBoolean();
+
srv.serviceCenterAddress = (String) xml.get(SERVICE_CENTER_ADDRESS, String.class);
                        srv.sriResponseImsi = (String) 
xml.get(SRI_RESPONSE_IMSI, String.class);
                        srv.sriResponseVlr = (String) xml.get(SRI_RESPONSE_VLR, 
String.class);
=======================================
--- /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientMan.java Wed May 8 07:25:28 2013 +++ /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientMan.java Sun May 26 07:22:31 2013
@@ -106,6 +106,7 @@
        private int countSriReq = 0;
        private int countSriResp = 0;
        private int countMtFsmReq = 0;
+       private int countMtFsmReqNot = 0;
        private int countMtFsmResp = 0;
        private int countMoFsmReq = 0;
        private int countMoFsmResp = 0;
@@ -257,6 +258,17 @@
this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().setMtFSMReaction(val);
                this.testerHost.markStore();
        }
+
+       @Override
+       public boolean isOneNotificationFor100Dialogs() {
+ return this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs();
+       }
+
+       @Override
+       public void setOneNotificationFor100Dialogs(boolean val) {
+ this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().setOneNotificationFor100Dialogs(val);
+               this.testerHost.markStore();
+       }

        @Override
        public void putSRIReaction(String val) {
@@ -424,19 +436,19 @@
                sb.append(countMtFsmReq);
                sb.append(", countMtFsmResp-");
                sb.append(countMtFsmResp);
-               sb.append("<br> countMoFsmReq-");
+               sb.append("<br>countMoFsmReq-");
                sb.append(countMoFsmReq);
                sb.append(", countMoFsmResp-");
                sb.append(countMoFsmResp);
                sb.append(", countIscReq-");
                sb.append(countIscReq);
-               sb.append(", countRsmdsReq-");
+               sb.append("<br>countRsmdsReq-");
                sb.append(countRsmdsReq);
                sb.append(", countRsmdsResp-");
                sb.append(countRsmdsResp);
                sb.append(", countAscReq-");
                sb.append(countAscReq);
-               sb.append(", countAscResp-");
+               sb.append("<br>countAscResp-");
                sb.append(countAscResp);
                sb.append(", countErrRcvd-");
                sb.append(countErrRcvd);
@@ -447,6 +459,21 @@
        }

        public boolean start() {
+               this.countSriReq = 0;
+               this.countSriResp = 0;
+               this.countMtFsmReq = 0;
+               this.countMtFsmReqNot = 0;
+               this.countMtFsmResp = 0;
+               this.countMoFsmReq = 0;
+               this.countMoFsmResp = 0;
+               this.countIscReq = 0;
+               this.countRsmdsReq = 0;
+               this.countRsmdsResp = 0;
+               this.countAscReq = 0;
+               this.countAscResp = 0;
+               this.countErrRcvd = 0;
+               this.countErrSent = 0;
+
                MAPProvider mapProvider = 
this.mapMan.getMAPStack().getMAPProvider();
                mapProvider.getMAPServiceSms().acivate();
                mapProvider.getMAPServiceSms().addMAPServiceListener(this);
@@ -697,7 +724,10 @@
if (this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().getMtFSMReaction().intValue() == MtFSMReaction.VAL_RETURN_SUCCESS) {
                                        
curDialog.addForwardShortMessageResponse(invokeId);
                                        this.countMtFsmResp++;
- this.testerHost.sendNotif(SOURCE_NAME, "Sent: mtResp", "", Level.DEBUG);
+
+ if (!this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs()) { + this.testerHost.sendNotif(SOURCE_NAME, "Sent: mtResp", "", Level.DEBUG);
+                                       }
                                } else {
                                        sendMtError(curDialog, invokeId);
                                }
@@ -800,8 +830,17 @@
                                        }
                                }
                        }
- String uData = this.createMtData(curDialog, destImsi, dTpdu, serviceCentreAddr); - this.testerHost.sendNotif(SOURCE_NAME, "Rcvd: mtReq: " + msg, uData, Level.DEBUG);
+
+ if (this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs()) {
+                               int i1 = countMtFsmReq / 100;
+                               if (countMtFsmReqNot < i1) {
+                                       countMtFsmReqNot = i1;
+ this.testerHost.sendNotif(SOURCE_NAME, "Rsvd: Ms messages: " + (countMtFsmReqNot * 100), "", Level.DEBUG);
+                               }
+                       } else {
+ String uData = this.createMtData(curDialog, destImsi, dTpdu, serviceCentreAddr); + this.testerHost.sendNotif(SOURCE_NAME, "Rcvd: mtReq: " + msg, uData, Level.DEBUG);
+                       }
                } catch (MAPException e) {
this.testerHost.sendNotif(SOURCE_NAME, "Exception when decoding MtForwardShortMessageRequest tpdu : " + e.getMessage(), e, Level.ERROR);
                }
@@ -856,7 +895,9 @@
if (this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().getMtFSMReaction().intValue() == MtFSMReaction.VAL_RETURN_SUCCESS) {
                                
curDialog.addMtForwardShortMessageResponse(invokeId, null, null);
                                this.countMtFsmResp++;
- this.testerHost.sendNotif(SOURCE_NAME, "Sent: mtResp", "", Level.DEBUG); + if (!this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs()) { + this.testerHost.sendNotif(SOURCE_NAME, "Sent: mtResp", "", Level.DEBUG);
+                               }
                        } else {
                                sendMtError(curDialog, invokeId);
                        }
@@ -904,9 +945,11 @@
                MAPDialogSms curDialog = ind.getMAPDialog();
                long invokeId = ind.getInvokeId();

-               String uData = this.createSriData(ind);
- this.testerHost.sendNotif(SOURCE_NAME, "Rcvd: sriReq", uData, Level.DEBUG);
-
+               String uData;
+ if (!this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs()) {
+                       uData = this.createSriData(ind);
+ this.testerHost.sendNotif(SOURCE_NAME, "Rcvd: sriReq", uData, Level.DEBUG);
+               }

                IMSI imsi = mapProvider.getMAPParameterFactory().createIMSI(
this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().getSriResponseImsi());
@@ -924,8 +967,10 @@
curDialog.addSendRoutingInfoForSMResponse(invokeId, imsi, li, null, null);

                                this.countSriResp++;
-                               uData = 
this.createSriRespData(curDialog.getLocalDialogId(), imsi, li);
- this.testerHost.sendNotif(SOURCE_NAME, "Sent: sriResp", uData, Level.DEBUG); + if (!this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs()) { + uData = this.createSriRespData(curDialog.getLocalDialogId(), imsi, li); + this.testerHost.sendNotif(SOURCE_NAME, "Sent: sriResp", uData, Level.DEBUG);
+                               }

if (curDialog.getApplicationContext().getApplicationContextVersion().getVersion()
1)
                                        informServiceCentrePossible = true;
@@ -1207,8 +1252,10 @@
                        try {
                                mapDialog.send();
                                currentRequestDef += "Rcvd emptTBeg;Sent 
emptTCont;";
- this.testerHost.sendNotif(SOURCE_NAME, "Rcvd: emptTBeg", "", Level.DEBUG); - this.testerHost.sendNotif(SOURCE_NAME, "Sent: emptTCont", "", Level.DEBUG); + if (!this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs()) { + this.testerHost.sendNotif(SOURCE_NAME, "Rcvd: emptTBeg", "", Level.DEBUG); + this.testerHost.sendNotif(SOURCE_NAME, "Sent: emptTCont", "", Level.DEBUG);
+                               }
                        } catch (Exception e) {
this.testerHost.sendNotif(SOURCE_NAME, "Exception when invoking send() : " + e.getMessage(), e, Level.ERROR);
                        }
=======================================
--- /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientManMBean.java Wed May 8 07:25:28 2013 +++ /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientManMBean.java Sun May 26 07:22:31 2013
@@ -108,6 +108,10 @@

        public void setSmsCodingType(SmsCodingType val);

+       public boolean isOneNotificationFor100Dialogs();
+
+       public void setOneNotificationFor100Dialogs(boolean val);
+

        public void putAddressNature(String val);

=======================================
--- /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientStandardManMBean.java Wed May 8 07:25:28 2013 +++ /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientStandardManMBean.java Sun May 26 07:22:31 2013
@@ -70,6 +70,9 @@
new MBeanAttributeInfo("NumberingPlanIdentification_Value", String.class.getName(), "NumberingPlanIdentification parameter for SMS tpdu destAddress", true, false, false), new MBeanAttributeInfo("CurrentRequestDef", String.class.getName(), "Get information of the current request", true, false, false), new MBeanAttributeInfo("SmsCodingType", SmsCodingType.class.getName(), "Character set for SMS encoding", true, true, false), + new MBeanAttributeInfo("OneNotificationFor100Dialogs", boolean.class.getName(), + "If true there will be only one notification per every 100 received dialogs (recommended for the auto answering mode)",
+                                               true, true, true),
                };

MBeanParameterInfo[] signString = new MBeanParameterInfo[] { new MBeanParameterInfo("val", String.class.getName(), "Index number or value") };
=======================================
--- /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsServerMan.java Wed May 8 07:25:28 2013 +++ /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsServerMan.java Sun May 26 07:22:31 2013
@@ -349,13 +349,13 @@
                sb.append(countMoFsmResp);
                sb.append(", countIscReq-");
                sb.append(countIscReq);
-               sb.append(", countRsmdsReq-");
+               sb.append("<br>countRsmdsReq-");
                sb.append(countRsmdsReq);
                sb.append(", countRsmdsResp-");
                sb.append(countRsmdsResp);
                sb.append(", countAscReq-");
                sb.append(countAscReq);
-               sb.append(", countAscResp-");
+               sb.append("<br>countAscResp-");
                sb.append(countAscResp);
                sb.append(", countErrRcvd-");
                sb.append(countErrRcvd);
@@ -366,6 +366,20 @@
        }

        public boolean start() {
+               this.countSriReq = 0;
+               this.countSriResp = 0;
+               this.countMtFsmReq = 0;
+               this.countMtFsmResp = 0;
+               this.countMoFsmReq = 0;
+               this.countMoFsmResp = 0;
+               this.countIscReq = 0;
+               this.countErrRcvd = 0;
+               this.countErrSent = 0;
+               this.countRsmdsReq = 0;
+               this.countRsmdsResp = 0;
+               this.countAscReq = 0;
+               this.countAscResp = 0;
+
                MAPProvider mapProvider = 
this.mapMan.getMAPStack().getMAPProvider();
                mapProvider.getMAPServiceSms().acivate();
                mapProvider.getMAPServiceSms().addMAPServiceListener(this);
=======================================
--- /tools/simulator/gui/src/main/java/org/mobicents/protocols/ss7/tools/simulatorgui/tests/sms/TestSmsClientParamForm.java Thu Apr 18 09:01:44 2013 +++ /tools/simulator/gui/src/main/java/org/mobicents/protocols/ss7/tools/simulatorgui/tests/sms/TestSmsClientParamForm.java Sun May 26 07:22:31 2013
@@ -78,6 +78,7 @@
        private JComboBox cbSRIInformServiceCenter;
        private JCheckBox cbSRIScAddressNotIncluded;
        private JComboBox cbMtFSMReaction;
+       private JCheckBox cbOneNotificationFor100Dialogs;

        public TestSmsClientParamForm(JFrame owner) {
                super(owner, true);
@@ -113,6 +114,10 @@
                tbSmscSsn.setBounds(435, 41, 86, 20);
                panel_gen.add(tbSmscSsn);

+ cbOneNotificationFor100Dialogs = new JCheckBox("One notification for 100 dialogs (recommended for bulk message mode)");
+               cbOneNotificationFor100Dialogs.setBounds(10, 67, 511, 23);
+               panel_gen.add(cbOneNotificationFor100Dialogs);
+
                JPanel panel_sri = new JPanel();
                tabbedPane.addTab("SRI response", panel_sri);
                panel_sri.setLayout(null);
@@ -317,6 +322,7 @@
                
tbSmscSsn.setText(((Integer)this.smsClient.getSmscSsn()).toString());

cbSRIScAddressNotIncluded.setSelected(this.smsClient.isSRIScAddressNotIncluded()); + cbOneNotificationFor100Dialogs.setSelected(this.smsClient.isOneNotificationFor100Dialogs());
        }

        private void loadDataA() {
@@ -339,6 +345,7 @@
                tbSmscSsn.setText("8");

                cbSRIScAddressNotIncluded.setSelected(false);
+               cbOneNotificationFor100Dialogs.setSelected(false);
        }

        private void loadDataB() {
@@ -372,6 +379,7 @@
                this.smsClient.setSmscSsn(smscSsn);

this.smsClient.setSRIScAddressNotIncluded(cbSRIScAddressNotIncluded.isSelected()); + this.smsClient.setOneNotificationFor100Dialogs(cbOneNotificationFor100Dialogs.isSelected());

                return true;
        }

==============================================================================
Revision: 8ea5ae8662cc
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 08:59:48 2013
Log:      Simulator update: bulk Mt SMS mode for SmsClient 2
http://code.google.com/p/jss7/source/detail?r=8ea5ae8662cc

Modified:
/tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientMan.java

=======================================
--- /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientMan.java Sun May 26 07:22:31 2013 +++ /tools/simulator/core/src/main/java/org/mobicents/protocols/ss7/tools/simulator/tests/sms/TestSmsClientMan.java Sun May 26 08:59:48 2013
@@ -1251,8 +1251,8 @@
                        // this is an empty first TC-BEGIN for MO SMS
                        try {
                                mapDialog.send();
-                               currentRequestDef += "Rcvd emptTBeg;Sent 
emptTCont;";
if (!this.testerHost.getConfigurationData().getTestSmsClientConfigurationData().isOneNotificationFor100Dialogs()) {
+//                                     currentRequestDef += "Rcvd emptTBeg;Sent 
emptTCont;";
this.testerHost.sendNotif(SOURCE_NAME, "Rcvd: emptTBeg", "", Level.DEBUG); this.testerHost.sendNotif(SOURCE_NAME, "Sent: emptTCont", "", Level.DEBUG);
                                }

==============================================================================
Revision: 87cdc10e6bb6
Author:   Sergey Vetyutnev <[email protected]>
Date:     Sun May 26 09:22:33 2013
Log:      Merge remote-tracking branch 'origin/2.0.x_cap22' into 2.0.x
http://code.google.com/p/jss7/source/detail?r=87cdc10e6bb6


--

--- You received this message because you are subscribed to the Google Groups "mobicents-commits" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to