Status: Started
Owner: jean.deruelle
Labels: Type-Defect Priority-Medium MSS-1.6.0.FINAL Release-Type-FINAL Roadmap-Fix Component-Sip-Servlets JBCP5-Patch-5.1.1

New issue 2699 by jean.deruelle: SipFactoryImpl.createApplicationSessionByKey is not compliant with Sip Servlets spec
http://code.google.com/p/mobicents/issues/detail?id=2699

"Returns a new SipApplicationSession identified by the specified SipApplicationKey. This is same as the one generated by the method annotated with @SipApplicationKey annotation. This allows a way to associate incoming requests to an already existing SipApplicationSession."

Currently if the call to the method is passed a regular string like "appKeyTest" the following exception is thrown

java.lang.IllegalArgumentException: appkeytest is not a valid sip application session key at org.mobicents.servlet.sip.message.SipFactoryImpl.createApplicationSessionByKey(SipFactoryImpl.java:725) at org.mobicents.servlet.sip.message.SipFactoryFacade.createApplicationSessionByKey(SipFactoryFacade.java:237) at org.mobicents.servlet.sip.testsuite.AppKeySipServlet.servletInitialized(AppKeySipServlet.java:118) at org.mobicents.servlet.sip.startup.SipStandardContext.notifySipContextListeners(SipStandardContext.java:1110) at org.mobicents.servlet.sip.core.SipApplicationDispatcherImpl.addSipApplication(SipApplicationDispatcherImpl.java:474) at org.mobicents.servlet.sip.startup.SipStandardContext.start(SipStandardContext.java:390) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:799)
        at 
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:779)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:601)
at org.mobicents.servlet.sip.SipEmbedded.deployContext(SipEmbedded.java:312) at org.mobicents.servlet.sip.testsuite.targeting.AppKeySipServletTest.deployApplication(AppKeySipServletTest.java:80) at org.mobicents.servlet.sip.testsuite.targeting.AppKeySipServletTest.testSipFactoryCreateApplicationSessionByAppKey(AppKeySipServletTest.java:129)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at junit.framework.TestCase.runTest(TestCase.java:154)
        at junit.framework.TestCase.runBare(TestCase.java:127)
        at junit.framework.TestResult$1.protect(TestResult.java:106)
        at junit.framework.TestResult.runProtected(TestResult.java:124)
        at junit.framework.TestResult.run(TestResult.java:109)
        at junit.framework.TestCase.run(TestCase.java:118)
at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197) Caused by: java.text.ParseException: The comma could not be found in the following key appkeytest at org.mobicents.servlet.sip.core.session.SessionManagerUtil.parseSipApplicationSessionKey(SessionManagerUtil.java:134) at org.mobicents.servlet.sip.message.SipFactoryImpl.createApplicationSessionByKey(SipFactoryImpl.java:722)
        ... 27 more

Reply via email to