You can subscribe to this list here.
| 2009 |
Jan
|
Feb
(28) |
Mar
(85) |
Apr
(81) |
May
(32) |
Jun
(51) |
Jul
(134) |
Aug
(21) |
Sep
|
Oct
|
Nov
|
Dec
|
|---|
|
From: <id...@us...> - 2009-04-22 19:08:59
|
Revision: 162
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=162&view=rev
Author: idueppe
Date: 2009-04-22 19:08:03 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
add initial project structure for oca-ilias
Modified Paths:
--------------
trunk/cse-ip/pom.xml
Added Paths:
-----------
trunk/cse-ip/oca-ilias/
trunk/cse-ip/oca-ilias/build.xml
trunk/cse-ip/oca-ilias/pom.xml
trunk/cse-ip/oca-ilias/src/
trunk/cse-ip/oca-ilias/src/main/
trunk/cse-ip/oca-ilias/src/main/java/
trunk/cse-ip/oca-ilias/src/main/resources/
trunk/cse-ip/oca-ilias/src/main/resources/META-INF/
trunk/cse-ip/oca-ilias/src/test/
trunk/cse-ip/oca-ilias/src/test/java/
trunk/cse-ip/oca-ilias/src/test/java/de/
trunk/cse-ip/oca-ilias/src/test/java/de/campussource/
trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/
trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/
trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/
trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/Ilias.java
trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/IliasDummyWebServiceServer.java
trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/LectureWebServiceTest.java
trunk/cse-ip/oca-ilias/src/test/resources/
trunk/cse-ip/oca-ilias/src/test/resources/META-INF/
trunk/cse-ip/oca-ilias/src/test/resources/log4j.properties
Added: trunk/cse-ip/oca-ilias/build.xml
===================================================================
--- trunk/cse-ip/oca-ilias/build.xml (rev 0)
+++ trunk/cse-ip/oca-ilias/build.xml 2009-04-22 19:08:03 UTC (rev 162)
@@ -0,0 +1,34 @@
+<project name="cse-ip :: oca :: ilias :: build" default="install" basedir=".">
+ <condition property="maven.executable" value="mvn.bat" else="mvn"><os family="windows" /></condition>
+
+ <target name="compile">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="clean">
+ <exec executable="${maven.executable}">
+ <arg line="clean"/>
+ </exec>
+ </target>
+
+ <target name="install" depends="clean">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="eclipse">
+ <exec executable="${maven.executable}">
+ <arg line="eclipse:clean eclipse:eclipse"/>
+ </exec>
+ </target>
+
+ <target name="wsimport">
+ <exec executable="${maven.executable}">
+ <arg line="jaxws:wsimport"/>
+ </exec>
+ </target>
+
+</project>
Property changes on: trunk/cse-ip/oca-ilias/build.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-ilias/pom.xml
===================================================================
--- trunk/cse-ip/oca-ilias/pom.xml (rev 0)
+++ trunk/cse-ip/oca-ilias/pom.xml 2009-04-22 19:08:03 UTC (rev 162)
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <artifactId>cse-ip</artifactId>
+ <groupId>de.campussource.cse</groupId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>oca-ilias</artifactId>
+ <packaging>ejb</packaging>
+ <name>Outbound Client Adapter for Ilias</name>
+ <version>1.0-SNAPSHOT</version>
+
+ <dependencies>
+ <dependency>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>test-utilities</artifactId>
+ <version>${pom.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.xml.ws</groupId>
+ <artifactId>jaxws-rt</artifactId>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.ejb</groupId>
+ <artifactId>ejb-api</artifactId>
+ <version>3.0</version>
+ <!-- <scope>provided</scope>-->
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <testResources>
+ <testResource>
+ <directory>${basedir}/src/test/resources</directory>
+ <includes>
+ <include>**/*</include>
+ </includes>
+ </testResource>
+ </testResources>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <version>1.2</version>
+ <executions>
+ <execution>
+ <id>add-test-source</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>add-test-source</goal>
+ </goals>
+ <configuration>
+ <sources>
+ <source>${project.build.directory}/sources-generated</source>
+ </sources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-ejb-plugin</artifactId>
+ <configuration>
+ <ejbVersion>3.0</ejbVersion>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>jaxws-maven-plugin</artifactId>
+ <version>1.10</version>
+ <executions>
+ <execution>
+ <phase>generate-test-sources</phase>
+ <goals>
+ <goal>wsimport</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <staleFile>${project.build.directory}/jaxws/stale/wsdl.IliasWebService.done</staleFile>
+ <packageName>de.campussource.cse.oca.ilias</packageName>
+ <keep>true</keep>
+ <verbose>true</verbose>
+ <wsdlDirectory>${basedir}/src/test/resources</wsdlDirectory>
+ <sourceDestDir>${project.build.directory}/sources-generated</sourceDestDir>
+ <wsdlLocation>http://localhost:12345/ilias?wsdl</wsdlLocation>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
\ No newline at end of file
Property changes on: trunk/cse-ip/oca-ilias/pom.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/Ilias.java
===================================================================
--- trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/Ilias.java (rev 0)
+++ trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/Ilias.java 2009-04-22 19:08:03 UTC (rev 162)
@@ -0,0 +1,10 @@
+package de.campussource.cse.oca.ilias;
+
+import javax.jws.WebService;
+
+// FIXME
+@WebService(name = "LectureWebService", targetNamespace = "http://www.openuss.org/services", endpointInterface = "de.campussource.cse.oca.openuss.LectureWebService")
+public class Ilias {
+
+
+}
Property changes on: trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/Ilias.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/IliasDummyWebServiceServer.java
===================================================================
--- trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/IliasDummyWebServiceServer.java (rev 0)
+++ trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/IliasDummyWebServiceServer.java 2009-04-22 19:08:03 UTC (rev 162)
@@ -0,0 +1,14 @@
+package de.campussource.cse.oca.ilias;
+
+import javax.swing.JOptionPane;
+import javax.xml.ws.Endpoint;
+
+public class IliasDummyWebServiceServer {
+
+ public static void main(String[] args) {
+ Endpoint endpoint = Endpoint.publish("http://localhost:8080/openuss", new Ilias());
+ JOptionPane.showMessageDialog(null,"OpenUSS Dumy Server running.");
+ endpoint.stop();
+ }
+
+}
Property changes on: trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/IliasDummyWebServiceServer.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/LectureWebServiceTest.java
===================================================================
--- trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/LectureWebServiceTest.java (rev 0)
+++ trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/LectureWebServiceTest.java 2009-04-22 19:08:03 UTC (rev 162)
@@ -0,0 +1,47 @@
+package de.campussource.cse.oca.ilias;
+
+import javax.xml.ws.Endpoint;
+
+import org.junit.AfterClass;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+
+public class LectureWebServiceTest {
+
+ private static Endpoint endpoint;
+// private LectureWebService service;
+
+ @BeforeClass
+ public static void setupClass() {
+// OpenUSS eis = new OpenUSS();
+// endpoint = Endpoint.publish("http://localhost:12345/openuss", eis);
+ }
+
+ @AfterClass
+ public static void tearDownClass() {
+ if (endpoint != null) {
+ endpoint.stop();
+ }
+ }
+
+ @Before
+ public void setUp() {
+// service = new OpenUSSService().getLectureWebServicePort();
+ }
+
+ @Test
+ public void testFindUser() {
+ // FIXME Test logic is not correct. User that doesn't exist should return null.
+// assertNotNull(service.findUser("test"));
+ }
+
+ @Test
+ public void testGetInstitute() {
+// Institute institute = service.getInstitute(12345L);
+// assertNotNull(institute);
+// assertEquals(Long.valueOf(12345L), institute.getId());
+ }
+
+}
Property changes on: trunk/cse-ip/oca-ilias/src/test/java/de/campussource/cse/oca/ilias/LectureWebServiceTest.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-ilias/src/test/resources/log4j.properties
===================================================================
--- trunk/cse-ip/oca-ilias/src/test/resources/log4j.properties (rev 0)
+++ trunk/cse-ip/oca-ilias/src/test/resources/log4j.properties 2009-04-22 19:08:03 UTC (rev 162)
@@ -0,0 +1,15 @@
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.Target=System.out
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n
+
+log4j.rootCategory=debug, stdout
+
+log4j.logger.org.hibernate=info
+
+log4j.logger.oracle.toplink=debug
+
+log4j.logger.org.hibernate.SQL=debug
+log4j.logger.org.hibernate.type=debug
+log4j.logger.org.hibernate.id=debug
+log4j.logger.org.hibernate.cache=debug
\ No newline at end of file
Property changes on: trunk/cse-ip/oca-ilias/src/test/resources/log4j.properties
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/cse-ip/pom.xml
===================================================================
--- trunk/cse-ip/pom.xml 2009-04-22 18:56:27 UTC (rev 161)
+++ trunk/cse-ip/pom.xml 2009-04-22 19:08:03 UTC (rev 162)
@@ -106,6 +106,8 @@
<modules>
<module>framework</module>
<module>ica-his-lsf</module>
+ <module>oca-openuss</module>
+ <module>oca-ilias</module>
<module>sc-common</module>
<module>sc-mapper</module>
<module>sc-cdmm</module>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 18:56:38
|
Revision: 161
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=161&view=rev
Author: idueppe
Date: 2009-04-22 18:56:27 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
- refactor mapper-rest to support PUT and GET methods.
Modified Paths:
--------------
trunk/cse-ip/sc-mapper-rest/pom.xml
trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java
trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java
trunk/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java
Modified: trunk/cse-ip/sc-mapper-rest/pom.xml
===================================================================
--- trunk/cse-ip/sc-mapper-rest/pom.xml 2009-04-22 17:56:12 UTC (rev 160)
+++ trunk/cse-ip/sc-mapper-rest/pom.xml 2009-04-22 18:56:27 UTC (rev 161)
@@ -43,6 +43,11 @@
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+
</dependencies>
</project>
\ No newline at end of file
Modified: trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java
===================================================================
--- trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java 2009-04-22 17:56:12 UTC (rev 160)
+++ trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java 2009-04-22 18:56:27 UTC (rev 161)
@@ -4,18 +4,25 @@
import java.util.Map;
import javax.ws.rs.GET;
+import javax.ws.rs.PUT;
import javax.ws.rs.Path;
import javax.ws.rs.PathParam;
import javax.ws.rs.Produces;
+import javax.ws.rs.WebApplicationException;
+import javax.ws.rs.core.Response;
-import de.campussource.cse.common.exception.IdNotFoundException;
+import org.apache.commons.lang.StringUtils;
-@Path("/mapper")
+import de.campussource.cse.mapper.IdentityMapper;
+
+@Path("/mapped")
public class IdentityMapperRestBean {
-
- private Map<Long, String> busToClient = new HashMap<Long, String>();
- private Map<String, Long> clientToBus = new HashMap<String, Long>();
-
+
+ private IdentityMapper mapper;
+
+ private static Map<Long, String> busToClient = new HashMap<Long, String>();
+ private static Map<String, Long> clientToBus = new HashMap<String, Long>();
+
private Long toBus(String client) {
Long bus = clientToBus.get(client);
if (bus == null) {
@@ -23,47 +30,50 @@
busToClient.put(bus, client);
clientToBus.put(client, bus);
}
-
+
return bus;
}
private String toClient(Long bus) {
return busToClient.get(bus);
}
-
- @GET
- @Path("/client/{instanceid}/{objectid}")
+
+ @PUT
+ @Path("/{instanceid}/{objectid}")
@Produces("application/xml")
- public MappedObject toBusId(@PathParam("instanceid") Long clientInstanceId,
+ public MappedObject putMapping(@PathParam("instanceid") Long clientInstanceId,
@PathParam("objectid") String clientObjectId) {
+
+ if (clientInstanceId == null || StringUtils.isEmpty(clientObjectId)) {
+ throw new WebApplicationException(Response.Status.NOT_ACCEPTABLE);
+ }
MappedObject mapped = new MappedObject();
mapped.setBusId(toBus(clientObjectId));
-// mapped.setBusId(mapper.toBusId(clientInstanceId, clientObjectId));
+ // mapped.setBusId(mapper.toBusId(clientInstanceId, clientObjectId));
mapped.setClientInstanceId(clientInstanceId);
mapped.setClientObjectId(clientObjectId);
return mapped;
}
-
+
@GET
- @Path("/bus/{busid}/{instanceid}")
+ @Path("/{busid}/{instanceid}")
@Produces("application/xml")
- public MappedObject toClientObjectId(
- @PathParam("busid") Long busId,
- @PathParam("instanceid") Long clientInstanceId) throws IdNotFoundException {
+ public MappedObject toClientObjectId(@PathParam("busid") Long busId, @PathParam("instanceid") Long clientInstanceId) {
MappedObject mapped = new MappedObject();
mapped.setBusId(busId);
mapped.setClientInstanceId(clientInstanceId);
mapped.setClientObjectId(toClient(busId));
-// mapped.setClientObjectId(mapper.toClientObjectId(busId, clientInstanceId));
-
+ // mapped.setClientObjectId(mapper.toClientObjectId(busId,
+ // clientInstanceId));
+
return mapped;
}
+
+ public void setMapper(IdentityMapper identityMapper) {
+ mapper = identityMapper;
+ }
-// public static void setMapper(IdentityMapper identityMapper) {
-// mapper = identityMapper;
-// }
-
}
Modified: trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java
===================================================================
--- trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java 2009-04-22 17:56:12 UTC (rev 160)
+++ trunk/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java 2009-04-22 18:56:27 UTC (rev 161)
@@ -6,7 +6,10 @@
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;
+import org.apache.commons.lang.builder.ToStringBuilder;
+import org.apache.commons.lang.builder.ToStringStyle;
+
@XmlRootElement(name="Mapped")
@XmlType(name="MappedObjectType", namespace="http://cse.campussource.de/mapper")
@XmlAccessorType(XmlAccessType.FIELD)
@@ -45,4 +48,48 @@
this.clientObjectId = clientObjectId;
}
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((busId == null) ? 0 : busId.hashCode());
+ result = prime * result + ((clientInstanceId == null) ? 0 : clientInstanceId.hashCode());
+ result = prime * result + ((clientObjectId == null) ? 0 : clientObjectId.hashCode());
+ return result;
+ }
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj)
+ return true;
+ if (obj == null)
+ return false;
+ if (getClass() != obj.getClass())
+ return false;
+ MappedObject other = (MappedObject) obj;
+ if (busId == null) {
+ if (other.busId != null)
+ return false;
+ } else if (!busId.equals(other.busId))
+ return false;
+ if (clientInstanceId == null) {
+ if (other.clientInstanceId != null)
+ return false;
+ } else if (!clientInstanceId.equals(other.clientInstanceId))
+ return false;
+ if (clientObjectId == null) {
+ if (other.clientObjectId != null)
+ return false;
+ } else if (!clientObjectId.equals(other.clientObjectId))
+ return false;
+ return true;
+ }
+
+ @Override
+ public String toString() {
+ return new ToStringBuilder(this,ToStringStyle.DEFAULT_STYLE).append(busId).append(clientInstanceId).append(clientObjectId).toString();
+ }
+
+
+
}
Modified: trunk/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java
===================================================================
--- trunk/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java 2009-04-22 17:56:12 UTC (rev 160)
+++ trunk/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java 2009-04-22 18:56:27 UTC (rev 161)
@@ -1,15 +1,19 @@
package de.campussource.cse.mapper.rest;
-import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
+import java.io.StringReader;
import java.net.HttpURLConnection;
import java.net.URL;
+import javax.xml.bind.JAXBContext;
+import javax.xml.bind.Unmarshaller;
+
import org.junit.AfterClass;
import org.junit.BeforeClass;
import org.junit.Test;
@@ -19,7 +23,7 @@
public class RestIdentityMapperIntegrationTest{
- private static final String LOCALHOST = "http://localhost:8888/";
+ private static final String LOCALHOST = "http://localhost:8000/";
private static HttpServer server;
@BeforeClass
@@ -44,11 +48,15 @@
// JOptionPane.showMessageDialog(null, "JAX-RS Server is running!");
// }
- private static String testResourceAtUrl(URL url) throws Exception {
+ private static MappedObject sendHttpRequestToUrl(URL url) throws Exception {
+ return sendHttpRequestToUrl(url,"GET");
+ }
+
+ private static MappedObject sendHttpRequestToUrl(URL url, String method) throws Exception {
try {
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
- connection.setRequestMethod("GET");
+ connection.setRequestMethod(method);
connection.connect();
InputStream is = connection.getInputStream();
@@ -63,7 +71,12 @@
connection.disconnect();
- return buffer.toString();
+
+ JAXBContext context = JAXBContext.newInstance(MappedObject.class);
+ Unmarshaller unmarshaller = context.createUnmarshaller();
+ MappedObject mapped = (MappedObject) unmarshaller.unmarshal(new StringReader(buffer.toString()));
+
+ return mapped;
} catch (IOException e) {
e.printStackTrace();
@@ -72,12 +85,17 @@
}
@Test
- public void testRest() throws Exception {
- String activationText = testResourceAtUrl(new URL(LOCALHOST + "mapper/client/12345/objectid"));
- assertNotNull(activationText);
- assertFalse(activationText.isEmpty());
+ public void testMapper() throws Exception {
+ MappedObject mapped = sendHttpRequestToUrl(new URL(LOCALHOST + "mapped/12345/objectid"), "PUT");
+ assertNotNull(mapped);
+ assertNotNull(mapped.getBusId());
+ assertEquals(Long.valueOf(12345L),mapped.getClientInstanceId());
+ assertEquals("objectid", mapped.getClientObjectId());
+
+ MappedObject loaded = sendHttpRequestToUrl(new URL(LOCALHOST + "mapped/"+mapped.getBusId()+"/12345"));
+ assertEquals(mapped,loaded);
}
-
+
@AfterClass
public static void tearDown() throws IOException {
if (server != null) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 17:56:22
|
Revision: 160
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=160&view=rev
Author: idueppe
Date: 2009-04-22 17:56:12 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
some test enhancements and add a dummy server for testing.
Modified Paths:
--------------
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java
Added Paths:
-----------
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSSDummyWebServiceServer.java
Modified: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java
===================================================================
--- trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java 2009-04-22 17:14:56 UTC (rev 159)
+++ trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java 2009-04-22 17:56:12 UTC (rev 160)
@@ -1,61 +1,49 @@
package de.campussource.cse.oca.openuss;
-import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
import javax.xml.ws.Endpoint;
-import org.junit.After;
+import org.junit.AfterClass;
import org.junit.Before;
+import org.junit.BeforeClass;
import org.junit.Test;
-import de.campussource.cse.common.test.AnnotationInjector;
+public class LectureWebServiceTest {
+ private static Endpoint endpoint;
+ private LectureWebService service;
+ @BeforeClass
+ public static void setupClass() {
+ OpenUSS eis = new OpenUSS();
+ endpoint = Endpoint.publish("http://localhost:12345/openuss", eis);
+ }
-public class LectureWebServiceTest {
-
- private AnnotationInjector injector;
- private Endpoint endpoint;
+ @AfterClass
+ public static void tearDownClass() {
+ if (endpoint != null) {
+ endpoint.stop();
+ }
+ }
@Before
- public void setup() {
- OpenUSS ejb = new OpenUSS();
-// autowireByType(ejb);
- endpoint = Endpoint.publish("http://localhost:12345/openuss", ejb);
+ public void setUp() {
+ service = new OpenUSSService().getLectureWebServicePort();
}
-
- @After
- public void stop() {
- if (endpoint!=null){
- endpoint.stop();
- }
+
+ @Test
+ public void testFindUser() throws LectureLogicException_Exception {
+ // FIXME Test logic is not correct. User that doesn't exist should return null.
+ assertNotNull(service.findUser("test"));
}
-
+
@Test
- public void testWebService() {
- LectureWebService openussService = new OpenUSSService().getLectureWebServicePort();
-
- try {
- assertNull(openussService.findUser("test"));
- } catch (LectureLogicException_Exception e) {
- e.printStackTrace();
- }
+ public void testGetInstitute() throws LectureLogicException_Exception {
+ Institute institute = service.getInstitute(12345L);
+ assertNotNull(institute);
+ assertEquals(Long.valueOf(12345L), institute.getId());
}
-
-// protected void autowireByType(Object object) {
-// //lazyInjectorInitialization();
-// injector = new AnnotationInjector().autowire(object);
-// //injector.autowire(object);
-// }
-
-// /**
-// * Checks whether or not the Injector is already initialized or not.
-// */
-// private void lazyInjectorInitialization() {
-// if (injector == null) {
-// injector = new AnnotationInjector().defaultPersistentUnit(entityManager);
-// }
-// }
-
}
Modified: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java
===================================================================
--- trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java 2009-04-22 17:14:56 UTC (rev 159)
+++ trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java 2009-04-22 17:56:12 UTC (rev 160)
@@ -2,32 +2,25 @@
import java.util.List;
-import javax.ejb.Stateless;
import javax.jws.WebService;
-@Stateless
-@WebService(
- name="LectureWebService",
- targetNamespace="http://www.openuss.org/services",
- endpointInterface="")
-public class OpenUSS implements LectureWebService{
+@WebService(name = "LectureWebService", targetNamespace = "http://www.openuss.org/services", endpointInterface = "de.campussource.cse.oca.openuss.LectureWebService")
+public class OpenUSS implements LectureWebService {
+
@Override
- public boolean assignCourseMember(long courseId, long userId, Role role)
- throws LectureLogicException_Exception {
+ public boolean assignCourseMember(long courseId, long userId, Role role) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return false;
}
@Override
- public Long createCourse(Course course)
- throws LectureLogicException_Exception {
+ public Long createCourse(Course course) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return null;
}
@Override
- public Long createInstitute(Institute institute)
- throws LectureLogicException_Exception {
+ public Long createInstitute(Institute institute) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return null;
}
@@ -39,71 +32,63 @@
}
@Override
- public boolean deleteCourse(long courseId)
- throws LectureLogicException_Exception {
+ public boolean deleteCourse(long courseId) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return false;
}
@Override
- public boolean deleteUser(long userId)
- throws LectureLogicException_Exception {
+ public boolean deleteUser(long userId) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return false;
}
@Override
- public Long findUser(String username)
- throws LectureLogicException_Exception {
- System.out.println("Username: "+username);
+ public Long findUser(String username) throws LectureLogicException_Exception {
+ System.out.println("Username: " + username);
return 1L;
}
@Override
- public Course getCourse(long courseId)
- throws LectureLogicException_Exception {
- // TODO Auto-generated method stub
- return null;
+ public Course getCourse(long courseId) throws LectureLogicException_Exception {
+ Course course = new Course();
+ course.setId(courseId);
+ return course;
}
@Override
- public Institute getInstitute(long instituteId)
- throws LectureLogicException_Exception {
- // TODO Auto-generated method stub
- return null;
+ public Institute getInstitute(long instituteId) throws LectureLogicException_Exception {
+ Institute institute = new Institute();
+ institute.setId(instituteId);
+ return institute;
}
@Override
- public Role isCourseMember(long courseId, long userId)
- throws LectureLogicException_Exception {
+ public Role isCourseMember(long courseId, long userId) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return null;
}
@Override
- public List<Institute> listInstitute(long departmentId)
- throws LectureLogicException_Exception {
+ public List<Institute> listInstitute(long departmentId) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return null;
}
@Override
- public boolean removeCourseMember(long courseId, long userId)
- throws LectureLogicException_Exception {
+ public boolean removeCourseMember(long courseId, long userId) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return false;
}
@Override
- public boolean updateCourse(Course course)
- throws LectureLogicException_Exception {
+ public boolean updateCourse(Course course) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return false;
}
@Override
- public boolean updateInstitute(Institute insitute)
- throws LectureLogicException_Exception {
+ public boolean updateInstitute(Institute insitute) throws LectureLogicException_Exception {
// TODO Auto-generated method stub
return false;
}
Added: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSSDummyWebServiceServer.java
===================================================================
--- trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSSDummyWebServiceServer.java (rev 0)
+++ trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSSDummyWebServiceServer.java 2009-04-22 17:56:12 UTC (rev 160)
@@ -0,0 +1,14 @@
+package de.campussource.cse.oca.openuss;
+
+import javax.swing.JOptionPane;
+import javax.xml.ws.Endpoint;
+
+public class OpenUSSDummyWebServiceServer {
+
+ public static void main(String[] args) {
+ Endpoint endpoint = Endpoint.publish("http://localhost:8080/openuss", new OpenUSS());
+ JOptionPane.showMessageDialog(null,"OpenUSS Dumy Server running.");
+ endpoint.stop();
+ }
+
+}
Property changes on: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSSDummyWebServiceServer.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 17:16:04
|
Revision: 159
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=159&view=rev
Author: idueppe
Date: 2009-04-22 17:14:56 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
fixed build order for oca-openuss by moving OpenUSS.java to test sources
Added Paths:
-----------
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java
Removed Paths:
-------------
trunk/cse-ip/oca-openuss/src/main/java/de/
Added: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java
===================================================================
--- trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java (rev 0)
+++ trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java 2009-04-22 17:14:56 UTC (rev 159)
@@ -0,0 +1,117 @@
+package de.campussource.cse.oca.openuss;
+
+import java.util.List;
+
+import javax.ejb.Stateless;
+import javax.jws.WebService;
+@Stateless
+@WebService(
+ name="LectureWebService",
+ targetNamespace="http://www.openuss.org/services",
+ endpointInterface="")
+public class OpenUSS implements LectureWebService{
+
+ @Override
+ public boolean assignCourseMember(long courseId, long userId, Role role)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public Long createCourse(Course course)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Long createInstitute(Institute institute)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Long createUser(User user) throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public boolean deleteCourse(long courseId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean deleteUser(long userId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public Long findUser(String username)
+ throws LectureLogicException_Exception {
+ System.out.println("Username: "+username);
+ return 1L;
+ }
+
+ @Override
+ public Course getCourse(long courseId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Institute getInstitute(long instituteId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Role isCourseMember(long courseId, long userId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public List<Institute> listInstitute(long departmentId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public boolean removeCourseMember(long courseId, long userId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean updateCourse(Course course)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean updateInstitute(Institute insitute)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean updateUser(User user) throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+}
Property changes on: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/OpenUSS.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ro...@us...> - 2009-04-22 14:28:00
|
Revision: 158
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=158&view=rev
Author: roekens
Date: 2009-04-22 14:27:50 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
initial commit of oca for openuss
breaks maven install at the moment
to build project first call mvn jaxws:wsimport then mvn install (can this be configured?)
passing parameters to stub service does not seem to work - bugfixing needed
Added Paths:
-----------
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java
Added: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java
===================================================================
--- trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java (rev 0)
+++ trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java 2009-04-22 14:27:50 UTC (rev 158)
@@ -0,0 +1,61 @@
+package de.campussource.cse.oca.openuss;
+
+import static org.junit.Assert.assertNull;
+
+import javax.xml.ws.Endpoint;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+import de.campussource.cse.common.test.AnnotationInjector;
+
+
+
+public class LectureWebServiceTest {
+
+ private AnnotationInjector injector;
+ private Endpoint endpoint;
+
+ @Before
+ public void setup() {
+ OpenUSS ejb = new OpenUSS();
+// autowireByType(ejb);
+ endpoint = Endpoint.publish("http://localhost:12345/openuss", ejb);
+ }
+
+ @After
+ public void stop() {
+ if (endpoint!=null){
+ endpoint.stop();
+ }
+ }
+
+ @Test
+ public void testWebService() {
+ LectureWebService openussService = new OpenUSSService().getLectureWebServicePort();
+
+ try {
+ assertNull(openussService.findUser("test"));
+ } catch (LectureLogicException_Exception e) {
+ e.printStackTrace();
+ }
+ }
+
+
+// protected void autowireByType(Object object) {
+// //lazyInjectorInitialization();
+// injector = new AnnotationInjector().autowire(object);
+// //injector.autowire(object);
+// }
+
+// /**
+// * Checks whether or not the Injector is already initialized or not.
+// */
+// private void lazyInjectorInitialization() {
+// if (injector == null) {
+// injector = new AnnotationInjector().defaultPersistentUnit(entityManager);
+// }
+// }
+
+}
Property changes on: trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/LectureWebServiceTest.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ro...@us...> - 2009-04-22 14:26:54
|
Revision: 157
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=157&view=rev
Author: roekens
Date: 2009-04-22 14:26:49 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
initial commit of oca for openuss
breaks maven install at the moment
to build project first call mvn jaxws:wsimport then mvn install (can this be configured?)
passing parameters to stub service does not seem to work - bugfixing needed
Added Paths:
-----------
trunk/cse-ip/oca-openuss/
trunk/cse-ip/oca-openuss/build.xml
trunk/cse-ip/oca-openuss/pom.xml
trunk/cse-ip/oca-openuss/src/
trunk/cse-ip/oca-openuss/src/main/
trunk/cse-ip/oca-openuss/src/main/java/
trunk/cse-ip/oca-openuss/src/main/java/de/
trunk/cse-ip/oca-openuss/src/main/java/de/campussource/
trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/
trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/oca/
trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/oca/openuss/
trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/oca/openuss/OpenUSS.java
trunk/cse-ip/oca-openuss/src/main/resources/
trunk/cse-ip/oca-openuss/src/main/resources/META-INF/
trunk/cse-ip/oca-openuss/src/test/
trunk/cse-ip/oca-openuss/src/test/java/
trunk/cse-ip/oca-openuss/src/test/java/de/
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/
trunk/cse-ip/oca-openuss/src/test/java/de/campussource/cse/oca/openuss/
trunk/cse-ip/oca-openuss/src/test/resources/
trunk/cse-ip/oca-openuss/src/test/resources/LectureWebService.wsdl
trunk/cse-ip/oca-openuss/src/test/resources/META-INF/
trunk/cse-ip/oca-openuss/src/test/resources/log4j.properties
Added: trunk/cse-ip/oca-openuss/build.xml
===================================================================
--- trunk/cse-ip/oca-openuss/build.xml (rev 0)
+++ trunk/cse-ip/oca-openuss/build.xml 2009-04-22 14:26:49 UTC (rev 157)
@@ -0,0 +1,34 @@
+<project name="cse-ip :: oca :: openuss :: build" default="install" basedir=".">
+ <condition property="maven.executable" value="mvn.bat" else="mvn"><os family="windows" /></condition>
+
+ <target name="compile">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="clean">
+ <exec executable="${maven.executable}">
+ <arg line="clean"/>
+ </exec>
+ </target>
+
+ <target name="install" depends="clean">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="eclipse">
+ <exec executable="${maven.executable}">
+ <arg line="eclipse:clean eclipse:eclipse"/>
+ </exec>
+ </target>
+
+ <target name="wsimport">
+ <exec executable="${maven.executable}">
+ <arg line="jaxws:wsimport"/>
+ </exec>
+ </target>
+
+</project>
Property changes on: trunk/cse-ip/oca-openuss/build.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-openuss/pom.xml
===================================================================
--- trunk/cse-ip/oca-openuss/pom.xml (rev 0)
+++ trunk/cse-ip/oca-openuss/pom.xml 2009-04-22 14:26:49 UTC (rev 157)
@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <artifactId>cse-ip</artifactId>
+ <groupId>de.campussource.cse</groupId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>oca-openuss</artifactId>
+ <packaging>ejb</packaging>
+ <name>Outbound Client Adapter for OpenUSS</name>
+ <version>1.0-SNAPSHOT</version>
+
+ <dependencies>
+ <dependency>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>test-utilities</artifactId>
+ <version>${pom.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.xml.ws</groupId>
+ <artifactId>jaxws-rt</artifactId>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.ejb</groupId>
+ <artifactId>ejb-api</artifactId>
+ <version>3.0</version>
+ <!-- <scope>provided</scope>-->
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-collections</groupId>
+ <artifactId>commons-collections</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <testResources>
+ <testResource>
+ <directory>${basedir}/src/test/resources</directory>
+ <includes>
+ <include>**/*</include>
+ </includes>
+ </testResource>
+ </testResources>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <version>1.2</version>
+ <executions>
+ <execution>
+ <id>add-test-source</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>add-test-source</goal>
+ </goals>
+ <configuration>
+ <sources>
+ <source>${project.build.directory}/sources-generated</source>
+ </sources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-ejb-plugin</artifactId>
+ <configuration>
+ <ejbVersion>3.0</ejbVersion>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>jaxws-maven-plugin</artifactId>
+ <version>1.10</version>
+ <executions>
+ <execution>
+ <phase>generate-test-sources</phase>
+ <goals>
+ <goal>wsimport</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <staleFile>${project.build.directory}/jaxws/stale/wsdl.LectureWebService.done</staleFile>
+ <packageName>de.campussource.cse.oca.openuss</packageName>
+ <keep>true</keep>
+ <verbose>true</verbose>
+ <wsdlDirectory>${basedir}/src/test/resources</wsdlDirectory>
+ <sourceDestDir>${project.build.directory}/sources-generated</sourceDestDir>
+ <wsdlLocation>http://localhost:12345/openuss?wsdl</wsdlLocation>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
\ No newline at end of file
Property changes on: trunk/cse-ip/oca-openuss/pom.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/oca/openuss/OpenUSS.java
===================================================================
--- trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/oca/openuss/OpenUSS.java (rev 0)
+++ trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/oca/openuss/OpenUSS.java 2009-04-22 14:26:49 UTC (rev 157)
@@ -0,0 +1,117 @@
+package de.campussource.cse.oca.openuss;
+
+import java.util.List;
+
+import javax.ejb.Stateless;
+import javax.jws.WebService;
+@Stateless
+@WebService(
+ name="LectureWebService",
+ targetNamespace="http://www.openuss.org/services",
+ endpointInterface="")
+public class OpenUSS implements LectureWebService{
+
+ @Override
+ public boolean assignCourseMember(long courseId, long userId, Role role)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public Long createCourse(Course course)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Long createInstitute(Institute institute)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Long createUser(User user) throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public boolean deleteCourse(long courseId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean deleteUser(long userId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public Long findUser(String username)
+ throws LectureLogicException_Exception {
+ System.out.println("Username: "+username);
+ return 1L;
+ }
+
+ @Override
+ public Course getCourse(long courseId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Institute getInstitute(long instituteId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public Role isCourseMember(long courseId, long userId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public List<Institute> listInstitute(long departmentId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public boolean removeCourseMember(long courseId, long userId)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean updateCourse(Course course)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean updateInstitute(Institute insitute)
+ throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+ @Override
+ public boolean updateUser(User user) throws LectureLogicException_Exception {
+ // TODO Auto-generated method stub
+ return false;
+ }
+
+}
Property changes on: trunk/cse-ip/oca-openuss/src/main/java/de/campussource/cse/oca/openuss/OpenUSS.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-openuss/src/test/resources/LectureWebService.wsdl
===================================================================
--- trunk/cse-ip/oca-openuss/src/test/resources/LectureWebService.wsdl (rev 0)
+++ trunk/cse-ip/oca-openuss/src/test/resources/LectureWebService.wsdl 2009-04-22 14:26:49 UTC (rev 157)
@@ -0,0 +1,684 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<wsdl:definitions name="OpenUSSService" targetNamespace="http://www.openuss.org/services" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://www.openuss.org/services" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+ <wsdl:types>
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://www.openuss.org/services/DataTypes" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://www.openuss.org/services/DataTypes">
+ <xs:complexType name="Institute">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="id" type="xs:long"/>
+ <xs:element name="name" type="xs:string"/>
+ <xs:element name="shortcut" type="xs:string"/>
+ <xs:element name="departmentId" type="xs:long"/>
+ <xs:element minOccurs="0" name="description" type="xs:string"/>
+ <xs:element minOccurs="0" name="address" type="xs:string"/>
+ <xs:element minOccurs="0" name="postCode" type="xs:string"/>
+ <xs:element minOccurs="0" name="city" type="xs:string"/>
+ <xs:element minOccurs="0" name="telephone" type="xs:string"/>
+ <xs:element minOccurs="0" name="telefax" type="xs:string"/>
+ <xs:element minOccurs="0" name="website" type="xs:string"/>
+ <xs:element name="email" type="xs:string"/>
+ <xs:element name="ownerName" type="xs:string"/>
+ <xs:element name="ownerId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="Course">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="id" type="xs:long"/>
+ <xs:element name="name" type="xs:token"/>
+ <xs:element minOccurs="0" name="shortcut" type="xs:token"/>
+ <xs:element minOccurs="0" name="description" type="xs:string"/>
+ <xs:element name="instituteId" type="xs:long"/>
+ <xs:element name="startDate" type="xs:dateTime"/>
+ <xs:element minOccurs="0" name="endDate" type="xs:dateTime"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="User">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="id" type="xs:long"/>
+ <xs:element name="username" type="xs:token"/>
+ <xs:element name="password" type="xs:token"/>
+ <xs:element name="email" type="xs:token"/>
+ <xs:element name="firstName" type="xs:token"/>
+ <xs:element name="lastName" type="xs:token"/>
+ <xs:element minOccurs="0" name="title" type="xs:string"/>
+ <xs:element minOccurs="0" name="address" type="xs:string"/>
+ <xs:element minOccurs="0" name="postCode" type="xs:string"/>
+ <xs:element minOccurs="0" name="city" type="xs:string"/>
+ <xs:element minOccurs="0" name="locale" type="xs:string"/>
+ <xs:element minOccurs="0" name="matriculation" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:simpleType name="Role">
+ <xs:restriction base="xs:string">
+ <xs:enumeration value="NONE"/>
+ <xs:enumeration value="PARTICIPANT"/>
+ <xs:enumeration value="ASSISTANT"/>
+ </xs:restriction>
+ </xs:simpleType>
+</xs:schema>
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:ns1="http://www.openuss.org/services/DataTypes" xmlns:tns="http://www.openuss.org/services" attributeFormDefault="unqualified" elementFormDefault="unqualified" targetNamespace="http://www.openuss.org/services">
+ <xs:import namespace="http://www.openuss.org/services/DataTypes"/>
+ <xs:element name="assignCourseMember" type="tns:assignCourseMember"/>
+ <xs:element name="assignCourseMemberResponse" type="tns:assignCourseMemberResponse"/>
+ <xs:element name="createCourse" type="tns:createCourse"/>
+ <xs:element name="createCourseResponse" type="tns:createCourseResponse"/>
+ <xs:element name="createInstitute" type="tns:createInstitute"/>
+ <xs:element name="createInstituteResponse" type="tns:createInstituteResponse"/>
+ <xs:element name="createUser" type="tns:createUser"/>
+ <xs:element name="createUserResponse" type="tns:createUserResponse"/>
+ <xs:element name="deleteCourse" type="tns:deleteCourse"/>
+ <xs:element name="deleteCourseResponse" type="tns:deleteCourseResponse"/>
+ <xs:element name="deleteUser" type="tns:deleteUser"/>
+ <xs:element name="deleteUserResponse" type="tns:deleteUserResponse"/>
+ <xs:element name="findUser" type="tns:findUser"/>
+ <xs:element name="findUserResponse" type="tns:findUserResponse"/>
+ <xs:element name="getCourse" type="tns:getCourse"/>
+ <xs:element name="getCourseResponse" type="tns:getCourseResponse"/>
+ <xs:element name="getInstitute" type="tns:getInstitute"/>
+ <xs:element name="getInstituteResponse" type="tns:getInstituteResponse"/>
+ <xs:element name="isCourseMember" type="tns:isCourseMember"/>
+ <xs:element name="isCourseMemberResponse" type="tns:isCourseMemberResponse"/>
+ <xs:element name="listInstitute" type="tns:listInstitute"/>
+ <xs:element name="listInstituteResponse" type="tns:listInstituteResponse"/>
+ <xs:element name="removeCourseMember" type="tns:removeCourseMember"/>
+ <xs:element name="removeCourseMemberResponse" type="tns:removeCourseMemberResponse"/>
+ <xs:element name="updateCourse" type="tns:updateCourse"/>
+ <xs:element name="updateCourseResponse" type="tns:updateCourseResponse"/>
+ <xs:element name="updateInstitute" type="tns:updateInstitute"/>
+ <xs:element name="updateInstituteResponse" type="tns:updateInstituteResponse"/>
+ <xs:element name="updateUser" type="tns:updateUser"/>
+ <xs:element name="updateUserResponse" type="tns:updateUserResponse"/>
+ <xs:complexType name="createInstitute">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="institute" type="ns1:Institute"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="createInstituteResponse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="instituteId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="updateInstitute">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="insitute" type="ns1:Institute"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="updateInstituteResponse">
+ <xs:sequence>
+ <xs:element name="success" type="xs:boolean"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="removeCourseMember">
+ <xs:sequence>
+ <xs:element name="courseId" type="xs:long"/>
+ <xs:element name="userId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="removeCourseMemberResponse">
+ <xs:sequence>
+ <xs:element name="success" type="xs:boolean"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="isCourseMember">
+ <xs:sequence>
+ <xs:element name="courseId" type="xs:long"/>
+ <xs:element name="userId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="isCourseMemberResponse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="roleType" type="ns1:Role"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="findUser">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="username" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="findUserResponse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="userId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="deleteCourse">
+ <xs:sequence>
+ <xs:element name="courseId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="deleteCourseResponse">
+ <xs:sequence>
+ <xs:element name="boolean" type="xs:boolean"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="getCourse">
+ <xs:sequence>
+ <xs:element name="courseId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="getCourseResponse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="courseId" type="ns1:Course"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="updateUser">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="user" type="ns1:User"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="updateUserResponse">
+ <xs:sequence>
+ <xs:element name="success" type="xs:boolean"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="createUser">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="user" type="ns1:User"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="createUserResponse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="userId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="updateCourse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="course" type="ns1:Course"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="updateCourseResponse">
+ <xs:sequence>
+ <xs:element name="succcess" type="xs:boolean"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="listInstitute">
+ <xs:sequence>
+ <xs:element name="departmentId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="listInstituteResponse">
+ <xs:sequence>
+ <xs:element maxOccurs="unbounded" minOccurs="0" name="instituteList" type="ns1:Institute"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="createCourse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="course" type="ns1:Course"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="createCourseResponse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="courseId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="getInstitute">
+ <xs:sequence>
+ <xs:element name="instituteId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="getInstituteResponse">
+ <xs:sequence>
+ <xs:element minOccurs="0" name="institute" type="ns1:Institute"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="deleteUser">
+ <xs:sequence>
+ <xs:element name="userId" type="xs:long"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="deleteUserResponse">
+ <xs:sequence>
+ <xs:element name="success" type="xs:boolean"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="assignCourseMember">
+ <xs:sequence>
+ <xs:element name="courseId" type="xs:long"/>
+ <xs:element name="userId" type="xs:long"/>
+ <xs:element minOccurs="0" name="role" type="ns1:Role"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:complexType name="assignCourseMemberResponse">
+ <xs:sequence>
+ <xs:element name="success" type="xs:boolean"/>
+ </xs:sequence>
+ </xs:complexType>
+ <xs:element name="LectureLogicException" type="tns:LectureLogicException"/>
+ <xs:complexType name="LectureLogicException">
+ <xs:sequence/>
+ </xs:complexType>
+</xs:schema>
+ </wsdl:types>
+ <wsdl:message name="deleteCourse">
+ <wsdl:part name="parameters" element="tns:deleteCourse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="getCourseResponse">
+ <wsdl:part name="parameters" element="tns:getCourseResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="updateCourseResponse">
+ <wsdl:part name="parameters" element="tns:updateCourseResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="deleteCourseResponse">
+ <wsdl:part name="parameters" element="tns:deleteCourseResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="assignCourseMember">
+ <wsdl:part name="parameters" element="tns:assignCourseMember">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="createUser">
+ <wsdl:part name="parameters" element="tns:createUser">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="removeCourseMemberResponse">
+ <wsdl:part name="parameters" element="tns:removeCourseMemberResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="updateUserResponse">
+ <wsdl:part name="parameters" element="tns:updateUserResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="assignCourseMemberResponse">
+ <wsdl:part name="parameters" element="tns:assignCourseMemberResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="deleteUser">
+ <wsdl:part name="parameters" element="tns:deleteUser">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="findUserResponse">
+ <wsdl:part name="parameters" element="tns:findUserResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="updateUser">
+ <wsdl:part name="parameters" element="tns:updateUser">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="createInstituteResponse">
+ <wsdl:part name="parameters" element="tns:createInstituteResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="createInstitute">
+ <wsdl:part name="parameters" element="tns:createInstitute">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="updateInstituteResponse">
+ <wsdl:part name="parameters" element="tns:updateInstituteResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="listInstituteResponse">
+ <wsdl:part name="parameters" element="tns:listInstituteResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="isCourseMember">
+ <wsdl:part name="parameters" element="tns:isCourseMember">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="createCourse">
+ <wsdl:part name="parameters" element="tns:createCourse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="getCourse">
+ <wsdl:part name="parameters" element="tns:getCourse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="isCourseMemberResponse">
+ <wsdl:part name="parameters" element="tns:isCourseMemberResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="createUserResponse">
+ <wsdl:part name="parameters" element="tns:createUserResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="getInstituteResponse">
+ <wsdl:part name="parameters" element="tns:getInstituteResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="updateCourse">
+ <wsdl:part name="parameters" element="tns:updateCourse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="listInstitute">
+ <wsdl:part name="parameters" element="tns:listInstitute">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="updateInstitute">
+ <wsdl:part name="parameters" element="tns:updateInstitute">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="deleteUserResponse">
+ <wsdl:part name="parameters" element="tns:deleteUserResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="removeCourseMember">
+ <wsdl:part name="parameters" element="tns:removeCourseMember">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="LectureLogicException">
+ <wsdl:part name="LectureLogicException" element="tns:LectureLogicException">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="getInstitute">
+ <wsdl:part name="parameters" element="tns:getInstitute">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="findUser">
+ <wsdl:part name="parameters" element="tns:findUser">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="createCourseResponse">
+ <wsdl:part name="parameters" element="tns:createCourseResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:portType name="LectureWebService">
+ <wsdl:operation name="createInstitute">
+ <wsdl:input name="createInstitute" message="tns:createInstitute">
+ </wsdl:input>
+ <wsdl:output name="createInstituteResponse" message="tns:createInstituteResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="updateInstitute">
+ <wsdl:input name="updateInstitute" message="tns:updateInstitute">
+ </wsdl:input>
+ <wsdl:output name="updateInstituteResponse" message="tns:updateInstituteResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="removeCourseMember">
+ <wsdl:input name="removeCourseMember" message="tns:removeCourseMember">
+ </wsdl:input>
+ <wsdl:output name="removeCourseMemberResponse" message="tns:removeCourseMemberResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="isCourseMember">
+ <wsdl:input name="isCourseMember" message="tns:isCourseMember">
+ </wsdl:input>
+ <wsdl:output name="isCourseMemberResponse" message="tns:isCourseMemberResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="findUser">
+ <wsdl:input name="findUser" message="tns:findUser">
+ </wsdl:input>
+ <wsdl:output name="findUserResponse" message="tns:findUserResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="deleteCourse">
+ <wsdl:input name="deleteCourse" message="tns:deleteCourse">
+ </wsdl:input>
+ <wsdl:output name="deleteCourseResponse" message="tns:deleteCourseResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="getCourse">
+ <wsdl:input name="getCourse" message="tns:getCourse">
+ </wsdl:input>
+ <wsdl:output name="getCourseResponse" message="tns:getCourseResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="updateUser">
+ <wsdl:input name="updateUser" message="tns:updateUser">
+ </wsdl:input>
+ <wsdl:output name="updateUserResponse" message="tns:updateUserResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="createUser">
+ <wsdl:input name="createUser" message="tns:createUser">
+ </wsdl:input>
+ <wsdl:output name="createUserResponse" message="tns:createUserResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="updateCourse">
+ <wsdl:input name="updateCourse" message="tns:updateCourse">
+ </wsdl:input>
+ <wsdl:output name="updateCourseResponse" message="tns:updateCourseResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="listInstitute">
+ <wsdl:input name="listInstitute" message="tns:listInstitute">
+ </wsdl:input>
+ <wsdl:output name="listInstituteResponse" message="tns:listInstituteResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="createCourse">
+ <wsdl:input name="createCourse" message="tns:createCourse">
+ </wsdl:input>
+ <wsdl:output name="createCourseResponse" message="tns:createCourseResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="getInstitute">
+ <wsdl:input name="getInstitute" message="tns:getInstitute">
+ </wsdl:input>
+ <wsdl:output name="getInstituteResponse" message="tns:getInstituteResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="deleteUser">
+ <wsdl:input name="deleteUser" message="tns:deleteUser">
+ </wsdl:input>
+ <wsdl:output name="deleteUserResponse" message="tns:deleteUserResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="assignCourseMember">
+ <wsdl:input name="assignCourseMember" message="tns:assignCourseMember">
+ </wsdl:input>
+ <wsdl:output name="assignCourseMemberResponse" message="tns:assignCourseMemberResponse">
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException" message="tns:LectureLogicException">
+ </wsdl:fault>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="OpenUSSServiceSoapBinding" type="tns:LectureWebService">
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="createInstitute">
+ <soap:operation soapAction="createInstitute" style="document"/>
+ <wsdl:input name="createInstitute">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="createInstituteResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="updateInstitute">
+ <soap:operation soapAction="updateInstitute" style="document"/>
+ <wsdl:input name="updateInstitute">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="updateInstituteResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="removeCourseMember">
+ <soap:operation soapAction="removeCourseMember" style="document"/>
+ <wsdl:input name="removeCourseMember">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="removeCourseMemberResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="findUser">
+ <soap:operation soapAction="findUser" style="document"/>
+ <wsdl:input name="findUser">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="findUserResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="isCourseMember">
+ <soap:operation soapAction="isCourseMember" style="document"/>
+ <wsdl:input name="isCourseMember">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="isCourseMemberResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="deleteCourse">
+ <soap:operation soapAction="deleteCourse" style="document"/>
+ <wsdl:input name="deleteCourse">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="deleteCourseResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="getCourse">
+ <soap:operation soapAction="getCourse" style="document"/>
+ <wsdl:input name="getCourse">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getCourseResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="updateUser">
+ <soap:operation soapAction="updateUser" style="document"/>
+ <wsdl:input name="updateUser">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="updateUserResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="createUser">
+ <soap:operation soapAction="createUser" style="document"/>
+ <wsdl:input name="createUser">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="createUserResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="updateCourse">
+ <soap:operation soapAction="updateCourse" style="document"/>
+ <wsdl:input name="updateCourse">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="updateCourseResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="listInstitute">
+ <soap:operation soapAction="listInstitute" style="document"/>
+ <wsdl:input name="listInstitute">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="listInstituteResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="createCourse">
+ <soap:operation soapAction="createCourse" style="document"/>
+ <wsdl:input name="createCourse">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="createCourseResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="getInstitute">
+ <soap:operation soapAction="getInstitute" style="document"/>
+ <wsdl:input name="getInstitute">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getInstituteResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="deleteUser">
+ <soap:operation soapAction="deleteUser" style="document"/>
+ <wsdl:input name="deleteUser">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="deleteUserResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ <wsdl:operation name="assignCourseMember">
+ <soap:operation soapAction="assignCourseMember" style="document"/>
+ <wsdl:input name="assignCourseMember">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="assignCourseMemberResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ <wsdl:fault name="LectureLogicException">
+ <soap:fault name="LectureLogicException" use="literal"/>
+ </wsdl:fault>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="OpenUSSService">
+ <wsdl:port name="LectureWebServicePort" binding="tns:OpenUSSServiceSoapBinding">
+ <soap:address location="http://localhost:9090/LectureWebServicePort"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
Property changes on: trunk/cse-ip/oca-openuss/src/test/resources/LectureWebService.wsdl
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/cse-ip/oca-openuss/src/test/resources/log4j.properties
===================================================================
--- trunk/cse-ip/oca-openuss/src/test/resources/log4j.properties (rev 0)
+++ trunk/cse-ip/oca-openuss/src/test/resources/log4j.properties 2009-04-22 14:26:49 UTC (rev 157)
@@ -0,0 +1,15 @@
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.Target=System.out
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n
+
+log4j.rootCategory=debug, stdout
+
+log4j.logger.org.hibernate=info
+
+log4j.logger.oracle.toplink=debug
+
+log4j.logger.org.hibernate.SQL=debug
+log4j.logger.org.hibernate.type=debug
+log4j.logger.org.hibernate.id=debug
+log4j.logger.org.hibernate.cache=debug
\ No newline at end of file
Property changes on: trunk/cse-ip/oca-openuss/src/test/resources/log4j.properties
___________________________________________________________________
Added: svn:mime-type
+ text/plain
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ro...@us...> - 2009-04-22 09:53:16
|
Revision: 156
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=156&view=rev
Author: roekens
Date: 2009-04-22 09:53:14 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
further implementation of DataModelManagerBean
Modified Paths:
--------------
trunk/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java
Modified: trunk/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java
===================================================================
--- trunk/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java 2009-04-22 09:39:33 UTC (rev 155)
+++ trunk/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java 2009-04-22 09:53:14 UTC (rev 156)
@@ -51,6 +51,10 @@
} catch (ServiceComponentException e1) {
//do nothing
}
+ //check if event time is before entity state time
+ if (loadedCourse == null || loadedCourse.getDate().after(courseMessage.getEventTime())){
+ return events;
+ }
//handle different inputEvents
if (courseMessage.getInputEvent()==InputEventType.CREATE_UPDATE){
@@ -58,6 +62,7 @@
EventMessage eventMessage = new EventMessage();
Course course = courseMessage.getCourse();
course.setState(State.EXISTS);
+ course.setDate(courseMessage.getEventTime());
eventMessage.setEntity(course);
try {
courseDao.persist(course);
@@ -91,8 +96,13 @@
} else if (courseMessage.getInputEvent()==InputEventType.DELETE){
return deleteCourse(courseMessage);
} else if (courseMessage.getInputEvent()==InputEventType.CREATE_BY_REFERENCE){
- //NOT_EXISTS
- //KNOWN
+ Course knownCourse = courseMessage.getCourse();
+ knownCourse.setState(State.KNOWN);
+ try {
+ courseDao.persist(knownCourse);
+ } catch (ServiceComponentException e) {
+ // TODO handle me
+ }
}
@@ -101,6 +111,7 @@
private void createByReference(Category category) {
try {
+ @SuppressWarnings("unused")
Category loadedCategory = categoryDao.find(category.getId());
} catch (ServiceComponentException e) {
CategoryMessage cm = new CategoryMessage();
@@ -113,6 +124,7 @@
private void createByReference(Course course) {
try {
+ @SuppressWarnings("unused")
Course loadedCourse = courseDao.find(course.getId());
} catch (ServiceComponentException e) {
CourseMessage cm = new CourseMessage();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 09:39:34
|
Revision: 155
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=155&view=rev
Author: idueppe
Date: 2009-04-22 09:39:33 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
fixed project name.
Modified Paths:
--------------
trunk/cse-ip/sc-mapper/pom.xml
Modified: trunk/cse-ip/sc-mapper/pom.xml
===================================================================
--- trunk/cse-ip/sc-mapper/pom.xml 2009-04-22 09:38:57 UTC (rev 154)
+++ trunk/cse-ip/sc-mapper/pom.xml 2009-04-22 09:39:33 UTC (rev 155)
@@ -11,7 +11,7 @@
<groupId>de.campussource.cse</groupId>
<artifactId>sc-mapper</artifactId>
<packaging>ejb</packaging>
- <name>Service Component Id-Mapper</name>
+ <name>Service Component Mapper</name>
<version>1.0-SNAPSHOT</version>
<dependencies>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 09:38:59
|
Revision: 154
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=154&view=rev
Author: idueppe
Date: 2009-04-22 09:38:57 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
add additional ant default target "all" to run a clean, install, eclipse at once.
Modified Paths:
--------------
trunk/cse-ip/build.xml
Modified: trunk/cse-ip/build.xml
===================================================================
--- trunk/cse-ip/build.xml 2009-04-22 08:50:01 UTC (rev 153)
+++ trunk/cse-ip/build.xml 2009-04-22 09:38:57 UTC (rev 154)
@@ -1,4 +1,4 @@
-<project name="cse-ip :: build" default="install" basedir=".">
+<project name="cse-ip :: build" default="all" basedir=".">
<condition property="maven.executable" value="mvn.bat" else="mvn"><os family="windows" /></condition>
<condition property="asadmin.executable" value="asadmin.bat" else="asadmin"><os family="windows"/></condition>
@@ -53,4 +53,7 @@
</exec>
</target>
+ <target name="all" depends="clean, install, eclipse" >
+ </target>
+
</project>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 08:50:10
|
Revision: 153
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=153&view=rev
Author: idueppe
Date: 2009-04-22 08:50:01 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
Moved cse-ip project from sandbox to trunk. This is now the current development.
Added Paths:
-----------
trunk/cse-ip/
Removed Paths:
-------------
trunk/sandbox/cse-ip/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ro...@us...> - 2009-04-22 08:32:41
|
Revision: 152
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=152&view=rev
Author: roekens
Date: 2009-04-22 08:32:38 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
stubs for needed messages added
new operations for cdmm added
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManager.java
trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java
Added Paths:
-----------
trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/AccountMessage.java
trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/GroupMessage.java
trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/RoleMessage.java
Added: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/AccountMessage.java
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/AccountMessage.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/AccountMessage.java 2009-04-22 08:32:38 UTC (rev 152)
@@ -0,0 +1,5 @@
+package de.campussource.cse.cdmm;
+
+public class AccountMessage {
+
+}
Property changes on: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/AccountMessage.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManager.java
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManager.java 2009-04-22 08:31:26 UTC (rev 151)
+++ trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManager.java 2009-04-22 08:32:38 UTC (rev 152)
@@ -15,4 +15,16 @@
public List<EventMessage> createOrUpdateCategory(CategoryMessage categoryMessage);
public List<EventMessage> deleteCategory(CategoryMessage categoryMessage);
+
+ public List<EventMessage> createOrUpdateRole(RoleMessage roleMessage);
+
+ public List<EventMessage> deleteRole(RoleMessage roleMessage);
+
+ public List<EventMessage> createOrUpdateAccount(AccountMessage accountMessage);
+
+ public List<EventMessage> deleteAccount(AccountMessage accountMessage);
+
+ public List<EventMessage> createOrUpdateGroup(GroupMessage groupMessage);
+
+ public List<EventMessage> deleteGroup(GroupMessage groupMessage);
}
Modified: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java 2009-04-22 08:31:26 UTC (rev 151)
+++ trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java 2009-04-22 08:32:38 UTC (rev 152)
@@ -139,4 +139,41 @@
return null;
}
+ @Override
+ public List<EventMessage> createOrUpdateAccount(
+ AccountMessage accountMessage) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public List<EventMessage> createOrUpdateGroup(GroupMessage groupMessage) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public List<EventMessage> createOrUpdateRole(RoleMessage roleMessage) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public List<EventMessage> deleteAccount(AccountMessage accountMessage) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public List<EventMessage> deleteGroup(GroupMessage groupMessage) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ @Override
+ public List<EventMessage> deleteRole(RoleMessage roleMessage) {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
}
Added: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/GroupMessage.java
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/GroupMessage.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/GroupMessage.java 2009-04-22 08:32:38 UTC (rev 152)
@@ -0,0 +1,5 @@
+package de.campussource.cse.cdmm;
+
+public class GroupMessage {
+
+}
Property changes on: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/GroupMessage.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/RoleMessage.java
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/RoleMessage.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/RoleMessage.java 2009-04-22 08:32:38 UTC (rev 152)
@@ -0,0 +1,5 @@
+package de.campussource.cse.cdmm;
+
+public class RoleMessage {
+
+}
Property changes on: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/RoleMessage.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 08:31:27
|
Revision: 151
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=151&view=rev
Author: idueppe
Date: 2009-04-22 08:31:26 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
fixed project structure
Added Paths:
-----------
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/webapp/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/webapp/WEB-INF/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/webapp/WEB-INF/web.xml
Added: trunk/sandbox/cse-ip/sc-mapper-rest/src/main/webapp/WEB-INF/web.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/main/webapp/WEB-INF/web.xml (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/main/webapp/WEB-INF/web.xml 2009-04-22 08:31:26 UTC (rev 151)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
+ version="2.5">
+
+</web-app>
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/src/main/webapp/WEB-INF/web.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 08:25:43
|
Revision: 150
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=150&view=rev
Author: idueppe
Date: 2009-04-22 08:25:37 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
removed version of jersey dependency which is now managed by the parent pom.xml
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml
Modified: trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml 2009-04-22 08:24:50 UTC (rev 149)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml 2009-04-22 08:25:37 UTC (rev 150)
@@ -31,7 +31,7 @@
<dependency>
<groupId>com.sun.jersey</groupId>
<artifactId>jersey-server</artifactId>
- <version>1.0.1</version>
+ <version>1.0.3</version>
</dependency>
<dependency>
<groupId>log4j</groupId>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 08:24:53
|
Revision: 149
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=149&view=rev
Author: idueppe
Date: 2009-04-22 08:24:50 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
removed test file
Removed Paths:
-------------
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java
Deleted: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java 2009-04-22 08:23:19 UTC (rev 148)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java 2009-04-22 08:24:50 UTC (rev 149)
@@ -1,96 +0,0 @@
-package de.campussource.cse.mapper.rest;
-
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.net.HttpURLConnection;
-import java.net.URL;
-
-import javax.swing.JOptionPane;
-import javax.ws.rs.GET;
-import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
-
-import org.junit.AfterClass;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-import com.sun.jersey.api.container.httpserver.HttpServerFactory;
-import com.sun.net.httpserver.HttpServer;
-
-@Path("/unittest")
-public class RestfulTest {
-
- private static final String LOCALHOST = "http://localhost:8888/";
-
- private static HttpServer server;
-
- @GET
- @Produces("text/plain")
- public String testSystem() {
- return "Hello. This is a test";
- }
-
- @BeforeClass
- public static void setUp() throws Exception {
- System.out.println("Creating Server...");
-
- server = HttpServerFactory.create(LOCALHOST);
- server.start();
-
- JOptionPane.showMessageDialog(null, "JAX-RS Server is running!");
-
- System.out.println("HTTP Server started.");
- System.out.println("Running tests...");
-
- }
-
- private static String testResourceAtUrl(URL url) throws Exception {
- try {
- HttpURLConnection connection = (HttpURLConnection) url.openConnection();
-
- connection.setRequestMethod("GET");
- connection.connect();
-
- InputStream is = connection.getInputStream();
-
- BufferedReader reader = new BufferedReader(new InputStreamReader(is));
- StringBuilder buffer = new StringBuilder();
- String line = null;
- while ((line = reader.readLine()) != null) {
- buffer.append(line);
- }
- System.out.println("Read: " + buffer.toString());
-
- connection.disconnect();
-
- return buffer.toString();
-
- } catch (IOException e) {
- e.printStackTrace();
- }
- throw new Exception("Could not establish connection to " + url.toExternalForm());
- }
-
- @Test
- public void testRest() throws Exception {
- String activationText = testResourceAtUrl(new URL(LOCALHOST + "/mapper"));
- assertNotNull(activationText);
- assertFalse(activationText.isEmpty());
- }
-
- @AfterClass
- public static void tearDown() throws IOException {
- if (server != null) {
- System.out.println("Stopping server...");
- server.stop(0);
- System.out.println("Server stopped");
- }
-
- }
-
-}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-22 08:23:21
|
Revision: 148
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=148&view=rev
Author: idueppe
Date: 2009-04-22 08:23:19 +0000 (Wed, 22 Apr 2009)
Log Message:
-----------
add jersey (jax-rs RI) dependency
Modified Paths:
--------------
trunk/sandbox/cse-ip/pom.xml
Modified: trunk/sandbox/cse-ip/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/pom.xml 2009-04-21 21:26:18 UTC (rev 147)
+++ trunk/sandbox/cse-ip/pom.xml 2009-04-22 08:23:19 UTC (rev 148)
@@ -79,7 +79,7 @@
<url>http://www.gnu.org/copyleft/gpl.html</url>
</license>
</licenses>
-
+
<issueManagement>
<url>https://apps.sourceforge.net/trac/cse-ip/</url>
<system>Trac</system>
@@ -87,17 +87,17 @@
<scm>
<connection>scm:svn:https://cse-ip.svn.sourceforge.net/svnroot/cse-ip/trunk</connection>
- <developerConnection>scm:svn:https://cse-ip.svn.sourceforge.net/svnroot/cse-ip/trunk</developerConnection>
+ <developerConnection>scm:svn:https://cse-ip.svn.sourceforge.net/svnroot/cse-ip/trunk</developerConnection>
<url>https://cse-ip.svn.sourceforge.net/svnroot/cse-ip/trunk/cse-ip</url>
</scm>
-
- <distributionManagement>
- <site>
- <id>cse-ip.sourceforge.net</id>
- <url>scp://shell.sourceforge.net/home/groups/c/cs/cse-ip/htdocs</url>
- </site>
- </distributionManagement>
+ <distributionManagement>
+ <site>
+ <id>cse-ip.sourceforge.net</id>
+ <url>scp://shell.sourceforge.net/home/groups/c/cs/cse-ip/htdocs</url>
+ </site>
+ </distributionManagement>
+
<organization>
<name>CampusSource</name>
<url>http://cse.campussource.de</url>
@@ -115,7 +115,7 @@
<repositories>
- <repository>
+ <repository>
<id>jboss</id>
<name>JBoss</name>
<url>http://repository.jboss.com/maven2</url>
@@ -127,7 +127,7 @@
<url>http://download.java.net/maven/2</url>
<layout>default</layout>
</repository>
- <repository>
+ <repository>
<id>java-net</id>
<name>Java.Net</name>
<layout>legacy</layout>
@@ -307,6 +307,11 @@
<version>1.2.14</version>
</dependency>
<dependency>
+ <groupId>com.sun.jersey</groupId>
+ <artifactId>jersey-server</artifactId>
+ <version>1.0.3</version>
+ </dependency>
+ <dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<version>${commons-lang.version}</version>
@@ -342,8 +347,8 @@
<groupId>com.sun.xml.ws</groupId>
<artifactId>jaxws-rt</artifactId>
<version>${jaxws-rt.version}</version>
- <scope>compile</scope>
- </dependency>
+ <scope>compile</scope>
+ </dependency>
</dependencies>
</dependencyManagement>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 21:26:27
|
Revision: 147
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=147&view=rev
Author: idueppe
Date: 2009-04-21 21:26:18 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
ignore createDDL.jdbc and dropDDL.jdbc
Property Changed:
----------------
trunk/sandbox/cse-ip/sc-mapper-rest/
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest
___________________________________________________________________
Added: svn:ignore
+ createDDL.jdbc
dropDDL.jdbc
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 21:22:36
|
Revision: 146
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=146&view=rev
Author: idueppe
Date: 2009-04-21 21:22:23 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
in progress: added rest client to sc-mapper
Modified Paths:
--------------
trunk/sandbox/cse-ip/build.xml
trunk/sandbox/cse-ip/pom.xml
trunk/sandbox/cse-ip/sc-mapper/pom.xml
Added Paths:
-----------
trunk/sandbox/cse-ip/sc-mapper-rest/
trunk/sandbox/cse-ip/sc-mapper-rest/build.xml
trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml
trunk/sandbox/cse-ip/sc-mapper-rest/src/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java
trunk/sandbox/cse-ip/sc-mapper-rest/src/main/resources/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/META-INF/
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/META-INF/persistence.xml
trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/log4j.properties
Modified: trunk/sandbox/cse-ip/build.xml
===================================================================
--- trunk/sandbox/cse-ip/build.xml 2009-04-21 19:27:23 UTC (rev 145)
+++ trunk/sandbox/cse-ip/build.xml 2009-04-21 21:22:23 UTC (rev 146)
@@ -1,4 +1,4 @@
-<project name="cse-ip" default="install" basedir=".">
+<project name="cse-ip :: build" default="install" basedir=".">
<condition property="maven.executable" value="mvn.bat" else="mvn"><os family="windows" /></condition>
<condition property="asadmin.executable" value="asadmin.bat" else="asadmin"><os family="windows"/></condition>
Modified: trunk/sandbox/cse-ip/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/pom.xml 2009-04-21 19:27:23 UTC (rev 145)
+++ trunk/sandbox/cse-ip/pom.xml 2009-04-21 21:22:23 UTC (rev 146)
@@ -109,11 +109,18 @@
<module>sc-common</module>
<module>sc-mapper</module>
<module>sc-cdmm</module>
+ <module>sc-mapper-rest</module>
<module>cse-ip-application</module>
</modules>
<repositories>
+ <repository>
+ <id>jboss</id>
+ <name>JBoss</name>
+ <url>http://repository.jboss.com/maven2</url>
+ <layout>default</layout>
+ </repository>
<repository>
<id>download-java-net</id>
<name>Repository Java.Net</name>
Modified: trunk/sandbox/cse-ip/sc-mapper/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/pom.xml 2009-04-21 19:27:23 UTC (rev 145)
+++ trunk/sandbox/cse-ip/sc-mapper/pom.xml 2009-04-21 21:22:23 UTC (rev 146)
@@ -22,16 +22,16 @@
<scope>test</scope>
</dependency>
<dependency>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>sc-common</artifactId>
+ <version>${pom.version}</version>
+ </dependency>
+ <dependency>
<groupId>com.sun.xml.ws</groupId>
<artifactId>jaxws-rt</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
- <groupId>de.campussource.cse</groupId>
- <artifactId>sc-common</artifactId>
- <version>${pom.version}</version>
- </dependency>
- <dependency>
<groupId>javax.ejb</groupId>
<artifactId>ejb-api</artifactId>
<version>3.0</version>
Added: trunk/sandbox/cse-ip/sc-mapper-rest/build.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/build.xml (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/build.xml 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,28 @@
+<project name="cse-ip :: sc :: mapper :: rest :: build" default="install" basedir=".">
+ <condition property="maven.executable" value="mvn.bat" else="mvn"><os family="windows" /></condition>
+
+ <target name="compile">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="clean">
+ <exec executable="${maven.executable}">
+ <arg line="clean"/>
+ </exec>
+ </target>
+
+ <target name="install" depends="clean">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="eclipse">
+ <exec executable="${maven.executable}">
+ <arg line="eclipse:clean eclipse:eclipse"/>
+ </exec>
+ </target>
+
+</project>
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/build.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <artifactId>cse-ip</artifactId>
+ <groupId>de.campussource.cse</groupId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
+
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>sc-mapper-rest</artifactId>
+ <packaging>war</packaging>
+ <name>Service Component Mapper REST</name>
+ <version>1.0-SNAPSHOT</version>
+
+
+
+ <dependencies>
+ <dependency>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>sc-mapper</artifactId>
+ <version>${pom.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>de.campussource.cse</groupId>
+ <artifactId>test-utilities</artifactId>
+ <version>${pom.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.jersey</groupId>
+ <artifactId>jersey-server</artifactId>
+ <version>1.0.1</version>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+</project>
\ No newline at end of file
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/pom.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,69 @@
+package de.campussource.cse.mapper.rest;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+import javax.ws.rs.Produces;
+
+import de.campussource.cse.common.exception.IdNotFoundException;
+
+@Path("/mapper")
+public class IdentityMapperRestBean {
+
+ private Map<Long, String> busToClient = new HashMap<Long, String>();
+ private Map<String, Long> clientToBus = new HashMap<String, Long>();
+
+ private Long toBus(String client) {
+ Long bus = clientToBus.get(client);
+ if (bus == null) {
+ bus = System.currentTimeMillis();
+ busToClient.put(bus, client);
+ clientToBus.put(client, bus);
+ }
+
+ return bus;
+ }
+
+ private String toClient(Long bus) {
+ return busToClient.get(bus);
+ }
+
+ @GET
+ @Path("/client/{instanceid}/{objectid}")
+ @Produces("application/xml")
+ public MappedObject toBusId(@PathParam("instanceid") Long clientInstanceId,
+ @PathParam("objectid") String clientObjectId) {
+
+ MappedObject mapped = new MappedObject();
+ mapped.setBusId(toBus(clientObjectId));
+// mapped.setBusId(mapper.toBusId(clientInstanceId, clientObjectId));
+ mapped.setClientInstanceId(clientInstanceId);
+ mapped.setClientObjectId(clientObjectId);
+
+ return mapped;
+ }
+
+ @GET
+ @Path("/bus/{busid}/{instanceid}")
+ @Produces("application/xml")
+ public MappedObject toClientObjectId(
+ @PathParam("busid") Long busId,
+ @PathParam("instanceid") Long clientInstanceId) throws IdNotFoundException {
+ MappedObject mapped = new MappedObject();
+ mapped.setBusId(busId);
+ mapped.setClientInstanceId(clientInstanceId);
+ mapped.setClientObjectId(toClient(busId));
+// mapped.setClientObjectId(mapper.toClientObjectId(busId, clientInstanceId));
+
+ return mapped;
+ }
+
+
+// public static void setMapper(IdentityMapper identityMapper) {
+// mapper = identityMapper;
+// }
+
+}
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/IdentityMapperRestBean.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,48 @@
+package de.campussource.cse.mapper.rest;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+@XmlRootElement(name="Mapped")
+@XmlType(name="MappedObjectType", namespace="http://cse.campussource.de/mapper")
+@XmlAccessorType(XmlAccessType.FIELD)
+public class MappedObject {
+
+ @XmlElement(name="BusId")
+ private Long busId;
+
+ @XmlElement(name="ClientInstanceId")
+ private Long clientInstanceId;
+
+ @XmlElement(name="ClientObjectId")
+ private String clientObjectId;
+
+ public Long getBusId() {
+ return busId;
+ }
+
+ public void setBusId(Long busId) {
+ this.busId = busId;
+ }
+
+ public Long getClientInstanceId() {
+ return clientInstanceId;
+ }
+
+ public void setClientInstanceId(Long clientInstanceId) {
+ this.clientInstanceId = clientInstanceId;
+ }
+
+ public String getClientObjectId() {
+ return clientObjectId;
+ }
+
+ public void setClientObjectId(String clientObjectId) {
+ this.clientObjectId = clientObjectId;
+ }
+
+}
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/src/main/java/de/campussource/cse/mapper/rest/MappedObject.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,91 @@
+package de.campussource.cse.mapper.rest;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+
+import java.io.BufferedReader;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.net.HttpURLConnection;
+import java.net.URL;
+
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import com.sun.jersey.api.container.httpserver.HttpServerFactory;
+import com.sun.net.httpserver.HttpServer;
+
+public class RestIdentityMapperIntegrationTest{
+
+ private static final String LOCALHOST = "http://localhost:8888/";
+ private static HttpServer server;
+
+ @BeforeClass
+ public static void setUp() throws Exception {
+ System.out.println("Creating Server...");
+
+
+ server = HttpServerFactory.create(LOCALHOST);
+ server.start();
+
+
+ System.out.println("HTTP Server started.");
+ System.out.println("Running tests...");
+
+ }
+
+// @Before
+// public void setup() {
+// IdentityMapper mapper = new IdentityMapperBean();
+// autowireByType(mapper);
+// IdentityMapperRestBean.setMapper(mapper);
+// JOptionPane.showMessageDialog(null, "JAX-RS Server is running!");
+// }
+
+ private static String testResourceAtUrl(URL url) throws Exception {
+ try {
+ HttpURLConnection connection = (HttpURLConnection) url.openConnection();
+
+ connection.setRequestMethod("GET");
+ connection.connect();
+
+ InputStream is = connection.getInputStream();
+
+ BufferedReader reader = new BufferedReader(new InputStreamReader(is));
+ StringBuilder buffer = new StringBuilder();
+ String line = null;
+ while ((line = reader.readLine()) != null) {
+ buffer.append(line);
+ }
+ System.out.println("Read: " + buffer.toString());
+
+ connection.disconnect();
+
+ return buffer.toString();
+
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ throw new Exception("Could not establish connection to " + url.toExternalForm());
+ }
+
+ @Test
+ public void testRest() throws Exception {
+ String activationText = testResourceAtUrl(new URL(LOCALHOST + "mapper/client/12345/objectid"));
+ assertNotNull(activationText);
+ assertFalse(activationText.isEmpty());
+ }
+
+ @AfterClass
+ public static void tearDown() throws IOException {
+ if (server != null) {
+ System.out.println("Stopping server...");
+ server.stop(0);
+ System.out.println("Server stopped");
+ }
+
+ }
+
+}
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestIdentityMapperIntegrationTest.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,96 @@
+package de.campussource.cse.mapper.rest;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+
+import java.io.BufferedReader;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.net.HttpURLConnection;
+import java.net.URL;
+
+import javax.swing.JOptionPane;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.Produces;
+
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import com.sun.jersey.api.container.httpserver.HttpServerFactory;
+import com.sun.net.httpserver.HttpServer;
+
+@Path("/unittest")
+public class RestfulTest {
+
+ private static final String LOCALHOST = "http://localhost:8888/";
+
+ private static HttpServer server;
+
+ @GET
+ @Produces("text/plain")
+ public String testSystem() {
+ return "Hello. This is a test";
+ }
+
+ @BeforeClass
+ public static void setUp() throws Exception {
+ System.out.println("Creating Server...");
+
+ server = HttpServerFactory.create(LOCALHOST);
+ server.start();
+
+ JOptionPane.showMessageDialog(null, "JAX-RS Server is running!");
+
+ System.out.println("HTTP Server started.");
+ System.out.println("Running tests...");
+
+ }
+
+ private static String testResourceAtUrl(URL url) throws Exception {
+ try {
+ HttpURLConnection connection = (HttpURLConnection) url.openConnection();
+
+ connection.setRequestMethod("GET");
+ connection.connect();
+
+ InputStream is = connection.getInputStream();
+
+ BufferedReader reader = new BufferedReader(new InputStreamReader(is));
+ StringBuilder buffer = new StringBuilder();
+ String line = null;
+ while ((line = reader.readLine()) != null) {
+ buffer.append(line);
+ }
+ System.out.println("Read: " + buffer.toString());
+
+ connection.disconnect();
+
+ return buffer.toString();
+
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ throw new Exception("Could not establish connection to " + url.toExternalForm());
+ }
+
+ @Test
+ public void testRest() throws Exception {
+ String activationText = testResourceAtUrl(new URL(LOCALHOST + "/mapper"));
+ assertNotNull(activationText);
+ assertFalse(activationText.isEmpty());
+ }
+
+ @AfterClass
+ public static void tearDown() throws IOException {
+ if (server != null) {
+ System.out.println("Stopping server...");
+ server.stop(0);
+ System.out.println("Server stopped");
+ }
+
+ }
+
+}
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/java/de/campussource/cse/mapper/rest/RestfulTest.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/META-INF/persistence.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/META-INF/persistence.xml (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/META-INF/persistence.xml 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,21 @@
+<persistence xmlns="http://java.sun.com/xml/ns/persistence"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
+ version="1.0">
+ <persistence-unit name="cseip-test" transaction-type="RESOURCE_LOCAL">
+ <provider>oracle.toplink.essentials.PersistenceProvider</provider>
+ <class>de.campussource.cse.mapper.MappedClientObject</class>
+ <properties>
+ <property name="toplink.ddl-generation" value="drop-and-create-tables" />
+ <property name="toplink.jdbc.driver" value="com.mysql.jdbc.Driver" />
+ <property name="toplink.jdbc.url" value="jdbc:mysql://localhost:3306/cseiptest?createDatabaseIfNotExist=true" />
+ <property name="toplink.jdbc.user" value="root" />
+ <property name="toplink.jdbc.password" value="masterkey" />
+ </properties>
+ </persistence-unit>
+</persistence>
+
+
+
+
+
\ No newline at end of file
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/META-INF/persistence.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/log4j.properties
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/log4j.properties (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/log4j.properties 2009-04-21 21:22:23 UTC (rev 146)
@@ -0,0 +1,15 @@
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.Target=System.out
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n
+
+log4j.rootCategory=debug, stdout
+
+log4j.logger.org.hibernate=info
+
+log4j.logger.oracle.toplink=debug
+
+log4j.logger.org.hibernate.SQL=debug
+log4j.logger.org.hibernate.type=debug
+log4j.logger.org.hibernate.id=debug
+log4j.logger.org.hibernate.cache=debug
\ No newline at end of file
Property changes on: trunk/sandbox/cse-ip/sc-mapper-rest/src/test/resources/log4j.properties
___________________________________________________________________
Added: svn:mime-type
+ text/plain
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 19:28:16
|
Revision: 145
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=145&view=rev
Author: idueppe
Date: 2009-04-21 19:27:23 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
fixed module order. The modules cdmm and mapper dependent on common.
Modified Paths:
--------------
trunk/sandbox/cse-ip/pom.xml
Modified: trunk/sandbox/cse-ip/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/pom.xml 2009-04-21 18:51:24 UTC (rev 144)
+++ trunk/sandbox/cse-ip/pom.xml 2009-04-21 19:27:23 UTC (rev 145)
@@ -106,9 +106,9 @@
<modules>
<module>framework</module>
<module>ica-his-lsf</module>
+ <module>sc-common</module>
<module>sc-mapper</module>
<module>sc-cdmm</module>
- <module>sc-common</module>
<module>cse-ip-application</module>
</modules>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 18:51:39
|
Revision: 144
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=144&view=rev
Author: idueppe
Date: 2009-04-21 18:51:24 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
additional annotations
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-common/src/main/java/de/campussource/cse/common/exception/IdNotFoundException.java
trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java
trunk/sandbox/cse-ip/sc-mapper/src/test/java/de/campussource/cse/mapper/webservice/IdentityMapperWebServiceTest.java
Added Paths:
-----------
trunk/sandbox/cse-ip/sc-common/build.xml
trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/package-info.java
Added: trunk/sandbox/cse-ip/sc-common/build.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-common/build.xml (rev 0)
+++ trunk/sandbox/cse-ip/sc-common/build.xml 2009-04-21 18:51:24 UTC (rev 144)
@@ -0,0 +1,28 @@
+<project name="cse-ip :: sc :: common :: build" default="install" basedir=".">
+ <condition property="maven.executable" value="mvn.bat" else="mvn"><os family="windows" /></condition>
+
+ <target name="compile">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="clean">
+ <exec executable="${maven.executable}">
+ <arg line="clean"/>
+ </exec>
+ </target>
+
+ <target name="install" depends="clean">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="eclipse">
+ <exec executable="${maven.executable}">
+ <arg line="eclipse:clean eclipse:eclipse"/>
+ </exec>
+ </target>
+
+</project>
Property changes on: trunk/sandbox/cse-ip/sc-common/build.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/sandbox/cse-ip/sc-common/src/main/java/de/campussource/cse/common/exception/IdNotFoundException.java
===================================================================
--- trunk/sandbox/cse-ip/sc-common/src/main/java/de/campussource/cse/common/exception/IdNotFoundException.java 2009-04-21 17:54:48 UTC (rev 143)
+++ trunk/sandbox/cse-ip/sc-common/src/main/java/de/campussource/cse/common/exception/IdNotFoundException.java 2009-04-21 18:51:24 UTC (rev 144)
@@ -1,10 +1,13 @@
package de.campussource.cse.common.exception;
+import javax.xml.ws.WebFault;
+
/**
* Exception to represent failed searches for objects
* e.g. no object with given id existing
* @author Sebastian Roekens
*/
+@WebFault(name="IdNotFound", targetNamespace="http://cse.campussource.de/common")
public class IdNotFoundException extends ServiceComponentException {
private static final long serialVersionUID = 3260263352045745859L;
Modified: trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java 2009-04-21 17:54:48 UTC (rev 143)
+++ trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java 2009-04-21 18:51:24 UTC (rev 144)
@@ -24,7 +24,8 @@
@Stateless
@WebService(
name="IdentityMapper",
- targetNamespace="http://cse.campussource.de/mapper")
+ targetNamespace="http://cse.campussource.de/mapper",
+ endpointInterface="")
public class IdentityMapperBean implements IdentityMapper {
@PersistenceContext
Added: trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/package-info.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/package-info.java (rev 0)
+++ trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/package-info.java 2009-04-21 18:51:24 UTC (rev 144)
@@ -0,0 +1,8 @@
+@XmlSchema(
+ namespace="http://cse.campussource.de/mapper",
+ elementFormDefault=XmlNsForm.UNQUALIFIED,
+ attributeFormDefault=XmlNsForm.QUALIFIED)
+package de.campussource.cse.mapper;
+
+import javax.xml.bind.annotation.XmlNsForm;
+import javax.xml.bind.annotation.XmlSchema;
Property changes on: trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/package-info.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/sandbox/cse-ip/sc-mapper/src/test/java/de/campussource/cse/mapper/webservice/IdentityMapperWebServiceTest.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/src/test/java/de/campussource/cse/mapper/webservice/IdentityMapperWebServiceTest.java 2009-04-21 17:54:48 UTC (rev 143)
+++ trunk/sandbox/cse-ip/sc-mapper/src/test/java/de/campussource/cse/mapper/webservice/IdentityMapperWebServiceTest.java 2009-04-21 18:51:24 UTC (rev 144)
@@ -39,17 +39,20 @@
txBegin();
IdentityMapper mapper = new IdentityMapperBeanService().getIdentityMapperPort();
+ // RETRIEVE BUSID
Long busId = mapper.toBusId(12345L, CLIENT_OBJECTID);
assertNotNull(busId);
txCommit();
txBegin();
+ // RETRIEVE CLIENTID
String clientId = mapper.toClientObjectId(busId, 12345L);
assertNotNull(clientId);
assertEquals(CLIENT_OBJECTID, clientId);
-
}
+
+
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 17:54:57
|
Revision: 143
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=143&view=rev
Author: idueppe
Date: 2009-04-21 17:54:48 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java
Modified: trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java 2009-04-21 17:01:07 UTC (rev 142)
+++ trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java 2009-04-21 17:54:48 UTC (rev 143)
@@ -22,7 +22,9 @@
* @author Ingo Dueppe
*/
@Stateless
-@WebService(name="IdentityMapper", targetNamespace="http://cse.campussource.de/mapper")
+@WebService(
+ name="IdentityMapper",
+ targetNamespace="http://cse.campussource.de/mapper")
public class IdentityMapperBean implements IdentityMapper {
@PersistenceContext
@@ -31,7 +33,10 @@
@Override
@TransactionAttribute(TransactionAttributeType.REQUIRED)
@WebMethod(action="persistClientObjectId")
- public void persistClientObjectId(@WebParam(name="BusId") Long busId, @WebParam(name="ClientInstanceId") Long clientInstanceId, @WebParam(name="ClientObjectId") String clientObjectId) {
+ public void persistClientObjectId(
+ @WebParam(name="BusId") Long busId,
+ @WebParam(name="ClientInstanceId") Long clientInstanceId,
+ @WebParam(name="ClientObjectId") String clientObjectId) {
Validate.notNull(busId, "IdentityMapper.persistClientObjectId: Parameter busId is mandatory.");
Validate.notNull(clientInstanceId, "IdentityMapper.persistClientObjectId: Parameter clientInstanceId is mandatory.");
Validate.notEmpty(clientObjectId, "IdentityMapper.persistClientObjectId: Parameter clientObjectId is mandatory.");
@@ -47,7 +52,10 @@
@Override
@TransactionAttribute(TransactionAttributeType.REQUIRED)
@WebMethod(action="toBusId")
- public @WebResult(name="BusId") Long toBusId(@WebParam(name="ClientInstanceId") Long clientInstanceId, @WebParam(name="ClientObjectId") String clientObjectId) {
+ @WebResult(name="BusId")
+ public Long toBusId(
+ @WebParam(name="ClientInstanceId") Long clientInstanceId,
+ @WebParam(name="ClientObjectId") String clientObjectId) {
Validate.notNull(clientInstanceId, "IdentityMapper.toBusId: Parameter clientInstanceId is mandatory.");
Validate.notNull(clientObjectId, "IdentityMapper.toBusId: Parameter clientObjectId is mandatory.");
try {
@@ -64,7 +72,10 @@
@Override
@TransactionAttribute(TransactionAttributeType.REQUIRED)
@WebMethod(action="toClientObjectId")
- public @WebResult(name="ClientObjectId") String toClientObjectId(@WebParam(name="busId") Long busId, @WebParam(name="clientInstanceId") Long clientInstanceId) throws IdNotFoundException {
+ @WebResult(name="ClientObjectId")
+ public String toClientObjectId(
+ @WebParam(name="busId") Long busId,
+ @WebParam(name="clientInstanceId") Long clientInstanceId) throws IdNotFoundException {
Validate.notNull(busId,"IdentityMapper.toClientObjectId: Parameter busId is mandatory.");
Validate.notNull(clientInstanceId,"IdentityMapper.toClientObjectId: Parameter clientInstanceId is mandatory.");
try {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 17:01:24
|
Revision: 142
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=142&view=rev
Author: idueppe
Date: 2009-04-21 17:01:07 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
fixed source folder settings by using build-helper-maven-plugin
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-cdmm/pom.xml
Modified: trunk/sandbox/cse-ip/sc-cdmm/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/pom.xml 2009-04-21 16:56:46 UTC (rev 141)
+++ trunk/sandbox/cse-ip/sc-cdmm/pom.xml 2009-04-21 17:01:07 UTC (rev 142)
@@ -103,15 +103,28 @@
<include>**/*.xml</include>
</includes>
</testResource>
- <testResource>
- <directory>${project.build.directory}/sources-generated</directory>
- <includes>
- <include>**/*.java</include>
- </includes>
- </testResource>
</testResources>
<plugins>
<plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <version>1.2</version>
+ <executions>
+ <execution>
+ <id>add-test-source</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>add-test-source</goal>
+ </goals>
+ <configuration>
+ <sources>
+ <source>${project.build.directory}/sources-generated</source>
+ </sources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ejb-plugin</artifactId>
<configuration>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 16:56:55
|
Revision: 141
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=141&view=rev
Author: idueppe
Date: 2009-04-21 16:56:46 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
fixed source folder settings by using build-helper-maven-plugin
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-mapper/pom.xml
Modified: trunk/sandbox/cse-ip/sc-mapper/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/pom.xml 2009-04-21 16:55:12 UTC (rev 140)
+++ trunk/sandbox/cse-ip/sc-mapper/pom.xml 2009-04-21 16:56:46 UTC (rev 141)
@@ -101,15 +101,29 @@
<include>**/*.xml</include>
</includes>
</testResource>
- <testResource>
- <directory>${project.build.directory}/sources-generated</directory>
- <includes>
- <include>**/*.java</include>
- </includes>
- </testResource>
</testResources>
<plugins>
<plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <version>1.2</version>
+ <executions>
+ <execution>
+ <id>add-test-source</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>add-test-source</goal>
+ </goals>
+ <configuration>
+ <sources>
+ <source>${project.build.directory}/sources-generated</source>
+ </sources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ejb-plugin</artifactId>
<configuration>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 16:55:57
|
Revision: 140
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=140&view=rev
Author: idueppe
Date: 2009-04-21 16:55:12 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
add additional web service annotation to bean class
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java
Modified: trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java 2009-04-21 16:51:55 UTC (rev 139)
+++ trunk/sandbox/cse-ip/sc-mapper/src/main/java/de/campussource/cse/mapper/IdentityMapperBean.java 2009-04-21 16:55:12 UTC (rev 140)
@@ -3,6 +3,9 @@
import javax.ejb.Stateless;
import javax.ejb.TransactionAttribute;
import javax.ejb.TransactionAttributeType;
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
import javax.jws.WebService;
import javax.persistence.EntityExistsException;
import javax.persistence.EntityManager;
@@ -27,7 +30,8 @@
@Override
@TransactionAttribute(TransactionAttributeType.REQUIRED)
- public void persistClientObjectId(Long busId, Long clientInstanceId, String clientObjectId) {
+ @WebMethod(action="persistClientObjectId")
+ public void persistClientObjectId(@WebParam(name="BusId") Long busId, @WebParam(name="ClientInstanceId") Long clientInstanceId, @WebParam(name="ClientObjectId") String clientObjectId) {
Validate.notNull(busId, "IdentityMapper.persistClientObjectId: Parameter busId is mandatory.");
Validate.notNull(clientInstanceId, "IdentityMapper.persistClientObjectId: Parameter clientInstanceId is mandatory.");
Validate.notEmpty(clientObjectId, "IdentityMapper.persistClientObjectId: Parameter clientObjectId is mandatory.");
@@ -42,7 +46,8 @@
@Override
@TransactionAttribute(TransactionAttributeType.REQUIRED)
- public Long toBusId(Long clientInstanceId, String clientObjectId) {
+ @WebMethod(action="toBusId")
+ public @WebResult(name="BusId") Long toBusId(@WebParam(name="ClientInstanceId") Long clientInstanceId, @WebParam(name="ClientObjectId") String clientObjectId) {
Validate.notNull(clientInstanceId, "IdentityMapper.toBusId: Parameter clientInstanceId is mandatory.");
Validate.notNull(clientObjectId, "IdentityMapper.toBusId: Parameter clientObjectId is mandatory.");
try {
@@ -55,17 +60,11 @@
}
}
- private Long createMapping(Long clientInstanceId, String clientObjectId) {
- MappedClientObject mapped = new MappedClientObject();
- mapped.setClientInstanceId(clientInstanceId);
- mapped.setClientObjectId(clientObjectId);
- manager.persist(mapped);
- return mapped.getBusId();
- }
@Override
@TransactionAttribute(TransactionAttributeType.REQUIRED)
- public String toClientObjectId(Long busId, Long clientInstanceId) throws IdNotFoundException {
+ @WebMethod(action="toClientObjectId")
+ public @WebResult(name="ClientObjectId") String toClientObjectId(@WebParam(name="busId") Long busId, @WebParam(name="clientInstanceId") Long clientInstanceId) throws IdNotFoundException {
Validate.notNull(busId,"IdentityMapper.toClientObjectId: Parameter busId is mandatory.");
Validate.notNull(clientInstanceId,"IdentityMapper.toClientObjectId: Parameter clientInstanceId is mandatory.");
try {
@@ -76,7 +75,13 @@
} catch (NoResultException nre) {
throw new IdNotFoundException(nre);
}
+ }
+ private Long createMapping(Long clientInstanceId, String clientObjectId) {
+ MappedClientObject mapped = new MappedClientObject();
+ mapped.setClientInstanceId(clientInstanceId);
+ mapped.setClientObjectId(clientObjectId);
+ manager.persist(mapped);
+ return mapped.getBusId();
}
-
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <id...@us...> - 2009-04-21 16:52:46
|
Revision: 139
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=139&view=rev
Author: idueppe
Date: 2009-04-21 16:51:55 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
add dependency to clean at install target
Modified Paths:
--------------
trunk/sandbox/cse-ip/sc-mapper/build.xml
Modified: trunk/sandbox/cse-ip/sc-mapper/build.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/build.xml 2009-04-21 14:03:05 UTC (rev 138)
+++ trunk/sandbox/cse-ip/sc-mapper/build.xml 2009-04-21 16:51:55 UTC (rev 139)
@@ -13,7 +13,7 @@
</exec>
</target>
- <target name="install">
+ <target name="install" depends="clean">
<exec executable="${maven.executable}">
<arg line="install"/>
</exec>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ro...@us...> - 2009-04-21 14:22:36
|
Revision: 137
http://cse-ip.svn.sourceforge.net/cse-ip/?rev=137&view=rev
Author: roekens
Date: 2009-04-21 13:41:08 +0000 (Tue, 21 Apr 2009)
Log Message:
-----------
- added build.xml for cdmm
- first integration of webservice as in sc-mapper
Modified Paths:
--------------
trunk/sandbox/cse-ip/pom.xml
trunk/sandbox/cse-ip/sc-cdmm/pom.xml
trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java
trunk/sandbox/cse-ip/sc-mapper/pom.xml
Added Paths:
-----------
trunk/sandbox/cse-ip/sc-cdmm/build.xml
Modified: trunk/sandbox/cse-ip/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/pom.xml 2009-04-21 13:25:38 UTC (rev 136)
+++ trunk/sandbox/cse-ip/pom.xml 2009-04-21 13:41:08 UTC (rev 137)
@@ -331,10 +331,17 @@
<version>2.1-60f</version>
<scope>test</scope>
</dependency>
+ <dependency>
+ <groupId>com.sun.xml.ws</groupId>
+ <artifactId>jaxws-rt</artifactId>
+ <version>${jaxws-rt.version}</version>
+ <scope>compile</scope>
+ </dependency>
</dependencies>
</dependencyManagement>
<properties>
+ <jaxws-rt.version>2.1.5</jaxws-rt.version>
<servicemix.version>3.3</servicemix.version>
<servicemix-tooling.version>3.2.3</servicemix-tooling.version>
<camel.version>1.6.0</camel.version>
Added: trunk/sandbox/cse-ip/sc-cdmm/build.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/build.xml (rev 0)
+++ trunk/sandbox/cse-ip/sc-cdmm/build.xml 2009-04-21 13:41:08 UTC (rev 137)
@@ -0,0 +1,41 @@
+<project name="cse-ip :: sc :: cdmm :: build" default="install" basedir=".">
+ <condition property="maven.executable" value="mvn.bat" else="mvn"><os family="windows" /></condition>
+
+ <target name="compile">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="clean">
+ <exec executable="${maven.executable}">
+ <arg line="clean"/>
+ </exec>
+ </target>
+
+ <target name="install">
+ <exec executable="${maven.executable}">
+ <arg line="install"/>
+ </exec>
+ </target>
+
+ <target name="eclipse">
+ <exec executable="${maven.executable}">
+ <arg line="eclipse:clean eclipse:eclipse"/>
+ </exec>
+ </target>
+
+ <target name="wsgen">
+ <exec executable="${maven.executable}">
+ <arg line="jaxws:wsgen"/>
+ </exec>
+ </target>
+
+ <target name="wsimport">
+ <exec executable="${maven.executable}">
+ <arg line="jaxws:wsimport"/>
+ </exec>
+ </target>
+
+
+</project>
Property changes on: trunk/sandbox/cse-ip/sc-cdmm/build.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/sandbox/cse-ip/sc-cdmm/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/pom.xml 2009-04-21 13:25:38 UTC (rev 136)
+++ trunk/sandbox/cse-ip/sc-cdmm/pom.xml 2009-04-21 13:41:08 UTC (rev 137)
@@ -22,6 +22,11 @@
<scope>test</scope>
</dependency>
<dependency>
+ <groupId>com.sun.xml.ws</groupId>
+ <artifactId>jaxws-rt</artifactId>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
<groupId>de.campussource.cse</groupId>
<artifactId>sc-common</artifactId>
<version>${pom.version}</version>
@@ -30,7 +35,7 @@
<groupId>javax.ejb</groupId>
<artifactId>ejb-api</artifactId>
<version>3.0</version>
- <scope>provided</scope>
+
</dependency>
<dependency>
<groupId>javax.persistence</groupId>
@@ -83,6 +88,22 @@
</dependencies>
<build>
+ <resources>
+ <resource>
+ <directory>${project.build.directory}/resources-generated</directory>
+ <includes>
+ <include>**/*.xsd</include>
+ <include>**/*.wsdl</include>
+ <include>**/*.xml</include>
+ </includes>
+ </resource>
+ <resource>
+ <directory>${project.build.directory}/sources-generated</directory>
+ <includes>
+ <include>**/*.java</include>
+ </includes>
+ </resource>
+ </resources>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
@@ -91,6 +112,30 @@
<ejbVersion>3.0</ejbVersion>
</configuration>
</plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>jaxws-maven-plugin</artifactId>
+ <version>1.10</version>
+ <executions>
+ <execution>
+ <phase>generate-test-sources</phase>
+ <goals>
+ <goal>wsgen</goal>
+ <goal>wsimport</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <sei>de.campussource.cse.cdmm.DataModelManagerBean</sei>
+ <packageName>de.campussource.cse.cdmm.generated</packageName>
+ <keep>true</keep>
+ <genWsdl>true</genWsdl>
+ <verbose>true</verbose>
+ <resourceDestDir>${project.build.directory}/resources-generated</resourceDestDir>
+ <sourceDestDir>${project.build.directory}/sources-generated</sourceDestDir>
+ <wsdlLocation>${project.build.directory}/resources-generated/IdentityMapperBean.wsdl</wsdlLocation>
+ </configuration>
+ </plugin>
</plugins>
</build>
Modified: trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java
===================================================================
--- trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java 2009-04-21 13:25:38 UTC (rev 136)
+++ trunk/sandbox/cse-ip/sc-cdmm/src/main/java/de/campussource/cse/cdmm/DataModelManagerBean.java 2009-04-21 13:41:08 UTC (rev 137)
@@ -7,6 +7,7 @@
import javax.ejb.EJB;
import javax.ejb.Remote;
import javax.ejb.Stateless;
+import javax.jws.WebService;
import de.campussource.cse.cdmm.dao.*;
import de.campussource.cse.cdmm.domain.Category;
@@ -22,6 +23,7 @@
*/
@Stateless
@Remote(value=DataModelManager.class)
+@WebService(name="DataModelManager", targetNamespace="http://cse.campussource.de/cdmm")
public class DataModelManagerBean implements DataModelManager {
@EJB
Modified: trunk/sandbox/cse-ip/sc-mapper/pom.xml
===================================================================
--- trunk/sandbox/cse-ip/sc-mapper/pom.xml 2009-04-21 13:25:38 UTC (rev 136)
+++ trunk/sandbox/cse-ip/sc-mapper/pom.xml 2009-04-21 13:41:08 UTC (rev 137)
@@ -24,7 +24,6 @@
<dependency>
<groupId>com.sun.xml.ws</groupId>
<artifactId>jaxws-rt</artifactId>
- <version>2.1.5</version>
<scope>compile</scope>
</dependency>
<dependency>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|