# Session disconnect notification

**URL:** <https://community.wowza.com/t/session-disconnect-notification/39584>\
**Category:** Wowza Streaming Engine\
**Created:** [November 27, 2012, 11:15pm UTC](https://community.wowza.com/t/session-disconnect-notification/39584 "2012-11-27T23:15:10Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 27, 2012, 11:15pm UTC](https://community.wowza.com/t/session-disconnect-notification/39584/1 "2012-11-27T23:15:10Z")

</div>

Hello,

I am using basic Video chat example of Wowza. When the connection is made, from Actionscript, I can notify server that the user is actually online.

var myLoader:URLLoader = new URLLoader()

myLoader.dataFormat = URLLoaderDataFormat.TEXT;

myLoader.load(new URLRequest(url))

myLoader.addEventListener(Event.COMPLETE, onLoad)

function onLoad(ev:Event){

trace (ev.target.data);

//output\_stuff.text=ev.target.data;

}

I want to keep track when user go offline. So How can I notify server when the session Disconnect or person close the window of that flash?

Thanks

---

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 27, 2012, 11:48pm UTC](https://community.wowza.com/t/session-disconnect-notification/39584/2 "2012-11-27T23:48:49Z")

</div>

Simply: I am looking for a way to check if session is there or not using php

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [November 28, 2012, 3:19pm UTC](https://community.wowza.com/t/session-disconnect-notification/39584/3 "2012-11-28T15:19:53Z")

</div>

Take a look at IMediaStreamActionNotify3:

[https://www.wowza.com/docs/how-to-use-imediastreamactionnotify3-interface-to-listen-for-rtmp-stream-events-includes-codec-info](https://www.wowza.com/docs/how-to-use-imediastreamactionnotify3-interface-to-listen-for-rtmp-stream-events-includes-codec-info)

This is the best interface for Flash RTMP client. You won’t need PHP or HTTPProvider. You can send info to all clients with IApplicationInstance.broadcastMsg, or to one client with IClient.call

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [November 30, 2012, 12:39am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/4 "2012-11-30T00:39:54Z")

</div>

There is an example Flash VideoChat in the examples that ship with Wowza. It is very simple. It is a client app, you upload it to your web server.

[https://www.wowza.com/docs/how-to-set-up-live-video-chat](https://www.wowza.com/docs/how-to-set-up-live-video-chat)

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [November 30, 2012, 12:23pm UTC](https://community.wowza.com/t/session-disconnect-notification/39584/5 "2012-11-30T12:23:06Z")

</div>

The client app goes on your web server.

If there is a Wowza module involved you need the Wowza IDE to build and compile .jar files, which are placed in the Wowza /lib folder.

[https://www.wowza.com/media-server/developers#wowza-ide](https://www.wowza.com/media-server/developers#wowza-ide)

Here is the IDE guide

[https://www.wowza.com/uploads/developers/WowzaIDE\_UsersGuide.pdf](https://www.wowza.com/uploads/developers/WowzaIDE_UsersGuide.pdf)

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [November 30, 2012, 1:13pm UTC](https://community.wowza.com/t/session-disconnect-notification/39584/6 "2012-11-30T13:13:10Z")

</div>

It is the videochat.fla file in the example. You need Flash CS to modify. If you prefer Flash Builder, there is a Flex version [here](http://community.wowza.com/t/-/234).

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [November 30, 2012, 1:34pm UTC](https://community.wowza.com/t/session-disconnect-notification/39584/7 "2012-11-30T13:34:46Z")

</div>

There is not a .jar file with the basic example.

Richard

---

<div class="post-metadata">

**Author:** ![Jay\_Charles](https://avatars.discourse-cdn.com/v4/letter/j/c89c15/32.png) [@Jay\_Charles](https://community.wowza.com/u/Jay_Charles)\
**Post date:** [November 29, 2012, 10:32am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/8 "2012-11-29T10:32:18Z")

</div>

Seems to me that it would be much simpler to have your Wowza application call out to your PHP application when users come and go.

In your Wowza module, you can use java’s httpurlconnection to make calls to your PHP service. You could do this after you process the onConnect / onDisconnect events

---

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 29, 2012, 2:41am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/9 "2012-11-29T02:41:27Z")

</div>

Sorry for my ignorance but I am still not sure how to do it.

When we user make a connection, there is a connection id. I want to check from php if a user with that connection id is still connected to the wowza server.

is there any way to do that?

or may be a http link to list all the active connection? this can also help me.

otherwise just let me know how exactly i can use the link you sent me.

Thanks for your response. Appreciate that!!!

---

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 29, 2012, 2:46am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/10 "2012-11-29T02:46:00Z")

</div>

Another quick question:

I am using a build in example of wowza video chat. WHERE exactly I can see the source code of that application so I can make changes in that? May be I can make some changes on the other side to achieve what I want.

---

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 29, 2012, 11:15am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/11 "2012-11-29T11:15:20Z")

</div>

I am good with java. I can do that but where I can find the video chat application on wowza? How can I re upload that application after making changes

---

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 30, 2012, 12:02am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/12 "2012-11-30T00:02:57Z")

</div>

Where exactly I will upload on the server? I am unable to find the java file to make changes. Please guide me how can I find that JAVA file where I can keep track of sessions.

Thanks

Zee

---

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 30, 2012, 4:51am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/13 "2012-11-30T04:51:21Z")

</div>

From where I can get the source code of Video chat application of WOWZA?

---

<div class="post-metadata">

**Author:** ![Zahid\_Rasheed](https://avatars.discourse-cdn.com/v4/letter/z/8797f3/32.png) [@Zahid\_Rasheed](https://community.wowza.com/u/Zahid_Rasheed)\
**Post date:** [November 30, 2012, 5:16am UTC](https://community.wowza.com/t/session-disconnect-notification/39584/14 "2012-11-30T05:16:12Z")

</div>

I have already made changes to the videochat.fla file. when I make a connection to wowza, i update my server that a user just got connected. Where is the other side where I can update when the connection is lost? where is the java file located (jar file) which manage this connection?
