]> git.argeo.org Git - gpl/argeo-slc.git/blob - server/org.argeo.slc.siteserver/bundles/simple-webapp.war/index.html
Simplify setup
[gpl/argeo-slc.git] / server / org.argeo.slc.siteserver / bundles / simple-webapp.war / index.html
1 <HTML><HEAD><TITLE>Spring-DM Samples: Simple WebApp</TITLE>
2 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
3 <link rel="stylesheet" href="styles/springsource.css" type="text/css" />
4 <title>Hello OSGi World</title>
5 </head>
6
7 </HEAD>
8
9 <BODY bgColor=white>
10 <div id="main_wrapper">
11 <h1>
12 Spring-DM Simple OSGi Web Application
13 </h1>
14
15 <h2>Introduction</h2>
16 This application demonstrates the use of web applications (WARs)
17 inside OSGi through Spring Dynamic Modules.
18 You can view static resources (like this page), servlets and
19 JSPs. The next section describes the dynamic pages available in this WAR.
20
21 <h2>Sample content</h2>
22
23 <p>You can select one of the following links to interact with the servlets and JSPs
24 available in this sample.
25 </p>
26
27 <h3>Servlets</h3>
28
29 The application contains two servlets:
30 <ul>
31 <li>Hello OSGi World servlet
32 <p/>
33 Simply click on the button below (which will send a
34 a <tt>POST</tt> request to a hello world servlet).
35 <form action="helloWorldServlet" method="POST">
36 <input type="submit" value="Call Hello World Servlet"/>
37 </form>
38 </li>
39 <li>
40 A OSGi content serving servlet
41
42 <p/> The servlet sends to the browser
43 the raw content of resources found inside the bundle. This main usage of this servlet
44 is to see, direclty from the web application, the servlet and JSP <a href="#sources">sources</a>.
45
46 <!--
47 <h4>Tip</h4>
48
49 The Content Servlet can serve <i>any</i> resource from the OSGi space through Spring-DM
50 Spring-DM <tt>ResourceLoader</tt>. If no prefix is specified, resources are resolved from
51 the servlet own bundle. However, by using <tt>classpath:</tt>, <tt>osgibundlejar:</tt> you can get access to the other <i>spaces</i>
52 defined by OSGi (for more information, see OsgiBundleResourceLoader <a href="http://static.springframework.org/osgi/docs/current/api/org/springframework/osgi/io/OsgiBundleResourceLoader.html">javadoc</a>).
53 <br/>
54
55 <form action="contentServlet" method="GET">
56 <input type="
57 <input type="submit" value="Get resource">
58 </form>
59 -->
60
61 </li>
62 </ul>
63
64 <h3>Java Server Pages</h3>
65 The sample application provides two types of Java Server Pages:
66 <ul>
67 <li>A <a href="hello-osgi-world.jsp">bare-bone</a> page that accesses the session</li>
68 <li>A <a href="jsp-tag-osgi-world.jsp">tag-based</a> page that uses the standard taglib </li>
69 </ul>
70
71
72 <p/>
73 While the servlets/pages are simplistic, they show the main functionality working inside an OSGi platform.
74
75 <h2>Sources</h2><a name="sources"> </a>
76 To view the Servlet and JSP sources directly from the browser, use one of the links above. The content itself
77 is served through a Servlet (the Content Servlet below) that sends to the browser the content of the files
78 found in its bundle classpath.
79
80 <ul>
81 <li><a href="./resourceServlet?resource=/WEB-INF/classes/org/springframework/osgi/samples/simplewebapp/servlet/HelloOsgiWorldServlet.java">Hello World Servlet</a></li>
82 <li><a href="./resourceServlet?resource=/WEB-INF/classes/org/springframework/osgi/samples/simplewebapp/servlet/ResourceServingServlet.java">Resource Serving Servlet</a></li>
83 <li><a href="./resourceServlet?resource=/hello-osgi-world.jsp">bare-bone JSP</a></li>
84 <li><a href="./resourceServlet?resource=/jsp-tag-osgi-world.jsp">tag-based JSP</a></li>
85 <li><a href="./resourceServlet?resource=/WEB-INF/web.xml">Web application <tt>web.xml</tt></a></li>
86 <li><a href="./resourceServlet?resource=">WAR OSGi bundle content</a></li>
87 </ul>
88
89 <h2>Requirements</h2>
90
91 This sample requires:
92 <ul>
93 <li>an OSGi 4.0+ platform</li>
94 <li>Spring-DM 1.1 + dependencies</li>
95 <li>Apache Tomcat 5.5.x+</li>
96 <li>Apache Jasper 2 Engine </li>
97 </ul>
98
99 Note that all the dependencies are automatically downloaded when running the sample.
100
101 <table class="footer">
102 <tr>
103 <td><a href="./">Home</a></td>
104 <td align="right"><img src="./images/springsource-logo.png"/></td>
105 </tr>
106 </table>
107
108 </div>
109 </BODY>
110 </HTML>