powered by Jive Software

Hang Up Error

Hey Dele,

When I do a “doHangup” on an active call on the SIP phone. I get a strange error…

Red5SIP Hangup

SIPUser hangup

closeMediaApplication

halting sip audio…

sender halted

receiver halted

RtpStreamReceiver: RtpStreamReceiver: Terminated

RtpStreamReceiver: Frames = 4209

SIPUser closeStreams

RTMPUser stopStream

Red5SIP Stream subscribe close: 1a808a1e-496c-4e32-8ce9-bcaf64031a63

Red5SIP Stream broadcast close: microphone_1210759021725

Red5SIP Client leaving app 1

Stopped Asao2Ulaw

Stopped ASAOThread

Total blocks processed = 213

In stopThread()

RtpStreamSender: RtpStreamSender: Error reading from InputStream

Stopped Asao2Ulaw

Stopped ASAOThread

In stopThread()

Stopped thread alive=false

In stopThread()

In stopThread()

RtpStreamSender: RtpStreamSender: Terminated

onCallClosed()

CLOSE/OK

SIPUser closeStreams

Red5SIP Stream stop: microphone_1210759021725

org.red5.server.service.ServiceInvoker - Error executing call: Service: null Method: publish Num Params: 10: null

org.red5.server.service.ServiceInvoker - Service invocation error

java.lang.reflect.InvocationTargetException

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja va:25)

at java.lang.reflect.Method.invoke(Method.java:597)

at org.red5.server.service.ServiceInvoker.invoke(ServiceInvoker.java:217)

at org.red5.server.net.rtmp.RTMPHandler.invokeCall(RTMPHandler.java:179)

at org.red5.server.net.rtmp.RTMPHandler.onInvoke(RTMPHandler.java:385)

at org.red5.server.net.rtmp.BaseRTMPHandler.messageReceived(BaseRTMPHandler.java:1 43)

at org.red5.server.net.rtmp.RTMPMinaIoHandler.messageReceived(RTMPMinaIoHandler.ja va:119)

at org.apache.mina.common.support.AbstractIoFilterChain$TailFilter.messageReceived (AbstractIoFilterChain.java:570)

at org.apache.mina.common.support.AbstractIoFilterChain.callNextMessageReceived(Ab stractIoFilterChain.java:299)

at org.apache.mina.common.support.AbstractIoFilterChain.access$1100(AbstractIoFilt erChain.java:53)

at org.apache.mina.common.support.AbstractIoFilterChain$EntryImpl$1.messageReceive d(AbstractIoFilterChain.java:648)

at org.apache.mina.filter.executor.ExecutorFilter.processEvent(ExecutorFilter.java :220)

at org.apache.mina.filter.executor.ExecutorFilter$ProcessEventsRunnable.run(Execut orFilter.java:264)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java: 885)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)

at java.lang.Thread.run(Thread.java:619)

Caused by: java.lang.NullPointerException

at org.red5.server.stream.StreamService.publish(StreamService.java:268)

… 18 common frames omitted

Red5SIP streamStatus

SIPUser streamStatus stop

Stopped thread alive=true

As you can see it looks like something is calling “publish” with 10 params and then theres a NullPointerException? I can’t seem to figure it out. Any ideas?

Also, I just noticed that after this error occurs, I can’t use the SIP phone to register again until I restart Red5 or wait a long time.

Thanks,

-Chris

So I guess I spoke to soon when I said nothing in the actionscript was calling publish…

Heres the line where its called…

outgoingNetStream.publish(null);

Thats in the callState() method of the red5phone.mxml

I believe the intention of this call is to stop publishing the audiostream to the Red5 plugin webapp. However something (all the time?) when this method is called I get the aforementioned error. I have an inkling that this could be a Red5 bug along the lines of they haven’t implemented the publish(null) method. (Even though in the Adobe API it states that .publish(null) should stop the published stream).

The workaround is to just comment out the outgoingNetStream.publish(null) line. Theres no exception on the server side anymore, and everything still seems to work.

Also, there’s a distinct possibility that this is uniquely my problem because I’ve been futzing around with the innards of both the Red5 app and the Flex.

-Chris

I have an inkling that this could be a Red5 bug

No, that is my bug. I copied that technique from my Openlaszlo audio/video client (AS2) in the video folder without checking for Flex (AS3) compatibility. However, I got it wrong. In my Openlaszlo code I was doing netstream.play(false) which meant I should have done netstream.publish(false) and checking Adobe AS2 and AS3 documentation it is indeed netstream.play(false).

Thanks for finding that

-dele

I have the same problem like you .

Have you resolved it ?

Thanks,

Niraj