[mobicents-public] Error creating sipServletRequest

47 views
Skip to first unread message

Siebenschlaefer

unread,
Apr 23, 2010, 7:25:19 AM4/23/10
to mobicents-public

HI,

What could be the reason for the NullPointerException?
See below.

BR
Theo

2010-04-22 15:14:03,929 INFO [servletPackage.SimpleWebServlet] the
SimpleWebServlet has been started
2010-04-22 15:14:03,955 DEBUG
[org.mobicents.servlet.sip.core.session.SipApplicationSessionImpl]
Scheduling sip application session
(360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
to expire in 3.0 minutes
2010-04-22 15:14:03,959 DEBUG
[org.mobicents.servlet.sip.core.session.SipManagerDelegate] Adding a
sip application session with the key :
(360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
2010-04-22 15:14:03,963 INFO [servletPackage.SimpleWebServlet]
request_line_header_value: INVITE
sip:iptv_ser...@mediaservice.oiptv.org SIP/2.0
2010-04-22 15:14:03,964 DEBUG
[org.mobicents.servlet.sip.message.SipFactoryImpl] Creating new
SipServletRequest for
SipApplicationSession[(360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)]
METHOD[INVITE] FROM[<sip:un...@oiptv.org>]
TO[<sip:iptv_ser...@mediaservice.oiptv.org>]
2010-04-22 15:14:03,964 DEBUG
[org.mobicents.servlet.sip.message.SipFactoryImpl] Creating Address
from [<sip:iptv_ser...@mediaservice.oiptv.org>]
2010-04-22 15:14:04,023 DEBUG
[org.mobicents.servlet.sip.message.SipFactoryImpl] Creating Address
from [<sip:un...@oiptv.org>]
2010-04-22 15:14:04,085 DEBUG
[org.mobicents.servlet.sip.core.ApplicationRoutingHeaderComposer] tag
will be equal to 18157525_d9d5d8b1_360870482572905
2010-04-22 15:14:04,093 DEBUG
[org.mobicents.servlet.sip.core.session.SipApplicationSessionImpl]
Added sip session
(18157525_d9d5d8b1_360870482572905:9fb6124f205c9458...@0.0.0.0:360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
to sip app session
(360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
2010-04-22 15:14:04,096 DEBUG
[org.mobicents.servlet.sip.core.session.SipManagerDelegate] Adding a
sip session with the key :
(18157525_d9d5d8b1_360870482572905:9fb6124f205c9458...@0.0.0.0:360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
2010-04-22 15:14:04,096 ERROR
[org.mobicents.servlet.sip.message.SipFactoryImpl] Error creating
sipServletRequest
java.lang.NullPointerException
at
org.mobicents.servlet.sip.core.session.SipSessionImpl.setHandler(SipSessionImpl.java:
1058)
at
org.mobicents.servlet.sip.message.SipFactoryImpl.createSipServletRequest(SipFactoryImpl.java:
546)
at
org.mobicents.servlet.sip.message.SipFactoryImpl.createRequest(SipFactoryImpl.java:
293)
at
org.mobicents.servlet.sip.message.SipFactoryFacade.createRequest(SipFactoryFacade.java:
138)
at servletPackage.SimpleWebServlet.doPost(SimpleWebServlet.java:101)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:
290)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:
206)
at
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:
96)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:
235)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:
206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:
230)
at
org.mobicents.servlet.sip.startup.SipStandardContextValve.invoke(SipStandardContextValve.java:
224)
at
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:
182)
at
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:
84)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:
127)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:
102)
at
org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:
157)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:
109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:
262)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:
844)
at org.apache.coyote.http11.Http11Protocol
$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:
446)
at java.lang.Thread.run(Thread.java:636)


--
Subscription settings: http://groups.google.com/group/mobicents-public/subscribe?hl=en

Jean Deruelle

unread,
Apr 23, 2010, 7:39:32 AM4/23/10
to mobicent...@googlegroups.com
Which version of Mobicents Sip Servlets are you using ?

Jean Deruelle

unread,
Apr 23, 2010, 7:41:23 AM4/23/10
to mobicent...@googlegroups.com
From the debug trace it seems you use MSS 1.1 please move to MSS 1.2

Siebenschlaefer

unread,
Apr 26, 2010, 10:24:17 AM4/26/10
to mobicents-public

Now I have installed MSS 1.2
But it still doesn't work.


HTTP Status 500 -

--------------------------------------------------------------------------------

type Exception report

message

description The server encountered an internal error () that prevented
it from fulfilling this request.

exception

java.lang.IllegalStateException: Error creating sipServletRequest

org.mobicents.servlet.sip.message.SipFactoryImpl.createSipServletRequest(SipFactoryImpl.java:
560)

org.mobicents.servlet.sip.message.SipFactoryImpl.createRequest(SipFactoryImpl.java:
293)

org.mobicents.servlet.sip.message.SipFactoryFacade.createRequest(SipFactoryFacade.java:
138)
servletPackage.SimpleWebServlet.doPost(SimpleWebServlet.java:
101)
javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:
96)


root cause

java.lang.NullPointerException

org.mobicents.servlet.sip.core.session.SipSessionImpl.setHandler(SipSessionImpl.java:
1073)

org.mobicents.servlet.sip.message.SipFactoryImpl.createSipServletRequest(SipFactoryImpl.java:
550)

org.mobicents.servlet.sip.message.SipFactoryImpl.createRequest(SipFactoryImpl.java:
293)

org.mobicents.servlet.sip.message.SipFactoryFacade.createRequest(SipFactoryFacade.java:
138)
servletPackage.SimpleWebServlet.doPost(SimpleWebServlet.java:
101)
javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:
96)


note The full stack trace of the root cause is available in the
JBossWeb/2.0.1.GA logs.


--------------------------------------------------------------------------------

JBossWeb/2.0.1.GA

On 23 Apr., 13:41, Jean Deruelle <jean.derue...@gmail.com> wrote:
> From the debug trace it seems you use MSS 1.1 please move to MSS 1.2
>
> On Fri, Apr 23, 2010 at 1:39 PM, Jean Deruelle <jean.derue...@gmail.com>wrote:
>
> > Which version of Mobicents Sip Servlets are you using ?
>
> > On Fri, Apr 23, 2010 at 1:25 PM, Siebenschlaefer <
> > theodor.scher...@utanet.at> wrote:
>
> >> HI,
>
> >> What could be the reason for the NullPointerException?
> >> See below.
>
> >> BR
> >> Theo
>
> >> 2010-04-22 15:14:03,929 INFO  [servletPackage.SimpleWebServlet] the
> >> SimpleWebServlet has been started
> >> 2010-04-22 15:14:03,955 DEBUG
> >> [org.mobicents.servlet.sip.core.session.SipApplicationSessionImpl]
> >> Scheduling sip application session
> >> (360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
> >> to expire in 3.0 minutes
> >> 2010-04-22 15:14:03,959 DEBUG
> >> [org.mobicents.servlet.sip.core.session.SipManagerDelegate] Adding a
> >> sip application session with the key :
> >> (360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
> >> 2010-04-22 15:14:03,963 INFO  [servletPackage.SimpleWebServlet]
> >> request_line_header_value: INVITE
> >> sip:iptv_service_...@mediaservice.oiptv.org<sip%3Aiptv_service_...@mediaservice.oiptv.org>SIP/2.0
> >> 2010-04-22 15:14:03,964 DEBUG
> >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating new
> >> SipServletRequest for
>
> >> SipApplicationSession[(360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)]
> >> METHOD[INVITE] FROM[<sip:un...@oiptv.org <sip%3Aun...@oiptv.org>>]
> >> TO[<sip:iptv_service_...@mediaservice.oiptv.org<sip%3Aiptv_service_...@mediaservice.oiptv.org>
> >> >]
> >> 2010-04-22 15:14:03,964 DEBUG
> >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating Address
> >> from [<sip:iptv_service_...@mediaservice.oiptv.org<sip%3Aiptv_service_...@mediaservice.oiptv.org>
> >> >]
> >> 2010-04-22 15:14:04,023 DEBUG
> >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating Address
> >> from [<sip:un...@oiptv.org <sip%3Aun...@oiptv.org>>]
> >> 2010-04-22 15:14:04,085 DEBUG
> >> [org.mobicents.servlet.sip.core.ApplicationRoutingHeaderComposer] tag
> >> will be equal to 18157525_d9d5d8b1_360870482572905
> >> 2010-04-22 15:14:04,093 DEBUG
> >> [org.mobicents.servlet.sip.core.session.SipApplicationSessionImpl]
> >> Added sip session
>
> >> (18157525_d9d5d8b1_360870482572905:9fb6124f205c945804ff12401bfa3...@0.0.0.0:360870482572905
> >> :org.mobicents.servlet.sip.example.SimpleApplication)
> >> to sip app session
> >> (360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)
> >> 2010-04-22 15:14:04,096 DEBUG
> >> [org.mobicents.servlet.sip.core.session.SipManagerDelegate] Adding a
> >> sip session with the key :
>
> >> (18157525_d9d5d8b1_360870482572905:9fb6124f205c945804ff12401bfa3...@0.0.0.0:360870482572905

Jean Deruelle

unread,
Apr 27, 2010, 8:49:47 AM4/27/10
to mobicent...@googlegroups.com
Can you show the code that gets the factory, creates the sip application session and creates the sip servlet request ?

Thx in advance
Jean

Siebenschlaefer

unread,
Apr 27, 2010, 11:24:31 AM4/27/10
to mobicents-public

@Resource
private SipFactory sipFactory;


// Create app session and request
SipApplicationSession appSession =

((ConvergedHttpSession)request.getSession()).getApplicationSession();


// from_header_value and to_header_value are supported correct

SipServletRequest req = sipFactory.createRequest(appSession,
"INVITE", from_header_value, to_header_value );


BR
Theo


On 27 Apr., 14:49, Jean Deruelle <jean.derue...@gmail.com> wrote:
> Can you show the code that gets the factory, creates the sip application
> session and creates the sip servlet request ?
>
> Thx in advance
> Jean
>
> On Mon, Apr 26, 2010 at 4:24 PM, Siebenschlaefer <theodor.scher...@utanet.at
> > <sip%3Aiptv_service_...@mediaservice.oiptv.org<sip%253Aiptv_service_...@mediaservice.oiptv.org>
> > >SIP/2.0
> > > >> 2010-04-22 15:14:03,964 DEBUG
> > > >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating new
> > > >> SipServletRequest for
>
> > SipApplicationSession[(360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)]
> > > >> METHOD[INVITE] FROM[<sip:un...@oiptv.org <sip%3Aun...@oiptv.org> <
> > sip%3Aun...@oiptv.org <sip%253Aun...@oiptv.org>>>]
> > > >> TO[<sip:iptv_service_...@mediaservice.oiptv.org<sip%3Aiptv_service_...@mediaservice.oiptv.org>
> > <sip%3Aiptv_service_...@mediaservice.oiptv.org<sip%253Aiptv_service_...@mediaservice.oiptv.org>
>
> > > >> >]
> > > >> 2010-04-22 15:14:03,964 DEBUG
> > > >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating Address
> > > >> from [<sip:iptv_service_...@mediaservice.oiptv.org<sip%3Aiptv_service_...@mediaservice.oiptv.org>
> > <sip%3Aiptv_service_...@mediaservice.oiptv.org<sip%253Aiptv_service_...@mediaservice.oiptv.org>
>
> > > >> >]
> > > >> 2010-04-22 15:14:04,023 DEBUG
> > > >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating Address
> > > >> from [<sip:un...@oiptv.org <sip%3Aun...@oiptv.org> <
> > sip%3Aun...@oiptv.org <sip%253Aun...@oiptv.org>>>]

Jean Deruelle

unread,
Apr 27, 2010, 11:42:47 AM4/27/10
to mobicent...@googlegroups.com
If you can make a simple standalone application reproducing the issue that would be great.
Can you provide the server.log as well ?

Siebenschlaefer

unread,
Apr 28, 2010, 10:21:48 AM4/28/10
to mobicents-public

I couldn't reproduce it with a standalone application. :-(

Is it possible to add an atttachment?


On 27 Apr., 17:42, Jean Deruelle <jean.derue...@gmail.com> wrote:
> If you can make a simple standalone application reproducing the issue that
> would be great.
> Can you provide the server.log as well ?
>
> On Tue, Apr 27, 2010 at 5:24 PM, Siebenschlaefer <theodor.scher...@utanet.at
> > > > <sip%3Aiptv_service_...@mediaservice.oiptv.org<sip%253Aiptv_service_...@mediaservice.oiptv.org>
> > <sip%253Aiptv_service_...@mediaservice.oiptv.org<sip%25253Aiptv_service_...@mediaservice.oiptv.org>
>
> > > > >SIP/2.0
> > > > > >> 2010-04-22 15:14:03,964 DEBUG
> > > > > >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating new
> > > > > >> SipServletRequest for
>
> > SipApplicationSession[(360870482572905:org.mobicents.servlet.sip.example.SimpleApplication)]
> > > > > >> METHOD[INVITE] FROM[<sip:un...@oiptv.org <sip%3Aun...@oiptv.org><
> > sip%3Aun...@oiptv.org <sip%253Aun...@oiptv.org>> <
> > > > sip%3Aun...@oiptv.org <sip%253Aun...@oiptv.org> <
> > sip%253Aun...@oiptv.org <sip%25253Aun...@oiptv.org>>>>]
> > > > <sip%3Aiptv_service_...@mediaservice.oiptv.org<sip%253Aiptv_service_...@mediaservice.oiptv.org>
> > <sip%253Aiptv_service_...@mediaservice.oiptv.org<sip%25253Aiptv_service_...@mediaservice.oiptv.org>
>
> > > > > >> >]
> > > > > >> 2010-04-22 15:14:03,964 DEBUG
> > > > > >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating
> > Address
> > > > > >> from [<sip:iptv_service_...@mediaservice.oiptv.org<sip%3Aiptv_service_...@mediaservice.oiptv.org>
> > <sip%3Aiptv_service_...@mediaservice.oiptv.org<sip%253Aiptv_service_...@mediaservice.oiptv.org>
>
> > > > <sip%3Aiptv_service_...@mediaservice.oiptv.org<sip%253Aiptv_service_...@mediaservice.oiptv.org>
> > <sip%253Aiptv_service_...@mediaservice.oiptv.org<sip%25253Aiptv_service_...@mediaservice.oiptv.org>
>
> > > > > >> >]
> > > > > >> 2010-04-22 15:14:04,023 DEBUG
> > > > > >> [org.mobicents.servlet.sip.message.SipFactoryImpl] Creating
> > Address
> > > > > >> from [<sip:un...@oiptv.org <sip%3Aun...@oiptv.org> <
> > sip%3Aun...@oiptv.org <sip%253Aun...@oiptv.org>> <
> > > > sip%3Aun...@oiptv.org <sip%253Aun...@oiptv.org> <
> > sip%253Aun...@oiptv.org <sip%25253Aun...@oiptv.org>>>>]
> ...
>
> Erfahren Sie mehr »

Jean Deruelle

unread,
Apr 28, 2010, 10:42:55 AM4/28/10
to mobicent...@googlegroups.com
Sure send an email with the attachement to mobicent...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages