/usr/share/doc/red5/html/configuration-files.html is in red5-doc 1.0~svn4374-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 | <html><head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Chapter 3. Configuration Files</title><link rel="stylesheet" type="text/css" href="html.css"><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="Red5 - Reference Documentation"><link rel="up" href="getting-started.html" title="Part I. Getting Started"><link rel="prev" href="frequently-asked-questions.html" title="Chapter 2. Frequently Asked Questions"><link rel="next" href="migration-guide.html" title="Chapter 4. Migration Guide"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div xmlns="http://www.w3.org/TR/xhtml1/transitional" style="background-color:white;border:none;height:73px;border:1px solid black;"><a style="border:none;" href="http://osflash.org/red5" title="Red5 Open Source Flash Server"><img style="border:none;" src="images/red5-banner.png"></img></a><a style="border:none;" href="http://osflash.org/red5" title="Red5 Open Source Flash Server"><img style="border:none;position:absolute;padding-top:5px;right:42px;" src="images/red5-banner-logo.png"></img></a></div><div class="chapter"><div class="titlepage"><div><div><h2 class="title"><a name="configuration-files"></a>Chapter 3. Configuration Files</h2></div></div></div>
<div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d5e659"></a>3.1. Directory "conf"</h2></div></div></div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e661"></a>3.1.1. jetty.xml</h3></div></div></div>
<p>The settings of the HTTP server and servlet container are specified using this file. It runs on
all available interfaces on port 5080 by default. </p>
<p>See the Jetty homepage
<a class="ulink" href="http://jetty.mortbay.org/jetty6/" target="_top">http://jetty.mortbay.org/jetty6/</a> for further information about the
syntax of this file.
</p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e666"></a>3.1.2. keystore</h3></div></div></div>
<p>Contains a sample private key and certificate to be used for secure connections. </p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e669"></a>3.1.3. log4j.properties</h3></div></div></div>
<p>Controls the log levels and output handlers for the logging subsystem. </p>
<p>Further information about log4j can be found on the official homepage
<a class="ulink" href="http://logging.apache.org/log4j/docs/" target="_top">http://logging.apache.org/log4j/docs/</a>.
</p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e674"></a>3.1.4. realm.properties (Jetty)</h3></div></div></div>
<p>This file defines users passwords and roles that can be used for protected areas. </p>
<p>The format is: </p>
<div class="literallayout"><p><br>
<username>: <password>[,<rolename> ...] <br>
</p></div>
<p>Passwords may be clear text, obfuscated or checksummed. The class
"org.mortbay.util.Password" should be used to generate obfuscated passwords or
password checksums </p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e680"></a>3.1.5. tomcat-users.xml (Tomcat)</h3></div></div></div>
<p>This file defines users passwords and roles that can be used for protected areas.</p>
<p>The format is: </p>
<pre class="programlisting">
<user name="<username>" password="<password>" roles="[,<rolename> ...]" />
</pre>
<p>Passwords may be clear text, obfuscated or checksummed. For information on different
digest support or available realm implementations use the how-to:
<a class="ulink" href="http://tomcat.apache.org/tomcat-5.5-doc/realm-howto.html" target="_top">http://tomcat.apache.org/tomcat-5.5-doc/realm-howto.html</a>
</p>
<p>Further information about tomcat realms can be found on the official homepage
<a class="ulink" href="http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/catalina/realm/package-summary.html" target="_top">http://tomcat.apache.org/tomcat-5.5-doc/catalina/docs/api/org/apache/catalina/realm/package-summary.html</a>
</p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e689"></a>3.1.6. red5.globals</h3></div></div></div>
<p>Specifies the path to the configuration file for the default global context to be used for Red5. </p>
<p>By default this file is located in "/webapps/red5-default.xml". </p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e693"></a>3.1.7. red5.properties</h3></div></div></div>
<p>File containing key / value pairs to configure the host and port of basic services like RTMP
or remoting. </p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e696"></a>3.1.8. red5.xml</h3></div></div></div>
<p>The main configuration file that wires together the context tree. It takes care of loading
"red5-common.xml" and "red5-core.xml" and sets up the rest of the server. This is the
first file to be loaded by Red5. The J2EE container is selected in this configuration file by
configuring one of the following bean elements. </p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Jetty </p>
</li></ul></div>
<pre class="programlisting">
<bean id="jetty6.server" class="org.red5.server.JettyLoader" init-method="init" autowire="byType" />
</pre>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Tomcat</p>
</li></ul></div>
<pre class="programlisting">
<bean id="tomcat.server" class="org.red5.server.TomcatLoader" init-method="init" destroy-method="shutdown">
... cut for brevity ...
</bean>
</pre>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e707"></a>3.1.9. red5-common.xml</h3></div></div></div>
<p>Classes that are shared between all child contexts are declared in this file. It contains
information about the object serializers / deserializers, the codecs to be used for the
network protocols as well as the available video codecs.
Configuration files used by Red5 </p>
<p>The object (FLV) cache is configured / spring-wired in this file. Four implementations are
currently available; The first one is our own creation (simple byte-buffers) and the others
use WhirlyCache, or Ehcache. If no caching is desired then the NoCache implementation
should be specified like so: </p>
<pre class="programlisting">
<bean id="object.cache" class="org.red5.server.cache.NoCacheImpl"/>
</pre>
<p>The other bean configurations are as follows (Only one may be used at a time): </p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Red5 homegrown simple example </p>
</li></ul></div>
<pre class="programlisting">
<bean id="object.cache" class="org.red5.server.cache.CacheImpl" init-method="init" autowire="byType">
<property name="maxEntries"><value>5</value></property>
</bean>
</pre>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>EhCache
<a class="ulink" href="http://ehcache.sourceforge.net/" target="_top">http://ehcache.sourceforge.net/</a>
</p>
</li></ul></div>
<pre class="programlisting">
<bean id="object.cache" class="org.red5.server.cache.EhCacheImpl" init-method="init">
<property name="diskStore" value="java.io.tmpdir" />
<property name="memoryStoreEvictionPolicy" value="LFU" />
<property name="cacheManagerEventListener"><null/></property>
<property name="cacheConfigs">
<list>
<bean class="net.sf.ehcache.config.CacheConfiguration">
<property name="name" value="flv.cache" />
<property name="maxElementsInMemory" value="5" />
<property name="eternal" value="false" />
<property name="timeToIdleSeconds" value="0" />
<property name="timeToLiveSeconds" value="0" />
<property name="overflowToDisk" value="false" />
<property name="diskPersistent" value="false" />
</bean>
</list>
</property>
</bean>
</pre>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Whirlycache
<a class="ulink" href="https://whirlycache.dev.java.net/" target="_top">https://whirlycache.dev.java.net/</a>
</p>
</li></ul></div>
<pre class="programlisting">
<bean id="object.cache" class="org.red5.server.cache.WhirlyCacheImpl" init-method="init" autowire="b
<property name="maxEntries" value="5" />
<property name="cacheConfig">
<bean class="com.whirlycott.cache.CacheConfiguration">
<property name="name" value="flv.cache" />
<property name="maxSize" value="5" />
<!-- This policy removes cached items, biased towards least frequently used (LFU) Items -->
<property name="policy"><value>com.whirlycott.cache.policy.LFUMaintenancePolicy</value></property>
<!-- This policy removes cached items, biased towards least recently used (LRU) Items -->
<!-- property name="policy"><value>com.whirlycott.cache.policy.LRUMaintenancePolicy</value></propert
<!-- This policy removes cache items in the order in which they were added -->
Configuration files used by Red5
<!-- property name="policy"><value>com.whirlycott.cache.policy.FIFOMaintenancePolicy</value></proper
<!-- A predicate for filtering Collections of Items based on their expiration time -->
<!-- property name="policy"><value>com.whirlycott.cache.policy.ExpirationTimePredicate</value></prop
<!-- property name="backend"><value>com.whirlycott.cache.impl.ConcurrentHashMapImpl</value></propert
<property name="backend"><value>com.whirlycott.cache.impl.FastHashMapImpl</value></property>
</bean>
</pre>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e727"></a>3.1.10. red5-core.xml</h3></div></div></div>
<p>All available network services are specified here. By default these are RTMP and RTMPT.
The actual settings for the RTMPT server can be found in "red5-rtmpt.xml" when using
Jetty as the J2EE container. The RTMPT handler is selected by configuring one of the
following bean elements. </p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Jetty</p>
</li></ul></div>
<pre class="programlisting">
<bean id="rtmpt.server" class="org.red5.server.net.rtmpt.RTMPTLoader" init-method="init" autowire="bType"/>
</pre>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Tomcat</p>
</li></ul></div>
<pre class="programlisting">
<bean id="rtmpt.server" class="org.red5.server.net.rtmpt.TomcatRTMPTLoader" init-method="init" autowire="bType">
... cut for brevity ...
</bean>
</pre>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e738"></a>3.1.11. red5-rtmpt.xml</h3></div></div></div>
<p>Sets up the mapping between the RTMPT URLs and the servlets to use as well as specify
the host and port to run on. By default the RTMPT server runs on all available interfaces on
port 8088. </p>
<p>See the Jetty homepage
<a class="ulink" href="http://jetty.mortbay.org/jetty6/" target="_top">http://jetty.mortbay.org/jetty6/</a> for further information about the
syntax of this file.
</p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e743"></a>3.1.12. web.xml (Tomcat)</h3></div></div></div>
<p>Default web.xml file used by Tomcat. The settings from this file are applied to a web
application before it's own WEB_INF/web.xml file. Further info about the configuration
of this file may be found here:
<a class="ulink" href="http://tomcat.apache.org/tomcat-5.5-doc/jasper-howto.html#Configuration" target="_top">http://tomcat.apache.org/tomcat-5.5-doc/jasper-howto.html#Configuration</a>
</p>
</div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e747"></a>3.1.13. web-default.xml (Jetty)</h3></div></div></div>
<p>Default web.xml file used by Jetty. The settings from this file are applied to a web
application before it's own WEB_INF/web.xml file.</p>
</div>
</div>
<div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d5e750"></a>3.2. Webapp config directory</h2></div></div></div>
<div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="d5e752"></a>3.2.1. red5-web.xml</h3></div></div></div>
<p>Red5 applications are configured within this file. The scripting implementations or Java
applications are configured via Spring bean elements. </p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Java Application</p>
</li></ul></div>
<pre class="programlisting">
<bean id="web.handler" class="org.red5.server.webapp.oflaDemo.Application" singleton="true" />
</pre>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Javascript / Rhino application </p>
</li></ul></div>
<pre class="programlisting">
<bean id="web.handler" class="org.red5.server.script.rhino.RhinoScriptFactory">
<constructor-arg index="0" value="classpath:applications/main.js"/>
<!-- Implemented interfaces -->
<constructor-arg index="1">
<list>
<value>org.red5.server.api.IScopeHandler</value>
<value>org.red5.server.adapter.IApplication</value>
</list>
</constructor-arg>
<!-- Extended class -->
<constructor-arg index="2">
<value>org.red5.server.adapter.ApplicationAdapter</value>
</constructor-arg>
</bean>
</pre>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
<p>Ruby application </p>
</li></ul></div>
<pre class="programlisting">
<bean id="web.handler" class="org.red5.server.script.jruby.JRubyScriptFactory">
<constructor-arg index="0" value="classpath:applications/main.rb"/>
<constructor-arg index="1">
<list>
<value>org.red5.server.api.IScopeHandler</value>
<value>org.red5.server.adapter.IApplication</value>
</list>
</constructor-arg>
</bean>
</pre>
</div>
</div>
</div><div xmlns="http://www.w3.org/TR/xhtml1/transitional" class="navfooter"><hr></hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="frequently-asked-questions.html">Prev</a> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right"> <a accesskey="n" href="migration-guide.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 2. Frequently Asked Questions </td><td width="20%" align="center"><span style="color:white;font-size:90%;"><a href="http://osflash.org/red5" title="Red5">Red5 Open Source Flash Server</a></span></td><td width="40%" align="right" valign="top"> Chapter 4. Migration Guide</td></tr></table></div></body></html>
|