Browse files

De-tab codebase to make future merges a bit easier

  • Loading branch information...
1 parent bf675de commit 9144fc04f1497ff5009548113ad3e56a6fbb9205 @gertv gertv committed Nov 9, 2011
Showing with 1,551 additions and 1,554 deletions.
  1. +75 −75 db/pom.xml
  2. +10 −10 db/src/main/resources/hibernate.cfg.xml
  3. +18 −18 db/src/main/resources/org/apache/camel/example/reportincident/model/Incident.hbm.xml
  4. +77 −77 features/pom.xml
  5. +31 −31 features/src/main/resources/reportincident.xml
  6. +99 −99 persistence-hibernate/pom.xml
  7. +3 −3 ...stence-hibernate/src/main/java/org/fusesource/devoxx/reportincident/dao/impl/IncidentDAOImpl.java
  8. +1 −1 persistence-hibernate/src/main/resources/META-INF/spring/persistence-osgi.xml
  9. +11 −11 persistence-hibernate/src/main/resources/META-INF/spring/spring-dao-beans.xml
  10. +53 −53 persistence-hibernate/src/main/resources/META-INF/spring/spring-datasource-beans-test.xml
  11. +85 −85 persistence-hibernate/src/main/resources/META-INF/spring/spring-datasource-beans.xml
  12. +1 −1 persistence-hibernate/src/main/resources/log4j.properties
  13. +85 −85 persistence-jpa/pom.xml
  14. +1 −1 persistence-jpa/src/main/java/org/fusesource/devoxx/reportincident/dao/IncidentDAO.java
  15. +1 −1 persistence-jpa/src/main/java/org/fusesource/devoxx/reportincident/dao/impl/IncidentDAOImpl.java
  16. +24 −24 persistence-jpa/src/main/resources/META-INF/spring/persistence-dao.xml
  17. +1 −1 persistence-jpa/src/main/resources/log4j.properties
  18. +1 −3 pom.xml
  19. +166 −166 routing/pom.xml
  20. +5 −5 routing/src/main/java/org/fusesource/devoxx/reportincident/internal/Feedback.java
  21. +45 −45 routing/src/main/java/org/fusesource/devoxx/reportincident/internal/IncidentSaver.java
  22. +39 −39 routing/src/main/java/org/fusesource/devoxx/reportincident/internal/WebService.java
  23. +9 −9 routing/src/main/resources/META-INF/spring/camel-context.xml
  24. +1 −1 ...ing/src/main/resources/META-INF/spring/org.apache.camel.example.reportincident.routing.properties
  25. +5 −5 routing/src/test/java/org/fusesource/devoxx/reportincident/ReportIncidentWithSpringTest.java
  26. +1 −1 routing/src/test/java/org/fusesource/devoxx/reportincident/ReportIncidentWithoutSpringTest.java
  27. +1 −1 routing/src/test/resources/log4j.properties
  28. +6 −6 .../src/test/resources/org/fusesource/devoxx/reportincident/ReportIncidentWithSpringTest-context.xml
  29. +153 −153 service/pom.xml
  30. +40 −40 service/src/main/java/org/fusesource/devoxx/reportincident/service/impl/IncidentServiceImpl.java
  31. +25 −25 service/src/main/resources/META-INF/spring/spring-service-beans-dao.xml
  32. +1 −1 service/src/main/resources/log4j.properties
  33. +222 −222 web/pom.xml
  34. +39 −39 web/src/main/java/org/fusesource/devoxx/reportincident/HomePage.html
  35. +82 −82 web/src/main/java/org/fusesource/devoxx/reportincident/HomePage.java
  36. +16 −16 web/src/main/java/org/fusesource/devoxx/reportincident/WicketApplication.java
  37. +1 −1 web/src/main/webapp/WEB-INF/applicationContext.xml
  38. +24 −24 web/src/main/webapp/WEB-INF/web.xml
  39. +87 −88 webservice/pom.xml
  40. +5 −5 webservice/src/main/resources/META-INF/wsdl/report_incident.wsdl
  41. +1 −1 webservice/src/main/resources/log4j.properties
View
150 db/pom.xml
@@ -16,62 +16,62 @@
limitations under the License.
-->
<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">
- <modelVersion>4.0.0</modelVersion>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident-db</artifactId>
- <packaging>jar</packaging>
- <name>Reportincident :: Reportincident :: DB</name>
- <version>1.0-SNAPSHOT</version>
-
- <parent>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident.parent</artifactId>
- <version>1.0-SNAPSHOT</version>
- </parent>
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident-db</artifactId>
+ <packaging>jar</packaging>
+ <name>Reportincident :: Reportincident :: DB</name>
+ <version>1.0-SNAPSHOT</version>
+
+ <parent>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident.parent</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
- <dependencies>
- <dependency>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident.model</artifactId>
- <version>1.0-SNAPSHOT</version>
- </dependency>
- </dependencies>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident.model</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </dependency>
+ </dependencies>
- <build>
- <plugins>
- <!-- to compile with 1.5 -->
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
+ <build>
+ <plugins>
+ <!-- to compile with 1.5 -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
- <!-- Hibernate plugin -->
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>hibernate3-maven-plugin</artifactId>
+ <!-- Hibernate plugin -->
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>hibernate3-maven-plugin</artifactId>
<!--
- <version>2.2</version>
+ <version>2.2</version>
- <configuration>
- <components>
- <component>
- <name>hbm2ddl</name>
- </component>
- </components>
- <componentProperties>
- <drop>true</drop>
- <create>true</create>
- <format>true</format>
- <configurationfile>/src/config/hibernate.cfg.xml</configurationfile>
- <outputfilename>db_reportincident_create_hsqldb.sql</outputfilename>
- </componentProperties>
- </configuration>
- -->
+ <configuration>
+ <components>
+ <component>
+ <name>hbm2ddl</name>
+ </component>
+ </components>
+ <componentProperties>
+ <drop>true</drop>
+ <create>true</create>
+ <format>true</format>
+ <configurationfile>/src/config/hibernate.cfg.xml</configurationfile>
+ <outputfilename>db_reportincident_create_hsqldb.sql</outputfilename>
+ </componentProperties>
+ </configuration>
+ -->
<configuration>
<componentProperties>
<export>false</export>
@@ -81,30 +81,30 @@
</componentProperties>
</configuration>
- <dependencies>
- <dependency>
- <groupId>hsqldb</groupId>
- <artifactId>hsqldb</artifactId>
- <version>1.8.0.10</version>
- </dependency>
- <dependency>
- <groupId>mysql</groupId>
- <artifactId>mysql-connector-java</artifactId>
- <version>5.1.6</version>
- </dependency>
- </dependencies>
+ <dependencies>
+ <dependency>
+ <groupId>hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <version>1.8.0.10</version>
+ </dependency>
+ <dependency>
+ <groupId>mysql</groupId>
+ <artifactId>mysql-connector-java</artifactId>
+ <version>5.1.6</version>
+ </dependency>
+ </dependencies>
- <executions>
- <execution>
- <phase>process-classes</phase>
- <goals>
- <goal>hbm2ddl</goal>
- </goals>
- </execution>
- </executions>
+ <executions>
+ <execution>
+ <phase>process-classes</phase>
+ <goals>
+ <goal>hbm2ddl</goal>
+ </goals>
+ </execution>
+ </executions>
- </plugin>
+ </plugin>
- </plugins>
- </build>
-</project>
+ </plugins>
+ </build>
+</project>
View
20 db/src/main/resources/hibernate.cfg.xml
@@ -41,17 +41,17 @@
<!-- MySQL DB
<hibernate-configuration>
- <session-factory name="reportincident">
- <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
- <property name="hibernate.connection.url">jdbc:mysql:///report</property>
- <property name="hibernate.connection.username">report</property>
- <property name="hibernate.dialect">org.hibernate.dialect.MySQL5Dialect</property>
- <property name="hibernate.connection.password">report</property>
- <property name="hibernate.show_sql">true</property>
+ <session-factory name="reportincident">
+ <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
+ <property name="hibernate.connection.url">jdbc:mysql:///report</property>
+ <property name="hibernate.connection.username">report</property>
+ <property name="hibernate.dialect">org.hibernate.dialect.MySQL5Dialect</property>
+ <property name="hibernate.connection.password">report</property>
+ <property name="hibernate.show_sql">true</property>
<mapping resource="META-INF/org/apache/camel/example/reportincident/model/incident.hbm.xml"/>
-
- </session-factory>
+
+ </session-factory>
</hibernate-configuration>
--->
+-->
View
36 db/src/main/resources/org/apache/camel/example/reportincident/model/Incident.hbm.xml
@@ -18,23 +18,23 @@
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping schema="REPORT">
- <class name="org.fusesource.devoxx.reportincident.model.Incident" table="T_INCIDENT">
- <meta attribute="extends">Abstract</meta>
- <id name="incidentId" column="INCIDENT_ID" type="long">
- <generator class="native" />
- </id>
-
- <property column="INCIDENT_REF" name="incidentRef" length="55" type="string" />
- <property column="INCIDENT_DATE" lazy="false" length="8" name="incidentDate" type="timestamp" />
- <property column="GIVEN_NAME" length="35" name="givenName" type="string" />
- <property column="FAMILY_NAME" length="35" name="familyName" type="string" />
- <property column="SUMMARY" length="35" name="summary" type="string" />
- <property column="DETAILS" length="255" name="details" type="string" />
- <property column="EMAIL" length="60" name="email" type="string" />
- <property column="PHONE" length="35" name="phone" type="string" />
-
+ <class name="org.fusesource.devoxx.reportincident.model.Incident" table="T_INCIDENT">
+ <meta attribute="extends">Abstract</meta>
+ <id name="incidentId" column="INCIDENT_ID" type="long">
+ <generator class="native" />
+ </id>
+
+ <property column="INCIDENT_REF" name="incidentRef" length="55" type="string" />
+ <property column="INCIDENT_DATE" lazy="false" length="8" name="incidentDate" type="timestamp" />
+ <property column="GIVEN_NAME" length="35" name="givenName" type="string" />
+ <property column="FAMILY_NAME" length="35" name="familyName" type="string" />
+ <property column="SUMMARY" length="35" name="summary" type="string" />
+ <property column="DETAILS" length="255" name="details" type="string" />
+ <property column="EMAIL" length="60" name="email" type="string" />
+ <property column="PHONE" length="35" name="phone" type="string" />
+
- <property column="CREATION_DATE" generated="never" lazy="false" name="creationDate" type="timestamp" />
- <property column="CREATION_USER" generated="never" lazy="false" name="creationUser" type="string" />
- </class>
+ <property column="CREATION_DATE" generated="never" lazy="false" name="creationDate" type="timestamp" />
+ <property column="CREATION_USER" generated="never" lazy="false" name="creationUser" type="string" />
+ </class>
</hibernate-mapping>
View
154 features/pom.xml
@@ -1,85 +1,85 @@
<?xml version="1.0" encoding="UTF-8"?>
- <!--
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You under the Apache License, Version
- 2.0 (the "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
+ <!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version
+ 2.0 (the "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
- http://www.apache.org/licenses/LICENSE-2.0 Unless required by
- applicable law or agreed to in writing, software distributed under the
- License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
- CONDITIONS OF ANY KIND, either express or implied. See the License for
- the specific language governing permissions and limitations under the
- License.
- -->
+ http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+ applicable law or agreed to in writing, software distributed under the
+ License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+ CONDITIONS OF ANY KIND, either express or implied. See the License for
+ the specific language governing permissions and limitations under the
+ License.
+ -->
<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">
- <modelVersion>4.0.0</modelVersion>
- <groupId>org.fusesource.devoxx.reportincident</groupId>
- <artifactId>features</artifactId>
- <packaging>jar</packaging>
- <version>1.0-SNAPSHOT</version>
- <name>Reportincident :: Project Features</name>
-
- <parent>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident.parent</artifactId>
- <version>1.0-SNAPSHOT</version>
- </parent>
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.fusesource.devoxx.reportincident</groupId>
+ <artifactId>features</artifactId>
+ <packaging>jar</packaging>
+ <version>1.0-SNAPSHOT</version>
+ <name>Reportincident :: Project Features</name>
+
+ <parent>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident.parent</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
- <build>
- <!-- enable filtering of the features file -->
- <resources>
- <resource>
- <directory>${pom.basedir}/src/main/resources</directory>
- <filtering>true</filtering>
- <includes>
- <include>**/*</include>
- </includes>
- </resource>
- </resources>
+ <build>
+ <!-- enable filtering of the features file -->
+ <resources>
+ <resource>
+ <directory>${pom.basedir}/src/main/resources</directory>
+ <filtering>true</filtering>
+ <includes>
+ <include>**/*</include>
+ </includes>
+ </resource>
+ </resources>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <executions>
- <execution>
- <id>filter</id>
- <phase>generate-resources</phase>
- <goals>
- <goal>resources</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- <!-- attach the generated features file as an artifact, so that it is published to the maven repository -->
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>build-helper-maven-plugin</artifactId>
- <version>${build-helper-maven-plugin.version}</version>
- <executions>
- <execution>
- <id>attach-artifacts</id>
- <phase>package</phase>
- <goals>
- <goal>attach-artifact</goal>
- </goals>
- <configuration>
- <artifacts>
- <artifact>
- <file>target/classes/reportincident.xml</file>
- <type>xml</type>
- <classifier>features</classifier>
- </artifact>
- </artifacts>
- </configuration>
- </execution>
- </executions>
- </plugin>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-resources-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>filter</id>
+ <phase>generate-resources</phase>
+ <goals>
+ <goal>resources</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ <!-- attach the generated features file as an artifact, so that it is published to the maven repository -->
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <version>${build-helper-maven-plugin.version}</version>
+ <executions>
+ <execution>
+ <id>attach-artifacts</id>
+ <phase>package</phase>
+ <goals>
+ <goal>attach-artifact</goal>
+ </goals>
+ <configuration>
+ <artifacts>
+ <artifact>
+ <file>target/classes/reportincident.xml</file>
+ <type>xml</type>
+ <classifier>features</classifier>
+ </artifact>
+ </artifacts>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
- </build>
+ </build>
</project>
View
62 features/src/main/resources/reportincident.xml
@@ -26,19 +26,19 @@
<feature version='${spring-version}'>spring-persistence</feature>
<feature version='${openjpa-version}'>openjpa</feature>
<feature>spring-dm-web</feature>
- <bundle>mvn:org.fusesource.devoxx.reportincident/persistence-jpa/${project.version}</bundle>
- <bundle>mvn:org.fusesource.devoxx.reportincident/service/${project.version}</bundle>
- <bundle>mvn:org.fusesource.devoxx.reportincident/webservice/${project.version}</bundle>
- <bundle>mvn:org.fusesource.devoxx.reportincident/routing/${project.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/persistence-jpa/${project.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/service/${project.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/webservice/${project.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/routing/${project.version}</bundle>
<bundle>mvn:org.fusesource.devoxx.reportincident/web/${project.version}/war</bundle>
- </feature>
+ </feature>
<!--
- <feature name="spring-web">
+ <feature name="spring-web">
<feature version='${spring-osgi-version}'>spring-dm</feature>
- <bundle>mvn:org.springframework/spring-web/${spring-version}</bundle>
+ <bundle>mvn:org.springframework/spring-web/${spring-version}</bundle>
<bundle>mvn:org.springframework.osgi/spring-osgi-web/${spring-osgi-version}</bundle>
- </feature>
+ </feature>
-->
<feature name="spring-persistence" version="${spring-version}">
<bundle>mvn:org.springframework/spring-orm/${spring-version}</bundle>
@@ -55,14 +55,14 @@
<feature name="jdbc-driver-h2" version="${h2-version}">
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-dbcp/1.4_1</bundle>
- <bundle>mvn:com.h2database/h2/${h2-version}</bundle>
+ <bundle>mvn:com.h2database/h2/${h2-version}</bundle>
</feature>
<feature name="wicket" version="${wicket-version}">
- <bundle>mvn:org.apache.wicket/wicket/${wicket-version}</bundle>
- <bundle>mvn:org.apache.wicket/wicket-ioc/${wicket-version}</bundle>
- <bundle>mvn:org.apache.wicket/wicket-spring/${wicket-version}</bundle>
- <bundle>mvn:org.apache.wicket/wicket-extensions/${wicket-version}</bundle>
+ <bundle>mvn:org.apache.wicket/wicket/${wicket-version}</bundle>
+ <bundle>mvn:org.apache.wicket/wicket-ioc/${wicket-version}</bundle>
+ <bundle>mvn:org.apache.wicket/wicket-spring/${wicket-version}</bundle>
+ <bundle>mvn:org.apache.wicket/wicket-extensions/${wicket-version}</bundle>
</feature>
<!--
@@ -77,44 +77,44 @@
<feature version='${aries-version}'>aries</feature>
<feature>hibernate</feature>
<feature>spring-web</feature>
- <bundle>mvn:org.fusesource.devoxx.reportincident/model/${pom.version}</bundle>
- <bundle>mvn:org.fusesource.devoxx.reportincident/persistence/${pom.version}</bundle>
- <bundle>mvn:org.fusesource.devoxx.reportincident/service/${pom.version}</bundle>
- <bundle>mvn:org.fusesource.devoxx.reportincident/webservice/${pom.version}</bundle>
- <bundle>mvn:org.fusesource.devoxx.reportincident/routing/${pom.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/model/${pom.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/persistence/${pom.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/service/${pom.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/webservice/${pom.version}</bundle>
+ <bundle>mvn:org.fusesource.devoxx.reportincident/routing/${pom.version}</bundle>
<bundle>mvn:org.fusesource.devoxx.reportincident/web/${pom.version}/war</bundle>
- </feature>
+ </feature>
<feature name="hibernate">
<bundle>mvn:org.springframework/spring-orm/${spring-version}</bundle>
<bundle>mvn:org.springframework/spring-jdbc/${spring-version}</bundle>
- <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.dom4j/1.6.1_2</bundle>
- <bundle>mvn:org.antlr/com.springsource.antlr/2.7.7</bundle>
- <bundle>mvn:org.jgroups/com.springsource.org.jgroups/2.5.1</bundle>
- <bundle>mvn:org.jboss.javassist/com.springsource.javassist/3.3.0.ga</bundle>
- <bundle>mvn:org.hibernate/com.springsource.org.hibernate/3.3.1.GA</bundle>
+ <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.dom4j/1.6.1_2</bundle>
+ <bundle>mvn:org.antlr/com.springsource.antlr/2.7.7</bundle>
+ <bundle>mvn:org.jgroups/com.springsource.org.jgroups/2.5.1</bundle>
+ <bundle>mvn:org.jboss.javassist/com.springsource.javassist/3.3.0.ga</bundle>
+ <bundle>mvn:org.hibernate/com.springsource.org.hibernate/3.3.1.GA</bundle>
</feature>
<feature name="openjpa" version="${openjpa-version}">
- <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.aspectj/1.6.8_1</bundle>
+ <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.aspectj/1.6.8_1</bundle>
<bundle>mvn:org.apache.openjpa/openjpa/${openjpa-version}</bundle>
<bundle>mvn:org.apache.servicemix.specs/org.apache.servicemix.specs.java-persistence-api-2.0/1.6.0</bundle>
<bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.serp/1.13.1_2</bundle>
</feature>
<feature name="jdbc-driver-mysql">
- <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-dbcp/1.4_1-SNAPSHOT</bundle>
- <bundle>mvn:mysql/mysql-connector-java/5.1.9</bundle>
+ <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-dbcp/1.4_1-SNAPSHOT</bundle>
+ <bundle>mvn:mysql/mysql-connector-java/5.1.9</bundle>
</feature>
<feature name="jdbc-driver-hsqldb" version="${hsqldb-version}">
<bundle>mvn:commons-pool/commons-pool/1.5.5</bundle>
- <bundle>mvn:commons-dbcp/commons-dbcp/1.4</bundle>
- <bundle>wrap:mvn:org.hsqldb/hsqldb/${hsqldb-version}</bundle>
+ <bundle>mvn:commons-dbcp/commons-dbcp/1.4</bundle>
+ <bundle>wrap:mvn:org.hsqldb/hsqldb/${hsqldb-version}</bundle>
</feature>
<feature name="jdbc-driver-derby" version="${derby-version}">
- <bundle>mvn:commons-dbcp/commons-dbcp/1.4</bundle>
+ <bundle>mvn:commons-dbcp/commons-dbcp/1.4</bundle>
<bundle>mvn:org.apache.derby/derby/${derby-version}</bundle>
</feature>
@@ -130,4 +130,4 @@
-->
-</features>
+</features>
View
198 persistence-hibernate/pom.xml
@@ -16,108 +16,108 @@
limitations under the License.
-->
<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">
- <modelVersion>4.0.0</modelVersion>
- <groupId>org.fusesource.devoxx.reportincident</groupId>
- <artifactId>persistence-hibernate</artifactId>
- <packaging>bundle</packaging>
- <name>Reportincident :: Persistence Bundle</name>
- <version>1.0-SNAPSHOT</version>
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.fusesource.devoxx.reportincident</groupId>
+ <artifactId>persistence-hibernate</artifactId>
+ <packaging>bundle</packaging>
+ <name>Reportincident :: Persistence Bundle</name>
+ <version>1.0-SNAPSHOT</version>
- <parent>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident.parent</artifactId>
- <version>1.0-SNAPSHOT</version>
- </parent>
+ <parent>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident.parent</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
- <dependencies>
- <dependency>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident.model</artifactId>
- <version>${project.version}</version>
- </dependency>
- <dependency>
- <groupId>org.hibernate</groupId>
- <artifactId>hibernate-core</artifactId>
- <version>${hibernate-version}</version>
- </dependency>
- <dependency>
- <groupId>asm</groupId>
- <artifactId>asm</artifactId>
- <version>${asm-version}</version>
- </dependency>
- <dependency>
- <groupId>org.springframework</groupId>
- <artifactId>spring</artifactId>
- <version>${spring-version}</version>
- </dependency>
- <dependency>
- <groupId>javax.transaction</groupId>
- <artifactId>jta</artifactId>
- <version>${jta-version}</version>
- </dependency>
- <dependency>
- <groupId>commons-dbcp</groupId>
- <artifactId>commons-dbcp</artifactId>
- <version>${commons-dbcp-version}</version>
- </dependency>
- <dependency>
- <groupId>mysql</groupId>
- <artifactId>mysql-connector-java</artifactId>
- <version>${mysql-version}</version>
- </dependency>
- <dependency>
- <groupId>org.hsqldb</groupId>
- <artifactId>hsqldb</artifactId>
- <version>${hsqldb-version}</version>
- </dependency>
- </dependencies>
-
- <repositories>
- <repository>
- <id>Sun Java Repo</id>
- <url>http://download.java.net/maven/2/</url>
- </repository>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident.model</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.hibernate</groupId>
+ <artifactId>hibernate-core</artifactId>
+ <version>${hibernate-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>asm</groupId>
+ <artifactId>asm</artifactId>
+ <version>${asm-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring</artifactId>
+ <version>${spring-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.transaction</groupId>
+ <artifactId>jta</artifactId>
+ <version>${jta-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-dbcp</groupId>
+ <artifactId>commons-dbcp</artifactId>
+ <version>${commons-dbcp-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>mysql</groupId>
+ <artifactId>mysql-connector-java</artifactId>
+ <version>${mysql-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <version>${hsqldb-version}</version>
+ </dependency>
+ </dependencies>
+
+ <repositories>
+ <repository>
+ <id>Sun Java Repo</id>
+ <url>http://download.java.net/maven/2/</url>
+ </repository>
</repositories>
-
+
- <build>
- <plugins>
- <!-- to compile with 1.5 -->
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
+ <build>
+ <plugins>
+ <!-- to compile with 1.5 -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
- <!-- to generate the MANIFEST-FILE of the bundle -->
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <extensions>true</extensions>
- <version>${felix-version}</version>
- <configuration>
- <manifestLocation>META-INF</manifestLocation>
- <instructions>
- <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
- <Import-Package>
- META-INF.org.fusesource.devoxx.reportincident.model,
- org.hsqldb.jdbc,
- org.fusesource.devoxx.reportincident.model,
- org.apache.commons.dbcp,
- *
- </Import-Package>
- <Private-Package>org.fusesource.devoxx.reportincident.dao.impl</Private-Package>
- <Export-Package>org.fusesource.devoxx.reportincident.dao</Export-Package>
- <DynamicImport-Package>*</DynamicImport-Package>
- </instructions>
- </configuration>
- </plugin>
- </plugins>
- </build>
-
-</project>
+ <!-- to generate the MANIFEST-FILE of the bundle -->
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <extensions>true</extensions>
+ <version>${felix-version}</version>
+ <configuration>
+ <manifestLocation>META-INF</manifestLocation>
+ <instructions>
+ <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
+ <Import-Package>
+ META-INF.org.fusesource.devoxx.reportincident.model,
+ org.hsqldb.jdbc,
+ org.fusesource.devoxx.reportincident.model,
+ org.apache.commons.dbcp,
+ *
+ </Import-Package>
+ <Private-Package>org.fusesource.devoxx.reportincident.dao.impl</Private-Package>
+ <Export-Package>org.fusesource.devoxx.reportincident.dao</Export-Package>
+ <DynamicImport-Package>*</DynamicImport-Package>
+ </instructions>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
View
6 ...ibernate/src/main/java/org/fusesource/devoxx/reportincident/dao/impl/IncidentDAOImpl.java
@@ -32,8 +32,8 @@
public class IncidentDAOImpl implements IncidentDAO
{
- private static final transient Log LOG = LogFactory.getLog(IncidentDAOImpl.class);
-
+ private static final transient Log LOG = LogFactory.getLog(IncidentDAOImpl.class);
+
/** The session factory. */
private SessionFactory sessionFactory;
@@ -116,7 +116,7 @@ public void removeIncident( long id )
*/
public void saveIncident( Incident Incident )
{
- SessionImpl session = (SessionImpl) this.sessionFactory.getCurrentSession();
+ SessionImpl session = (SessionImpl) this.sessionFactory.getCurrentSession();
this.sessionFactory.getCurrentSession().saveOrUpdate( Incident );
}
View
2 persistence-hibernate/src/main/resources/META-INF/spring/persistence-osgi.xml
@@ -26,4 +26,4 @@
<osgi:service ref="incidentDAO" interface="IncidentDAO"/>
-</beans>
+</beans>
View
22 persistence-hibernate/src/main/resources/META-INF/spring/spring-dao-beans.xml
@@ -17,15 +17,15 @@
-->
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="
- http://www.springframework.org/schema/beans
- http://www.springframework.org/schema/beans/spring-beans.xsd">
-
- <!-- DAO Declarations -->
- <bean id="incidentDAO" class="IncidentDAOImpl">
- <property name="sessionFactory">
- <ref bean="sessionFactory" />
- </property>
- </bean>
+ xsi:schemaLocation="
+ http://www.springframework.org/schema/beans
+ http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+ <!-- DAO Declarations -->
+ <bean id="incidentDAO" class="IncidentDAOImpl">
+ <property name="sessionFactory">
+ <ref bean="sessionFactory" />
+ </property>
+ </bean>
-</beans>
+</beans>
View
106 persistence-hibernate/src/main/resources/META-INF/spring/spring-datasource-beans-test.xml
@@ -16,11 +16,11 @@
limitations under the License.
-->
<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:context="http://www.springframework.org/schema/context"
- xmlns:osgi="http://www.springframework.org/schema/osgi"
- xmlns:osgix="http://www.springframework.org/schema/osgi-compendium"
- xsi:schemaLocation="
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:context="http://www.springframework.org/schema/context"
+ xmlns:osgi="http://www.springframework.org/schema/osgi"
+ xmlns:osgix="http://www.springframework.org/schema/osgi-compendium"
+ xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context
@@ -30,59 +30,59 @@
http://www.springframework.org/schema/osgi-compendium
http://www.springframework.org/schema/osgi-compendium/spring-osgi-compendium.xsd">
- <context:annotation-config />
+ <context:annotation-config />
- <!-- DB connection and persistence layer -->
- <!-- DataSource Definition -->
- <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
- <property name="driverClassName" value="com.mysql.jdbc.Driver" />
- <property name="url" value="jdbc:mysql:///report" />
- <property name="username" value="root" />
- <property name="password" value="" />
- </bean>
+ <!-- DB connection and persistence layer -->
+ <!-- DataSource Definition -->
+ <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
+ <property name="driverClassName" value="com.mysql.jdbc.Driver" />
+ <property name="url" value="jdbc:mysql:///report" />
+ <property name="username" value="root" />
+ <property name="password" value="" />
+ </bean>
- <!-- Spring Data Access Exception Translator Definition -->
- <bean id="jdbcExceptionTranslator" class="org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator">
- <property name="dataSource">
- <ref bean="dataSource" />
- </property>
- </bean>
+ <!-- Spring Data Access Exception Translator Definition -->
+ <bean id="jdbcExceptionTranslator" class="org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator">
+ <property name="dataSource">
+ <ref bean="dataSource" />
+ </property>
+ </bean>
- <!-- Hibernate SessionFactory Definition -->
- <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
+ <!-- Hibernate SessionFactory Definition -->
+ <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
- <property name="mappingLocations">
- <list>
- <value>classpath*:META-INF/org/apache/camel/example/reportincident/model/*.hbm.xml</value>
- </list>
- </property>
+ <property name="mappingLocations">
+ <list>
+ <value>classpath*:META-INF/org/apache/camel/example/reportincident/model/*.hbm.xml</value>
+ </list>
+ </property>
- <property name="hibernateProperties">
- <props>
- <prop key="hibernate.dialect">org.hibernate.dialect.MySQLDialect</prop>
- <prop key="hibernate.show_sql">false</prop>
- <prop key="hibernate.format_sql">true</prop>
- <prop key="hibernate.cglib.use_reflection_optimizer">true</prop>
- <prop key="hibernate.jdbc.batch_size">10</prop>
- <prop key="hibernate.query.factory_class">org.hibernate.hql.classic.ClassicQueryTranslatorFactory</prop>
- <!--
- <prop key="hibernate.transaction.manager_lookup_class">org.springframework.orm.hibernate3.LocalTransactionManagerLookup</prop>
- <prop key="hibernate.transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</prop>
- -->
- </props>
- </property>
- <property name="dataSource">
- <ref bean="dataSource" />
- </property>
-
- </bean>
+ <property name="hibernateProperties">
+ <props>
+ <prop key="hibernate.dialect">org.hibernate.dialect.MySQLDialect</prop>
+ <prop key="hibernate.show_sql">false</prop>
+ <prop key="hibernate.format_sql">true</prop>
+ <prop key="hibernate.cglib.use_reflection_optimizer">true</prop>
+ <prop key="hibernate.jdbc.batch_size">10</prop>
+ <prop key="hibernate.query.factory_class">org.hibernate.hql.classic.ClassicQueryTranslatorFactory</prop>
+ <!--
+ <prop key="hibernate.transaction.manager_lookup_class">org.springframework.orm.hibernate3.LocalTransactionManagerLookup</prop>
+ <prop key="hibernate.transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</prop>
+ -->
+ </props>
+ </property>
+ <property name="dataSource">
+ <ref bean="dataSource" />
+ </property>
+
+ </bean>
- <!-- Hibernate Transaction Manager Definition -->
- <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
- <property name="sessionFactory">
- <ref local="sessionFactory" />
- </property>
- </bean>
+ <!-- Hibernate Transaction Manager Definition -->
+ <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
+ <property name="sessionFactory">
+ <ref local="sessionFactory" />
+ </property>
+ </bean>
-</beans>
+</beans>
View
170 persistence-hibernate/src/main/resources/META-INF/spring/spring-datasource-beans.xml
@@ -16,11 +16,11 @@
limitations under the License.
-->
<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:context="http://www.springframework.org/schema/context"
- xmlns:osgi="http://www.springframework.org/schema/osgi"
- xmlns:osgix="http://www.springframework.org/schema/osgi-compendium"
- xsi:schemaLocation="
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:context="http://www.springframework.org/schema/context"
+ xmlns:osgi="http://www.springframework.org/schema/osgi"
+ xmlns:osgix="http://www.springframework.org/schema/osgi-compendium"
+ xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context
@@ -30,92 +30,92 @@
http://www.springframework.org/schema/osgi-compendium
http://www.springframework.org/schema/osgi-compendium/spring-osgi-compendium.xsd">
- <context:annotation-config />
- <context:property-placeholder properties-ref="preProps" />
-
- <!-- DB connection and persistence layer -->
- <!-- DataSource Definition -->
- <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
- <property name="driverClassName" value="${driverClassName}" />
- <property name="url" value="${url}" />
- <property name="username" value="${username}" />
- <property name="password" value="${password}" />
- </bean>
-
-
- <!-- Spring Data Access Exception Translator Definition -->
- <bean id="jdbcExceptionTranslator" class="org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator">
- <property name="dataSource">
- <ref bean="dataSource" />
- </property>
- </bean>
-
- <!-- Hibernate SessionFactory Definition -->
- <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
-
- <property name="mappingLocations">
- <list>
- <value>classpath*:META-INF/org/apache/camel/example/reportincident/model/*.hbm.xml</value>
- </list>
- </property>
-
- <property name="hibernateProperties">
- <props>
- <prop key="hibernate.dialect">org.hibernate.dialect.MySQLDialect</prop>
- <prop key="hibernate.show_sql">false</prop>
- <prop key="hibernate.format_sql">true</prop>
- <prop key="hibernate.cglib.use_reflection_optimizer">true</prop>
- <prop key="hibernate.jdbc.batch_size">10</prop>
- <prop key="hibernate.query.factory_class">org.hibernate.hql.classic.ClassicQueryTranslatorFactory</prop>
- <!--
- <prop key="hibernate.transaction.manager_lookup_class">org.springframework.orm.hibernate3.LocalTransactionManagerLookup</prop>
- <prop key="hibernate.transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</prop>
- -->
- </props>
- </property>
- <property name="dataSource">
- <ref bean="dataSource" />
- </property>
- <!--
- <property name="jtaTransactionManager">
- <osgi:reference>
- <osgi:interfaces>
- <value>org.springframework.transaction.PlatformTransactionManager</value>
- <value>javax.transaction.TransactionManager</value>
- </osgi:interfaces>
- </osgi:reference>
- </property>
- -->
-
- </bean>
-
- <!-- Hibernate Transaction Manager Definition -->
- <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
- <property name="sessionFactory">
- <ref local="sessionFactory" />
- </property>
- </bean>
-
-
- <!--
- Hibernate Transaction Manager exported as OSGI service because used
- org.fusesource.devoxx.reportincident.service
-
- <osgi:service id="transactionManagerOsgi" ref="transactionManager"
- interface="org.springframework.transaction.PlatformTransactionManager" />
- -->
-
-
- <!-- MySQL
- <osgix:cm-properties id="preProps" persistent-id="org.fusesource.devoxx.reportincident.datasource">
+ <context:annotation-config />
+ <context:property-placeholder properties-ref="preProps" />
+
+ <!-- DB connection and persistence layer -->
+ <!-- DataSource Definition -->
+ <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
+ <property name="driverClassName" value="${driverClassName}" />
+ <property name="url" value="${url}" />
+ <property name="username" value="${username}" />
+ <property name="password" value="${password}" />
+ </bean>
+
+
+ <!-- Spring Data Access Exception Translator Definition -->
+ <bean id="jdbcExceptionTranslator" class="org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator">
+ <property name="dataSource">
+ <ref bean="dataSource" />
+ </property>
+ </bean>
+
+ <!-- Hibernate SessionFactory Definition -->
+ <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
+
+ <property name="mappingLocations">
+ <list>
+ <value>classpath*:META-INF/org/apache/camel/example/reportincident/model/*.hbm.xml</value>
+ </list>
+ </property>
+
+ <property name="hibernateProperties">
+ <props>
+ <prop key="hibernate.dialect">org.hibernate.dialect.MySQLDialect</prop>
+ <prop key="hibernate.show_sql">false</prop>
+ <prop key="hibernate.format_sql">true</prop>
+ <prop key="hibernate.cglib.use_reflection_optimizer">true</prop>
+ <prop key="hibernate.jdbc.batch_size">10</prop>
+ <prop key="hibernate.query.factory_class">org.hibernate.hql.classic.ClassicQueryTranslatorFactory</prop>
+ <!--
+ <prop key="hibernate.transaction.manager_lookup_class">org.springframework.orm.hibernate3.LocalTransactionManagerLookup</prop>
+ <prop key="hibernate.transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</prop>
+ -->
+ </props>
+ </property>
+ <property name="dataSource">
+ <ref bean="dataSource" />
+ </property>
+ <!--
+ <property name="jtaTransactionManager">
+ <osgi:reference>
+ <osgi:interfaces>
+ <value>org.springframework.transaction.PlatformTransactionManager</value>
+ <value>javax.transaction.TransactionManager</value>
+ </osgi:interfaces>
+ </osgi:reference>
+ </property>
+ -->
+
+ </bean>
+
+ <!-- Hibernate Transaction Manager Definition -->
+ <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
+ <property name="sessionFactory">
+ <ref local="sessionFactory" />
+ </property>
+ </bean>
+
+
+ <!--
+ Hibernate Transaction Manager exported as OSGI service because used
+ org.fusesource.devoxx.reportincident.service
+
+ <osgi:service id="transactionManagerOsgi" ref="transactionManager"
+ interface="org.springframework.transaction.PlatformTransactionManager" />
+ -->
+
+
+ <!-- MySQL
+ <osgix:cm-properties id="preProps" persistent-id="org.fusesource.devoxx.reportincident.datasource">
<prop key="driverClassName">com.mysql.jdbc.Driver</prop>
<prop key="url">jdbc:mysql:///report</prop>
<prop key="username">root</prop>
<prop key="password"></prop>
</osgix:cm-properties>
-->
- <!-- HSQLDB -->
+ <!-- HSQLDB -->
<osgix:cm-properties id="preProps" persistent-id="org.fusesource.devoxx.reportincident.datasource">
<prop key="driverClassName">org.hsqldb.jdbc.Driver</prop>
<prop key="url">jdbc:hsqldb:file:/tmp/reportincident</prop>
@@ -125,4 +125,4 @@
-</beans>
+</beans>
View
2 persistence-hibernate/src/main/resources/log4j.properties
@@ -5,4 +5,4 @@ log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.threshold=TRACE
#log4j.logger.org.springframework.osgi=DEBUG
-#log4j.logger.org.springframework=DEBUG
+#log4j.logger.org.springframework=DEBUG
View
170 persistence-jpa/pom.xml
@@ -16,107 +16,107 @@
limitations under the License.
-->
<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">
- <modelVersion>4.0.0</modelVersion>
- <groupId>org.fusesource.devoxx.reportincident</groupId>
- <artifactId>persistence-jpa</artifactId>
- <packaging>bundle</packaging>
- <name>Reportincident :: Persistence JPA</name>
- <version>1.0-SNAPSHOT</version>
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.fusesource.devoxx.reportincident</groupId>
+ <artifactId>persistence-jpa</artifactId>
+ <packaging>bundle</packaging>
+ <name>Reportincident :: Persistence JPA</name>
+ <version>1.0-SNAPSHOT</version>
- <parent>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident.parent</artifactId>
- <version>1.0-SNAPSHOT</version>
- </parent>
+ <parent>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident.parent</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
- <dependencies>
+ <dependencies>
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-jpa_3.0_spec</artifactId>
<version>${geronimo_jpa_spec-version}</version>
</dependency>
- <dependency>
- <groupId>javax.transaction</groupId>
- <artifactId>jta</artifactId>
- <version>${jta-version}</version>
- </dependency>
- <dependency>
- <groupId>commons-dbcp</groupId>
- <artifactId>commons-dbcp</artifactId>
- <version>${commons-dbcp-version}</version>
- </dependency>
- <dependency>
- <groupId>org.hsqldb</groupId>
- <artifactId>hsqldb</artifactId>
- <version>${hsqldb-version}</version>
- </dependency>
- <dependency>
- <groupId>com.h2database</groupId>
- <artifactId>h2</artifactId>
- <version>${h2-version}</version>
- </dependency>
<dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-bindy</artifactId>
- <version>${camel-version}</version>
- </dependency>
- <dependency>
- <groupId>commons-lang</groupId>
- <artifactId>commons-lang</artifactId>
- <version>${commons-lang}</version>
- </dependency>
+ <groupId>javax.transaction</groupId>
+ <artifactId>jta</artifactId>
+ <version>${jta-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-dbcp</groupId>
+ <artifactId>commons-dbcp</artifactId>
+ <version>${commons-dbcp-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.hsqldb</groupId>
+ <artifactId>hsqldb</artifactId>
+ <version>${hsqldb-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>com.h2database</groupId>
+ <artifactId>h2</artifactId>
+ <version>${h2-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-bindy</artifactId>
+ <version>${camel-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>${commons-lang}</version>
+ </dependency>
<dependency>
- <groupId>commons-logging</groupId>
- <artifactId>commons-logging</artifactId>
- <version>${commons-logging-version}</version>
- </dependency>
- </dependencies>
-
- <repositories>
- <repository>
- <id>Sun Java Repo</id>
- <url>http://download.java.net/maven/2/</url>
- </repository>
+ <groupId>commons-logging</groupId>
+ <artifactId>commons-logging</artifactId>
+ <version>${commons-logging-version}</version>
+ </dependency>
+ </dependencies>
+
+ <repositories>
+ <repository>
+ <id>Sun Java Repo</id>
+ <url>http://download.java.net/maven/2/</url>
+ </repository>
</repositories>
-
+
- <build>
- <plugins>
- <!-- to compile with 1.5 -->
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
+ <build>
+ <plugins>
+ <!-- to compile with 1.5 -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
- <!-- to generate the MANIFEST-FILE of the bundle -->
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <extensions>true</extensions>
- <version>${felix-version}</version>
- <configuration>
- <instructions>
- <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
- <Import-Package>
+ <!-- to generate the MANIFEST-FILE of the bundle -->
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <extensions>true</extensions>
+ <version>${felix-version}</version>
+ <configuration>
+ <instructions>
+ <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
+ <Import-Package>
org.springframework*;version="[2.5,4.0)",
javax.persistence*;version="[1.1.0,2.1.0)",
javax.persistence.criteria;version="[1.1.0,2.1.0)",
*
- </Import-Package>
- <Private-Package>org.fusesource.devoxx.reportincident.dao.impl</Private-Package>
- <Export-Package>
+ </Import-Package>
+ <Private-Package>org.fusesource.devoxx.reportincident.dao.impl</Private-Package>
+ <Export-Package>
org.fusesource.devoxx.reportincident.model,
org.fusesource.devoxx.reportincident.dao
</Export-Package>
- </instructions>
- </configuration>
- </plugin>
+ </instructions>
+ </configuration>
+ </plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
@@ -153,7 +153,7 @@
</plugin>
- </plugins>
- </build>
-
-</project>
+ </plugins>
+ </build>
+
+</project>
View
2 persistence-jpa/src/main/java/org/fusesource/devoxx/reportincident/dao/IncidentDAO.java
@@ -31,4 +31,4 @@
public abstract void saveIncident(Incident paramIncident);
public abstract void removeIncident(long paramLong);
-}
+}
View
2 ...ence-jpa/src/main/java/org/fusesource/devoxx/reportincident/dao/impl/IncidentDAOImpl.java
@@ -69,4 +69,4 @@ public void saveIncident(Incident incident) {
this.em.persist(incident);
this.em.flush();
}
-}
+}
View
48 persistence-jpa/src/main/resources/META-INF/spring/persistence-dao.xml
@@ -21,11 +21,11 @@
xmlns:osgi="http://www.springframework.org/schema/osgi"
xmlns:osgix="http://www.springframework.org/schema/osgi-compendium"
xsi:schemaLocation="
- http://www.springframework.org/schema/beans
- http://www.springframework.org/schema/beans/spring-beans.xsd
- http://www.springframework.org/schema/context
- http://www.springframework.org/schema/context/spring-context.xsd
- http://www.springframework.org/schema/osgi
+ http://www.springframework.org/schema/beans
+ http://www.springframework.org/schema/beans/spring-beans.xsd
+ http://www.springframework.org/schema/context
+ http://www.springframework.org/schema/context/spring-context.xsd
+ http://www.springframework.org/schema/osgi
http://www.springframework.org/schema/osgi/spring-osgi.xsd
http://www.springframework.org/schema/osgi-compendium
http://www.springframework.org/schema/osgi-compendium/spring-osgi-compendium.xsd">
@@ -59,20 +59,20 @@
-->
<!-- OpenJPA Derby addapter
- <bean id="jpaAdapterDerby" class="org.springframework.orm.jpa.vendor.OpenJpaVendorAdapter">
- <property name="databasePlatform" value="org.apache.openjpa.jdbc.sql.DerbyDictionary" />
- <property name="database" value="DERBY" />
+ <bean id="jpaAdapterDerby" class="org.springframework.orm.jpa.vendor.OpenJpaVendorAdapter">
+ <property name="databasePlatform" value="org.apache.openjpa.jdbc.sql.DerbyDictionary" />
+ <property name="database" value="DERBY" />
<property name="showSql" value="true" />
- </bean>
- -->
+ </bean>
+ -->
<!-- OpenJPA MySQL adapter
- <bean id="jpaAdapterMYSQL"
- class="org.springframework.orm.jpa.vendor.OpenJpaVendorAdapter">
+ <bean id="jpaAdapterMYSQL"
+ class="org.springframework.orm.jpa.vendor.OpenJpaVendorAdapter">
<property name="databasePlatform" value="org.apache.openjpa.jdbc.sql.MySQLDictionary" />
- <property name="showSql" value="true" />
- </bean>
- -->
+ <property name="showSql" value="true" />
+ </bean>
+ -->
<!-- OpenJPA HSQL addapter
<bean id="jpaAdapterHSQL" class="org.springframework.orm.jpa.vendor.OpenJpaVendorAdapter">
@@ -90,14 +90,14 @@
<!-- DataSource MYSQL
- <bean id="dataSourceMYSQL" class="org.apache.commons.dbcp.BasicDataSource">
- <property name="username" value="root" />
- <property name="password" value="" />
- <property name="driverClassName" value="com.mysql.jdbc.Driver" />
- <property name="url" value="jdbc:mysql://localhost:3306/reportincident" />
- <property name="defaultAutoCommit" value="true"/>
- </bean>
- -->
+ <bean id="dataSourceMYSQL" class="org.apache.commons.dbcp.BasicDataSource">
+ <property name="username" value="root" />
+ <property name="password" value="" />
+ <property name="driverClassName" value="com.mysql.jdbc.Driver" />
+ <property name="url" value="jdbc:mysql://localhost:3306/reportincident" />
+ <property name="defaultAutoCommit" value="true"/>
+ </bean>
+ -->
<!-- DataSource Derby
<bean id="dataSourceDERBY" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
@@ -147,4 +147,4 @@
-->
-</beans>
+</beans>
View
2 persistence-jpa/src/main/resources/log4j.properties
@@ -5,4 +5,4 @@ log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.threshold=TRACE
#log4j.logger.org.springframework.osgi=DEBUG
-#log4j.logger.org.springframework=DEBUG
+#log4j.logger.org.springframework=DEBUG
View
4 pom.xml
@@ -25,13 +25,11 @@
<modules>
<module>features</module>
- <!-- <module>model</module> -->
<module>persistence-jpa</module>
<module>service</module>
<module>routing</module>
<module>web</module>
<module>webservice</module>
- <!-- <module>db</module> -->
</modules>
<properties>
@@ -174,4 +172,4 @@
</pluginManagement>
</build>
-</project>
+</project>
View
332 routing/pom.xml
@@ -16,98 +16,98 @@
limitations under the License.
-->
<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">
- <modelVersion>4.0.0</modelVersion>
- <groupId>org.fusesource.devoxx.reportincident</groupId>
- <artifactId>routing</artifactId>
- <packaging>bundle</packaging>
- <version>1.0-SNAPSHOT</version>
- <name>Reportincident :: Routing Bundle</name>
-
- <parent>
- <groupId>org.apache.camel.example</groupId>
- <artifactId>reportincident.parent</artifactId>
- <version>1.0-SNAPSHOT</version>
- </parent>
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>org.fusesource.devoxx.reportincident</groupId>
+ <artifactId>routing</artifactId>
+ <packaging>bundle</packaging>
+ <version>1.0-SNAPSHOT</version>
+ <name>Reportincident :: Routing Bundle</name>
+
+ <parent>
+ <groupId>org.apache.camel.example</groupId>
+ <artifactId>reportincident.parent</artifactId>
+ <version>1.0-SNAPSHOT</version>
+ </parent>
- <dependencies>
- <dependency>
- <groupId>org.fusesource.devoxx.reportincident</groupId>
- <artifactId>service</artifactId>
- </dependency>
- <dependency>
- <groupId>org.fusesource.devoxx.reportincident</groupId>
- <artifactId>webservice</artifactId>
- </dependency>
- <dependency>
- <groupId>org.fusesource.devoxx.reportincident</groupId>
- <artifactId>persistence-jpa</artifactId>
- </dependency>
+ <dependencies>
+ <dependency>
+ <groupId>org.fusesource.devoxx.reportincident</groupId>
+ <artifactId>service</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.fusesource.devoxx.reportincident</groupId>
+ <artifactId>webservice</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.fusesource.devoxx.reportincident</groupId>
+ <artifactId>persistence-jpa</artifactId>
+ </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-core</artifactId>
- <version>${camel-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-spring</artifactId>
- <version>${camel-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-bindy</artifactId>
- <version>${camel-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.cxf</groupId>
- <artifactId>cxf-bundle</artifactId>
- <version>${cxf-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.cxf</groupId>
- <artifactId>cxf-common-utilities</artifactId>
- <version>${cxf-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-cxf</artifactId>
- <version>${camel-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-jms</artifactId>
- <version>${camel-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.activemq</groupId>
- <artifactId>activemq-camel</artifactId>
- <version>${activemq-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.activemq</groupId>
- <artifactId>activemq-core</artifactId>
- <version>${activemq-version}</version>
- </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-core</artifactId>
+ <version>${camel-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-spring</artifactId>
+ <version>${camel-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-bindy</artifactId>
+ <version>${camel-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.cxf</groupId>
+ <artifactId>cxf-bundle</artifactId>
+ <version>${cxf-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.cxf</groupId>
+ <artifactId>cxf-common-utilities</artifactId>
+ <version>${cxf-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-cxf</artifactId>
+ <version>${camel-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-jms</artifactId>
+ <version>${camel-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.activemq</groupId>
+ <artifactId>activemq-camel</artifactId>
+ <version>${activemq-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.activemq</groupId>
+ <artifactId>activemq-core</artifactId>
+ <version>${activemq-version}</version>
+ </dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j-version}</version>
</dependency>
- <dependency>
- <groupId>log4j</groupId>
- <artifactId>log4j</artifactId>
- <version>${log4j-version}</version>
- </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <version>${log4j-version}</version>
+ </dependency>
- <dependency>
+ <dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-beans</artifactId>
<version>${spring-version}</version>
</dependency>
- <dependency>
+ <dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jms</artifactId>
<version>${spring-version}</version>
@@ -117,15 +117,15 @@
<artifactId>spring-osgi-core</artifactId>
<version>${spring-osgi-version}</version>
</dependency>
-
- <!-- Test -->
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>${junit-version}</version>
- <scope>test</scope>
- </dependency>
- <dependency>
+
+ <!-- Test -->
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>${junit-version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-core</artifactId>
<version>${camel-version}</version>
@@ -139,91 +139,91 @@
<scope>test</scope>
</dependency>
- </dependencies>
+ </dependencies>
- <build>
- <plugins>
- <!-- to compile with 1.5 -->
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
+ <build>
+ <plugins>
+ <!-- to compile with 1.5 -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
- <!-- to generate the MANIFEST-FILE of the bundle -->
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <extensions>true</extensions>
- <version>${felix-version}</version>
- <configuration>
- <instructions>
- <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
- <Import-Package>
- META-INF.cxf,
- META-INF.cxf.osgi,
- META-INF.wsdl,
+ <!-- to generate the MANIFEST-FILE of the bundle -->
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <extensions>true</extensions>
+ <version>${felix-version}</version>
+ <configuration>
+ <instructions>
+ <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
+ <Import-Package>
+ META-INF.cxf,
+ META-INF.cxf.osgi,
+ META-INF.wsdl,
javax.xml.namespace,
javax.xml.soap;version=0,
javax.xml.ws;version=0,
org.w3c.dom;version=0,
- org.apache.commons.logging,
- org.apache.camel;version="[2.0,3.0)",
- org.apache.camel.component;version="[2.0,3.0)",
- org.apache.camel.component.cxf;version="[2.0,3.0)",
- org.apache.camel.component.cxf.converter;version="[2.0,3.0)",
- org.apache.camel.component.jms;version="[2.0,3.0)",
- org.apache.camel.converter;version="[2.0,3.0)",
- org.apache.camel.converter.jaxp;version="[2.0,3.0)",
- org.apache.camel.converter.stream;version="[2.0,3.0)",
- org.apache.camel.dataformat.bindy;version="[2.0,3.0)",
- org.apache.camel.dataformat.bindy.csv;version="[2.0,3.0)",
- org.fusesource.devoxx.reportincident,
- org.fusesource.devoxx.reportincident.model,
- org.fusesource.devoxx.reportincident.service,
- org.apache.camel.processor;version="[2.0,3.0)",
- org.apache.activemq.camel.component;version="[5.3,6.0)",
- org.apache.activemq.camel.converter;version="[5.3,6.0)",
- org.apache.activemq.pool,
- org.apache.cxf,
- org.apache.cxf.binding,
- org.apache.cxf.binding.corba,
- org.apache.cxf.binding.soap,
- org.apache.cxf.binding.soap.spring,
- org.apache.cxf.bus,
- org.apache.cxf.bus.resource,
- org.apache.cxf.bus.spring,
- org.apache.cxf.buslifecycle,
- org.apache.cxf.catalog,
- org.apache.cxf.configuration,
- org.apache.cxf.configuration.spring,
- org.apache.cxf.endpoint,
- org.apache.cxf.headers,
- org.apache.cxf.management,
- org.apache.cxf.management.jmx,
- org.apache.cxf.phase,
- org.apache.cxf.resource,
+ org.apache.commons.logging,
+ org.apache.camel;version="[2.0,3.0)",
+ org.apache.camel.component;version="[2.0,3.0)",
+ org.apache.camel.component.cxf;version="[2.0,3.0)",
+ org.apache.camel.component.cxf.converter;version="[2.0,3.0)",
+ org.apache.camel.component.jms;version="[2.0,3.0)",
+ org.apache.camel.converter;version="[2.0,3.0)",
+ org.apache.camel.converter.jaxp;version="[2.0,3.0)",
+ org.apache.camel.converter.stream;version="[2.0,3.0)",
+ org.apache.camel.dataformat.bindy;version="[2.0,3.0)",
+ org.apache.camel.dataformat.bindy.csv;version="[2.0,3.0)",
+ org.fusesource.devoxx.reportincident,
+ org.fusesource.devoxx.reportincident.model,
+ org.fusesource.devoxx.reportincident.service,
+ org.apache.camel.processor;version="[2.0,3.0)",
+ org.apache.activemq.camel.component;version="[5.3,6.0)",
+ org.apache.activemq.camel.converter;version="[5.3,6.0)",
+ org.apache.activemq.pool,
+ org.apache.cxf,
+ org.apache.cxf.binding,
+ org.apache.cxf.binding.corba,
+ org.apache.cxf.binding.soap,
+ org.apache.cxf.binding.soap.spring,
+ org.apache.cxf.bus,
+ org.apache.cxf.bus.resource,
+ org.apache.cxf.bus.spring,
+ org.apache.cxf.buslifecycle,
+ org.apache.cxf.catalog,
+ org.apache.cxf.configuration,
+ org.apache.cxf.configuration.spring,
+ org.apache.cxf.endpoint,
+ org.apache.cxf.headers,
+ org.apache.cxf.management,
+ org.apache.cxf.management.jmx,
+ org.apache.cxf.phase,
+ org.apache.cxf.resource,
org.apache.cxf.service.factory,
org.apache.cxf.tools.common.extensions.soap,
- org.apache.cxf.transport,
- org.apache.cxf.transport.http,
- org.apache.cxf.transport.http.policy,
- org.apache.cxf.transport.http_jetty,
- org.apache.cxf.transport.jms,
- org.apache.cxf.transports.http,
- org.apache.cxf.workqueue,
- org.apache.cxf.wsdl,
- org.apache.cxf.wsdl11,
- org.springframework.beans.factory.config,
- *
- </Import-Package>
- <Private-Package>org.fusesource.devoxx.reportincident.internal</Private-Package>
- </instructions>
- </configuration>
- </plugin>
+ org.apache.cxf.transport,
+ org.apache.cxf.transport.http,
+ org.apache.cxf.transport.http.policy,
+ org.apache.cxf.transport.http_jetty,
+ org.apache.cxf.transport.jms,
+ org.apache.cxf.transports.http,
+ org.apache.cxf.workqueue,
+ org.apache.cxf.wsdl,
+ org.apache.cxf.wsdl11,
+ org.springframework.beans.factory.config,
+ *
+ </Import-Package>
+ <Private-Package>org.fusesource.devoxx.reportincident.internal</Private-Package>
+ </instructions>
+ </configuration>
+ </plugin>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
@@ -236,6 +236,6 @@
</excludes> -->
</configuration>
</plugin>
- </plugins>
- </build>
+ </plugins>
+ </build>
</project>
View
10 routing/src/main/java/org/fusesource/devoxx/reportincident/internal/Feedback.java
@@ -20,10 +20,10 @@
public class Feedback {
- public OutputReportIncident setOk() {
- OutputReportIncident outputReportIncident = new OutputReportIncident();
- outputReportIncident.setCode("0");
- return outputReportIncident;
- }
+ public OutputReportIncident setOk() {
+ OutputReportIncident outputReportIncident = new OutputReportIncident();
+ outputReportIncident.setCode("0");
+ return outputReportIncident;
+ }
}
View
90 routing/src/main/java/org/fusesource/devoxx/reportincident/internal/IncidentSaver.java
@@ -29,65 +29,65 @@
public class IncidentSaver {
- private static final transient Log LOG = LogFactory.getLog(IncidentSaver.class);
-
- private IncidentService incidentService = null;
+ private static final transient Log LOG = LogFactory.getLog(IncidentSaver.class);
+
+ private IncidentService incidentService = null;
- public void process(Exchange exchange) throws ParseException {
+ public void process(Exchange exchange) throws ParseException {
- int count = 0;
+ int count = 0;
- List<Map<String, Object>> models = new ArrayList<Map<String, Object>>();
- Map<String, Object> model = new HashMap<String, Object>();
+ List<Map<String, Object>> models = new ArrayList<Map<String, Object>>();
+ Map<String, Object> model = new HashMap<String, Object>();
- // Get models from message
- models = (List<Map<String, Object>>) exchange.getIn().getBody();
-
- // Get Header origin from message
- String origin = (String) exchange.getIn().getHeader("origin");
- LOG.debug("Header origin : " + origin);
+ // Get models from message
+ models = (List<Map<String, Object>>) exchange.getIn().getBody();
+
+ // Get Header origin from message
+ String origin = (String) exchange.getIn().getHeader("origin");
+ LOG.debug("Header origin : " + origin);
- Iterator<Map<String, Object>> it = models.iterator();
-
- // Specify current Date
+ Iterator<Map<String, Object>> it = models.iterator();
+
+ // Specify current Date
DateFormat format = new SimpleDateFormat( "dd/MM/yyyy HH:mm:ss" );
String currentDate = format.format( new Date() );
Date creationDate = format.parse( currentDate );
- while (it.hasNext()) {
+ while (it.hasNext()) {
- model = it.next();
-
- LOG.debug("Model retrieved");
+ model = it.next();
+
+ LOG.debug("Model retrieved");
- for (String key : model.keySet()) {
-
- LOG.debug("Object retrieved : " + model.get(key).toString());
-
- // Retrieve incident from model
- Incident incident = (Incident) model.get(key);
- incident.setCreationDate(creationDate);
- incident.setCreationUser(origin);
-
- LOG.debug("Count : " + count + ", " + incident.toString());
-
- // Save org.fusesource.devoxx.reportincident.model.Incident
- incidentService.saveIncident(incident);
- LOG.debug(">>> org.fusesource.devoxx.reportincident.model.Incident saved");
- }
+ for (String key : model.keySet()) {
+
+ LOG.debug("Object retrieved : " + model.get(key).toString());
+
+ // Retrieve incident from model
+ Incident incident = (Incident) model.get(key);
+ incident.setCreationDate(creationDate);
+ incident.setCreationUser(origin);
+
+ LOG.debug("Count : " + count + ", " + incident.toString());
+
+ // Save org.fusesource.devoxx.reportincident.model.Incident
+ incidentService.saveIncident(incident);
+ LOG.debug(">>> org.fusesource.devoxx.reportincident.model.Incident saved");
+ }
- count++;
- }
+ count++;
+ }
- LOG.debug("Nber of CSV records received by the csv bean : " + count);
+ LOG.debug("Nber of CSV records received by the csv bean : " + count);
- }
-
+ }
+
// Property used to inject service implementation
- public void setIncidentService(IncidentService incidentService) {
- this.incidentService = incidentService;
- }
-
-
+ public void setIncidentService(IncidentService incidentService) {
+ this.incidentService = incidentService;
+ }
+
+
}
View
78 routing/src/main/java/org/fusesource/devoxx/reportincident/internal/WebService.java
@@ -33,56 +33,56 @@
public class WebService {
- private static final transient Log LOG = LogFactory.getLog(WebService.class);
+ private static final transient Log LOG = LogFactory.getLog(WebService.class);
- public void process(Exchange exchange) throws ParseException {
+ public void process(Exchange exchange) throws ParseException {
- InputReportIncident webincident = (InputReportIncident)exchange.getIn().getBody();
-
- LOG.debug("prg.apache.camel.example.reportincident.model.Incident received from : " + webincident.getFamilyName() + ", " + webincident.getGivenName());
- LOG.debug("prg.apache.camel.example.reportincident.model.Incident info : " + webincident.getIncidentId() + ", at : " + webincident.getIncidentDate());
- LOG.debug("prg.apache.camel.example.reportincident.model.Incident details : " + webincident.getDetails() + ", summary : " + webincident.getSummary());
+ InputReportIncident webincident = (InputReportIncident)exchange.getIn().getBody();
+
+ LOG.debug("prg.apache.camel.example.reportincident.model.Incident received from : " + webincident.getFamilyName() + ", " + webincident.getGivenName());
+ LOG.debug("prg.apache.camel.example.reportincident.model.Incident info : " + webincident.getIncidentId() + ", at : " + webincident.getIncidentDate());
+ LOG.debug("prg.apache.camel.example.reportincident.model.Incident details : " + webincident.getDetails() + ", summary : " + webincident.getSummary());
-
- List<Map<String, Incident>> models = new ArrayList<Map<String, Incident>>();
- Map<String, Incident> model = new HashMap<String, Incident>();
-
- // Convert the InputReportIncident into an prg.apache.camel.example.reportincident.model.Incident
- Incident incident = new Incident();
-
- DateFormat format =