Which is better for live streaming, RTMP vs HLS

RTMP – Low latency TCP-based protocol originally built for Flash

HLS – Proprietary Apple-backed protocol that is widely supported on many environments.

MPEG-Dash – Webstandard but carries the same faults as HLS

Both HLS & MPEG Dash are kind of medium to high latency protocols although there is scope to play with different latencies.

WebRTC – Low latency protocol, built on open standards works in almost all browsers. However it is not supported on several environments/browsers Viz. iOS, IE

In summary, you cannot build a live streaming product/platform just based on rtmp stream as it does not address your maximum device coverage agenda.

My recommendation is to use a combination of http based (HLS/MPEG-DASH) & rtmp server for input from the broadcaster and then the hls for the output to a HTML5 player, like this you have all protocols for building your solutions.

Web Site Management

Hosting Marketers is offering new services to their customers,

Web Site Management

Realizing the difficulty  of hiring trusted web developers, Hosting Marketers is now offering in-house site installation, script upgrades and if anything goes wrong sites fixes.

They also offering web design at very affordable  prices, starting at $60 for a 5 page wordpress site.

They offering also SEO expertize starting at $50 for On-page Analysis.

Please visit https://hosting-marketers.com/hosting-marketers-services/ for more information.

testing a player

Trying to test if a player code is easy to embeb on a wordpress post.

the player was generated at

http://www.hosting-marketers.com/generator/


red5 hosting

Red5 is a media server created with Java language. It is a free open source software but recently a new version Red5 Pro came out developed by the same people, this new version supports streaming to mobiles, Android or iOS, which red5 does not. The Red5 Pro is commercial product and costs $55 per server.

A media server allows Flash based applications connect to it using Real Time Messaging Protocol (RTMP). The server can send and receive data to and from the connected users who have a flash player installed. The server also allows users to receive and publish streams. This permits video chat applications, live streaming and even ondemand video streaming.

Most common Video chat software’s are:
1- Avchat
2- Videowhisper
3- Prochatrooms
4- Gchats

For live streaming the necessary tool if you already have a server with red5 installed is an encoder, an encoder is the software that will connect your computer to the red5 server using the RTMP, which your server provider will give you.
1- FMLE, it is an free Adobe product and does a good job.
2- Wirecast, it is an expensive commercial product of very high quality, absolutely necessary if you starting a TV station.

Although red5 is a free product many people prefer to use Wowza Streaming Engine or Adobe Flash Media Server which are commercial software’s and can be quite expensive, the FMS costs $4500 per server. The reason is that the developers of red5 although have created a wonderful system did not spend much time with tutorials and instructions on how to install and manage a red5 server, for this reason if you searching for a red5 server we suggest you pick a web host which specializes on red5 servers and red5 shared hosting.

1- Red5 Servers relatively cheap red5 servers starting at $15 a month.
2- Red5 Hosting, Hosting Marketers, a web host for experienced webmasters, it is the oldest hosting company specialized on Video and media servers, they also offer Wowza Streaming Engine on its shared plans. They have a very experienced customer support and a reputation for going out of their way to help customers. They starting plan with Red5 enabled costs $9.95 a month. Most other red5 hosting companies are resellers of Hosting Marketers.

Red5 is a formidable media server, extremely flexible and has the advantage of being a free product with with many people working on developing it, for now the main version does not yet work with mobiles, if that is what you need we suggest that instead of using the Red5 Pro version to use the Wowza instead.

Remind me, what is CloudFlare?

CloudFlare is a third party service that we offer to our hosting customers. CloudFlare provides performance, security and availability to web properties. CloudFlare runs a globally distributed network where they automatically cache static content, filter malicious traffic and help offload big spikes in traffic. On average, a site loads twice as fast, uses 65% fewer server resources and has an additional layer of security.

Hosting Marketers, is excited to announce our partnership with CloudFlare! If you haven’t heard about CloudFlare before, their value proposition is simple: they’ll make any website twice as fast and protect it from a broad range of web threats.

Today, hundreds of thousands of websites—ranging from individual blogs to e-commerce sites to the websites of Fortune 500 companies to national governments—use CloudFlare to make their sites faster and more secure. They power more than 65 billion monthly page views—more than Amazon, Wikipedia, Twitter, Zynga, AOL, Apple, Bing, eBay, PayPal and Instagram combined—and over 25% of the Internet’s population regularly passes through our network.

red5 out of memory exception

I’m trying to analyze heap dump of my application which is made when out of memory exception occurred.
I have video on demand application on red5 1.0.1 Final server and Flash client which is written in AS 3 and communicate with server through RTMPT

Why so much messages is accumulated in RTMPTConnection.pendingOutMessages ? See attachments for details.

any custom functions or config?
Piotr
no custom configs. What do you mean when talk about functions?

Well what does you app do exactly, perhaps you start some process that never finishes?

Can you post the custom configs (a diff file of compared to the originals) ? Now I’m not an expert on red5, but it would help to solve your issue by some of the smart folks in this group.
Cheers,

Piotr

May be this exceptions lead to memory leak? I found them in my log.
Also I found in profiler than org.red5.server.net.rtmpt.RTMPTConnection instances are never terminated after I close flash player or close browser tab. Their count grows.org.red5.server.net.protocol.ProtocolException: Error during decoding
at org.red5.server.net.rtmp.codec.RTMPProtocolDecoder.decode(RTMPProtocolDecoder.java:195) ~[red5-server-1.0.jar:na]
at org.red5.server.net.rtmp.codec.RTMPProtocolDecoder.decodeBuffer(RTMPProtocolDecoder.java:116) ~[red5-server-1.0.jar:na]
at org.red5.server.net.rtmpt.BaseRTMPTConnection.decode(BaseRTMPTConnection.java:195) ~[red5-server-1.0.jar:na]
at org.red5.server.net.rtmpt.RTMPTServlet.handleSend(RTMPTServlet.java:336) ~[red5-server-1.0.jar:na]
at org.red5.server.net.rtmpt.RTMPTServlet.service(RTMPTServlet.java:419) ~[red5-server-1.0.jar:na]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) ~[javaee-api-5.1.2.jar:5.1.2]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:470) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:615) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcessor.java:891) ~[tomcat-coyote-6.0.36.jar:6.0.36]
at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:750) ~[tomcat-coyote-6.0.36.jar:6.0.36]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:2282) ~[tomcat-coyote-6.0.36.jar:6.0.36]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) ~[na:1.7.0_25]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) ~[na:1.7.0_25]
at java.lang.Thread.run(Thread.java:724) ~[na:1.7.0_25]
Caused by: java.lang.IllegalStateException: Invalid RTMP state: 5, nothing to decode
at org.red5.server.net.rtmp.codec.RTMPProtocolDecoder.decode(RTMPProtocolDecoder.java:189) ~[red5-server-1.0.jar:na]
… 21 common frames omitted

java.lang.NullPointerException: null
at org.red5.server.net.rtmpt.BaseRTMPTConnection.read(BaseRTMPTConnection.java:204) ~[red5-server-1.0.jar:na]
at org.red5.server.net.rtmpt.RTMPTServlet.handleSend(RTMPTServlet.java:341) ~[red5-server-1.0.jar:na]
at org.red5.server.net.rtmpt.RTMPTServlet.service(RTMPTServlet.java:419) ~[red5-server-1.0.jar:na]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) ~[javaee-api-5.1.2.jar:5.1.2]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:470) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:615) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) ~[catalina-6.0.36.jar:6.0.36]
at org.apache.coyote.http11.Http11NioProcessor.process(Http11NioProcessor.java:891) ~[tomcat-coyote-6.0.36.jar:6.0.36]
at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:750) ~[tomcat-coyote-6.0.36.jar:6.0.36]
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:2282) ~[tomcat-coyote-6.0.36.jar:6.0.36]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) ~[na:1.7.0_25]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) ~[na:1.7.0_25]
at java.lang.Thread.run(Thread.java:724) ~[na:1.7.0_25]

Between 1.0.1 and 1.0.2 (trunk) the encode/decode and connection handling were overhauled; I would suggest trying the latest red5 with your application as all known memory leaks have now been fixed.

This bug was reproduced on 1.0.2. I’ll try use version 1.0. It is likely more stable. Bug is reproduced after 3 hours of playing live video in flash player. Flash player was crashed after that (due to unknown issue) and soon OOM appears.

I can confirm this bug exists in red5 1.0.1, red5 1.0.2 and not exists in red5 1.0.0.
Reproducing steps:
1. Install demo version of YourKit java profiler.
2. Run red5 with command line arguments:
-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=”C:\path” -agentpath:”C:\Program Files\YourKit Java Profiler 2013 build 13052\bin\win32\yjpagent.dll”
3. Connect to your red5 with YourKit
4. Provide any live streming to red5 (I’ve used ffmpeg)
5. Start playing live stream in browser (I’ve used Chorme) from red5.
6. Suspend process of browser (I’ve used Sysinternals Process Explorer). That action results in adobe flash plugin crashes.
7. Look at Yourkit->Memory->Class list. Type RTMPTConnection in search string and push Refresh many times. You can see that size of RTMPTConnection.PendingData constantly increases.
Screenshot of RTMPTConnection instance:

Red5 1.0.1 and Red5 1.0.2 after crash flash plugin starts accumulate data in RTMPTConnection.PendingData

Red5 1.0.0 accumulates data during several seconds after crash, but then the RTMPTConnection.PendingData growing stops

red5 hosting and wowza hosting news

Web Hosting Press Releases and News

HstWire is Focused on Quality

Every press release we distribute is reviewed by a human editor to insure it meets the highest standards of quality. By providing better quality content, we make it easier for journalists to cover your news.

Why Choose HstWire?

HstWire gets your news straight to the search engines that everyone uses, like Google, Yahoo and Bing. HstWire’s search engine friendly releases mean that people will find your business more easily.
HstWire is one of the easiest ways to boost your visibility online because we use search engine-friendly releases. You can include images, links and even videos in your HstWire releases, which can make it easier for prospects and customers to find you online.

server streaming with wowza

Hosting Marketers has started offering on all its hosting plans including hybrid servers wowza hosting. Wowza has the advantage of red5 that it can stream to Apple devices, iphones and iPads.

Stream Types

In Wowza Media Server 3, MediaStreams represent an incoming or outgoing stream of video, audio or metadata. Wowza Server provides a mechanism for defining custom server-side MediaStream implementations or stream types. These stream types are configured using the Streams/StreamType property in the Application.xml file. The following table lists the more commonly used stream types and their intended use (for a complete list, consult the User’s Guide):

  • default: Video on demand streaming of static Flash media, H.264/AAC and MP3 content
  • record: Video recording
  • live: Publish and play live video content (best for one-to-many streaming of live events)
  • live-lowlatency: Publish and play live video content (best for one-to-one or one-to-few video/audio chat applications)
  • live-record: Same as live plus content will be recorded
  • shoutcast: Audio re-streaming of a SHOUTcast/Icecast MP3 or AAC+ audio stream
  • shoutcast-record: Same as shoutcast plus content will be recorded
  • liverepeater-origin: Origin stream type used by live stream repeater to deliver a single streaming using origin/edge configuration
  • liverepeater-edge: Edge stream type used by live stream repeater to deliver a single stream using origin/edge configuration
  • rtp-live: Re-streaming of an RTSP/RTP, native RTP or MPEG-TS stream
  • rtp-live-record: Same as rtp-live plus content will be recorded

 

Supported Media

Wowza Media Server 3 supports the following media file formats: FLV (Flash Video), MP4 (QuickTime container) and MP3 content (see table below for common file extensions). To play video on demand content, the proper prefix must be prepended to the file name to create a stream name. For example to play the MP4 file mycoolvideo.mov use the stream name mp4:mycoolvideo.mov. The following table lists the more common file type prefixes (for a complete list consult the User’s Guide):

  • flv: FLV (Flash Video – this is the default media type so the qualifier and the file extension can be omitted)

    Example: “flv:mycoolvideo.flv”

  • mp4: MP4 (QuickTime container – .mp4, .f4v, .mov, .m4v, .mp4a, .3gp, and .3g2)

    Example: “mp4:mycoolvideo.mov”

  • mp3: MP3 (.mp3)

    Example: “mp3:mycoolsong.mp3”

  • smil: SMIL (XML files used to configure multi-bitrate streams – .smil)

Please visit Wowza Hosting for more information.

red5 shared hosting

In the last seven months some web hosting companies have started to offer shared red5 hosting on most their hosting plans. Although offering red5 means high quality servers and availability of large bandwidth the quality of the new servers available means that it is now possible to offer it.

This trend is due that red5 hosting is a necessary component for video streaming, and it has become popular on community sites, users spend hours watching video chat type sites which offer 2 way video chat or conference video.

The software’s on this servers offering red5 hosting are essentially ffmpeg, Mencoder, Mplayer, Libvorbis and Lame MP3 Encoder. With red5 shared hosting, the users are also bestowed with quick, near perfect and secure conversion of their video files to flv format which is then show on the browser with no need to upload anything on your computer.