Wowza Community

HTTProvider that returns server, vhost, application, appInstance, stream conn. counts

I’m not sure about the Wowza admin, but it’s not imminent.

Richard

Hello,

How is possible to extract on xml only information about one application, for example:

http://[wowza.url]:8086/connectioncounts?application=test

to show:

<Application>
  <Name>test</Name> 
  <Status>loaded</Status> 
<ConnectionsCurrent>2</ConnectionsCurrent> 
  <ConnectionsTotal>3</ConnectionsTotal> 
  <ConnectionsTotalAccepted>3</ConnectionsTotalAccepted> 
</Application>

Only information about what application name i need.

Thanks

Hello Charly,

I am using this feature now to build my own admin panel.

But I was looking at something, I have an application with multiple streampoints, but I always get this:

<Application>
  <Name>test</Name> 
  <Status>loaded</Status> 
  <TimeRunning>1454.528</TimeRunning> 
  <ConnectionsCurrent>2</ConnectionsCurrent> 
  <ConnectionsTotal>3</ConnectionsTotal> 
  <ConnectionsTotalAccepted>3</ConnectionsTotalAccepted> 
  <ConnectionsTotalRejected>0</ConnectionsTotalRejected> 
  <MessagesInBytesRate>78872.0</MessagesInBytesRate> 
  <MessagesOutBytesRate>2.0</MessagesOutBytesRate> 
- <ApplicationInstance>
  <Name>_definst_</Name> 
  <TimeRunning>1454.504</TimeRunning> 
  <ConnectionsCurrent>2</ConnectionsCurrent> 
  <ConnectionsTotal>3</ConnectionsTotal> 
  <ConnectionsTotalAccepted>3</ConnectionsTotalAccepted> 
  <ConnectionsTotalRejected>0</ConnectionsTotalRejected> 
  <MessagesInBytesRate>78872.0</MessagesInBytesRate> 
  <MessagesOutBytesRate>2.0</MessagesOutBytesRate> 
- <Stream>
  <Name>alpha</Name> 
  <SessionsFlash>0</SessionsFlash> 
  <SessionsCupertino>0</SessionsCupertino> 
  <SessionsSmooth>0</SessionsSmooth> 
  <SessionsRTSP>0</SessionsRTSP> 
  <SessionsTotal>0</SessionsTotal> 
  </Stream>
- <Stream>
  <Name>omega</Name> 
  <SessionsFlash>0</SessionsFlash> 
  <SessionsCupertino>0</SessionsCupertino> 
  <SessionsSmooth>0</SessionsSmooth> 
  <SessionsRTSP>0</SessionsRTSP> 
  <SessionsTotal>0</SessionsTotal> 
  </Stream>
  </ApplicationInstance>
  </Application>

Is it possible to break up the mountpoints so that I have for each own the bytes in and out?

I can’t really figure out what definst does in this context?

Ah thanks, that wasn’t very clear, but it seems to work now yes!

That option is perfect because now I can monitor per publishpoint the IO data. Thanks!

thanks Richard,

without the AuthenticationMethod it works.

But I’ve changed the folliìowing section:

com.wowza.wms.http.HTTPConnectionCountsXML

connectioncounts*

none

Thanks again for your answer, you have helped me to bypass a serious problem for me.

ciao

Dave

Hi ffsdff,

We can help you with your request.

Please contact us: support[@]wmconsulting.info

Regards,

Alejandro

add

[php]

<?php [/php] at the beginning and [php] ?>

[/php]

at the end ?

Shamrock

Note the wowzaip part, you need to change this to the IP address of your server running Wowza. Please do note PHP is not supported here, although advice can be offered really you do need to source PHP help from a PHP forum.

Shamrock

I am looking for developer who can make connection count that need to display in my website or inside flash player, control bar.

ii have this msg

Fatal error: Call to a member function getElementsByTagName() on a non-object in /home/mexsiden/public_html/mundo/listerns.php on line 9

i guees i need chaneg somethin in the line

$currentlistener = $wms->item(0)->getElementsByTagName(“ConnectionsCurrent”)->item(0)->nodeValue

A Wowza admin is in development. But I don’t have a time frame for its release.

Richard

This its a excellent news for all i hope soon for this moment

Dear Charlie (and everyone else :slight_smile: )

I’m a newbie with Wowza Media Server, and I need to do some monitoring for the server performances. From what I’ve read and understood in this forum, I tried to use http://[wowza-ip-address]:8086/connectioncounts to get the number of connections to the server. But I got the following response in the browser:

“This XML file does not appear to have any style information associated with it.”

Can you tell me what does it mean? :confused:

Thank you.

OK, thanks Richard for answer…

anyway, is it possible for us to modify the HTTPProvider and/or HTTPConnectionCountsXML class?

where can the source code be founded? thanks

Hello there…

I wanna ask about the “connectioncounts” request to the HTTProvider. I still wondering how exactly the calculation works?

for examples:

<WowzaMediaServer>
  <ConnectionsCurrent>2</ConnectionsCurrent>
  <ConnectionsTotal>64</ConnectionsTotal>
  <ConnectionsTotalAccepted>64</ConnectionsTotalAccepted>
  <ConnectionsTotalRejected>0</ConnectionsTotalRejected>
  <MessagesInBytesRate>14.0</MessagesInBytesRate>
  <MessagesOutBytesRate>841.0</MessagesOutBytesRate>
  &#8722; <VHost>
     <Name>_defaultVHost_</Name>
     <TimeRunning>39147.57</TimeRunning>
     <ConnectionsLimit>0</ConnectionsLimit>
     <ConnectionsCurrent>2</ConnectionsCurrent>
     <ConnectionsTotal>64</ConnectionsTotal>
     <ConnectionsTotalAccepted>64</ConnectionsTotalAccepted>
     <ConnectionsTotalRejected>0</ConnectionsTotalRejected>
     <MessagesInBytesRate>14.0</MessagesInBytesRate>
     <MessagesOutBytesRate>841.0</MessagesOutBytesRate>
    &#8722; <Application>
       <Name>securestreaming</Name>
       <Status>loaded</Status>
       <TimeRunning>4613.597</TimeRunning>
       <ConnectionsCurrent>2</ConnectionsCurrent>
       <ConnectionsTotal>12</ConnectionsTotal>
       <ConnectionsTotalAccepted>12</ConnectionsTotalAccepted>
       <ConnectionsTotalRejected>0</ConnectionsTotalRejected>
       <MessagesInBytesRate>14.0</MessagesInBytesRate>
       <MessagesOutBytesRate>841.0</MessagesOutBytesRate>

  1. the “total connection” in the , what exactly does it count? is it based on daily accesses? what does the total means? is there any time limit?

  2. between the and the what is the different of ConnectionTotalAccepted? why it’s different?

  3. I tried to use the loadBalancingTool before and the number of the rejected connection was increasing, why/how that could be happen? because in the loadBalanceTool test, the status was all connected. I thought the loadBalancingTool module is used to test the server connection for the media access.

OK, that’s for now… waiting for your help there. :wink:

Thank you

I’ve create a webservice refer to http://www.wowza.com/community/t/-/52

how can I build a function in webservice return the result like to access http://[wowza-ip-address]:8086/connectioncounts?flat, is to use com.wowza.wms.mediacaster.MediaCasterStreamManager?

some example code will be very appreciated! I’m new to wowza and java.

I can use Wowza IDE.

I want the webservice can tell me a specified stream exists or not, or has been published?

please help me

How would I make a .php page with this code?. I just want a simple stats page. I noticed there is no <php? in the code and I don’t know.

Just looking for code I can paste into a file and name it stats.php and it will get stats from Wowza media server 2.2

Thanks for any help.

I have tried that.

I get this error:

Parse error: syntax error, unexpected ‘}’ in /var/www/stats.php on line 14

Then I took out the bottom } and tried again and I get this:

[PHP]<?php

$xml = simplexml_load_file(“wowzaip:8086/connectioncounts”);

//var_dump($xml);

foreach ($xml->Application as $item) {

$tmp = (string) $item->Name;

echo $tmp."
";

foreach ($item->ApplicationInstance as $item2) {

$roomName = (string) $item2->Name;

$Connections = (string) $item2->ConnectionsCurrent;

echo $roomName.": “.$Connections.”
";

}

}

?>[/PHP]

[PHP]Warning: simplexml_load_file() [function.simplexml-load-file]: I/O warning : failed to load external entity “wowzaip:8086/connectioncounts” in /var/www/stats.php on line 2

Warning: Invalid argument supplied for foreach() in /var/www/stats.php on line 5[/PHP]

OK I understand.

I will have a look on there.

I don’t understand why Wowza doesn’t come with a web panel for showing stats in a simple manner. For example in FMS you can see everything running in detail from the admin panel without all this XML rubbish in the browser.

I did lots of searches on Google,But I can’t find any web panels for Wowza.

I think it’s a really good Media Server, it’s got better than FMS, but still lacks a decent admin panel. :frowning:

Ok Richard, That’s good news :slight_smile: Thanks for letting me know.