Permalink
Browse files

fixed startup issues

  • Loading branch information...
jsloyer committed Jun 1, 2015
1 parent 4a65191 commit 22e4f3131b40198621615f17532efc28f88924b6
@@ -26,5 +26,15 @@
<classpathentry kind="lib" path="dep-jar/junit-4.11.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/4"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="lib" path="dep-jar/servlet-api.jar"/>
<classpathentry kind="lib" path="dep-jar/activation-1.1.jar"/>
<classpathentry kind="lib" path="dep-jar/commons-lang-2.3.jar"/>
<classpathentry kind="lib" path="dep-jar/jaxb-api-2.2.jar"/>
<classpathentry kind="lib" path="dep-jar/jaxb-impl-2.2.1.1.jar"/>
<classpathentry kind="lib" path="dep-jar/slf4j-api-1.6.1.jar"/>
<classpathentry kind="lib" path="dep-jar/slf4j-simple-1.6.1.jar"/>
<classpathentry kind="lib" path="dep-jar/stax-api-1.0-2.jar"/>
<classpathentry kind="lib" path="dep-jar/wink-common-1.4.jar"/>
<classpathentry kind="lib" path="dep-jar/wink-server-1.4.jar"/>
<classpathentry kind="output" path="WebContent/WEB-INF/classes"/>
</classpath>
@@ -2,3 +2,4 @@ twitter4j.properties
*.class
src/com/ibm/personafusion/service/TwitterClient.java
.DS_Store
output/manifest.yml
@@ -5,18 +5,22 @@
id="WebApp_ID" version="2.5">
<display-name>Hello Java</display-name>
<servlet>
<servlet-name>InitDB</servlet-name>
<servlet-class>com.ibm.personafusion.InitDB</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet>
<servlet-name>JAX-RS Servlet</servlet-name>
<servlet-class>org.apache.wink.server.internal.servlet.RestServlet</servlet-class>
<init-param>
<param-name>applicationConfigLocation</param-name>
<param-value>/WEB-INF/resources</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>JAX-RS Servlet</servlet-name>
<url-pattern>/api/*</url-pattern>
</servlet-mapping>
</web-app>
@@ -24,6 +24,8 @@
<pathelement location="dep-jar/org.ektorp-1.2.2.jar"/>
<pathelement location="dep-jar/junit-4.11.jar"/>
<pathelement location="dep-jar/hamcrest-core-1.3.jar"/>
<pathelement location="dep-jar/servlet-api.jar"/>
</path>
<target name="init">
<mkdir dir="bin"/>
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN +2.11 MB (140%) output/webStarterApp.war
Binary file not shown.
@@ -0,0 +1,17 @@
package com.ibm.personafusion;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import com.ibm.personafusion.db.CloudantClient;
public class InitDB extends HttpServlet
{
public void init() throws ServletException
{
System.out.println("Initalizing DB");
CloudantClient cc = new CloudantClient();
System.out.println("DB has " + cc.getAllPeople().size() + " people in it");
}
}

0 comments on commit 22e4f31

Please sign in to comment.