Making a new application in Red5 for the Sound Recorder

  1. Make a new directory under the webapps directory. The name of the directory will be name of the application. For example, name the directory "sndrec."
  2. Create a file in your new directory called "web.xml." Paste this code into the file, changing the name of the application as needed (in this sample, the name of the application is "sndrec."). The name of the application appears twice in the file, and is highlighted in red for your convenience.

    <?xml version="1.0" encoding="ISO-8859-1"?>
    <web-app
    xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
    version="2.4">

    <display-name>sndrec</display-name>

    <context-param>
    <param-name>webAppRootKey</param-name>
    <param-value>/sndrec</param-value>
    </context-param>

    <listener>
    <listener-class>org.red5.logging.ContextLoggingListener</listener-class>
    </listener>

    <filter>
    <filter-name>LoggerContextFilter</filter-name>
    <filter-class>org.red5.logging.LoggerContextFilter</filter-class>
    </filter>

    <filter-mapping>
    <filter-name>LoggerContextFilter</filter-name>
    <url-pattern>/*</url-pattern>
    </filter-mapping>

    <security-constraint>
    <web-resource-collection>
    <web-resource-name>Forbidden</web-resource-name>
    <url-pattern>/streams/*</url-pattern>
    </web-resource-collection>
    <auth-constraint/>
    </security-constraint>

    </web-app>


  3. Restart Red5 (e.g., service red5 restart).
  4. You're done.
Share the love
Is this site helpful? Is the information worth ten dollars to you?
Consider helping me pay for hosting.