[kune-commits] r1136 - in trunk: . src/main/java/org/ourproject/kune/platf/server/manager/impl src/test/java/org/ourproject/kune/platf/server src/test/java/org/ourproject/kune/platf/server/manager war/WEB-INF/lib

vjrj vjrj at ourproject.org
Wed Jul 22 13:56:17 CEST 2009


Author: vjrj
Date: 2009-07-22 13:56:12 +0200 (Wed, 22 Jul 2009)
New Revision: 1136

Added:
   trunk/pom.xml.net
Modified:
   trunk/TROUBLESHOOT
   trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/GroupManagerDefault.java
   trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/UserManagerDefault.java
   trunk/src/test/java/org/ourproject/kune/platf/server/PersistencePreLoadedDataTest.java
   trunk/src/test/java/org/ourproject/kune/platf/server/manager/UserManagerTest.java
   trunk/war/WEB-INF/lib/gwt-servlet.jar
Log:
Incomplete - task Entity Properties (Group/User preferences) 


Modified: trunk/TROUBLESHOOT
===================================================================
--- trunk/TROUBLESHOOT	2009-07-19 18:10:48 UTC (rev 1135)
+++ trunk/TROUBLESHOOT	2009-07-22 11:56:12 UTC (rev 1136)
@@ -46,3 +46,9 @@
    Connections could not be acquired from the underlying database
 
 We have problems testing all test together from eclipse and using real db (not the h2 memory db)
+
+=== Too many files open ===
+
+If running all the Kune test you get errors about "Too many files open" see:
+http://code.google.com/p/gwt-examples/wiki/gwtEclipseFaqs
+about how to fix it in your system.
\ No newline at end of file

Added: trunk/pom.xml.net
===================================================================
--- trunk/pom.xml.net	2009-07-19 18:10:48 UTC (rev 1135)
+++ trunk/pom.xml.net	2009-07-22 11:56:12 UTC (rev 1136)
@@ -0,0 +1,826 @@
+<?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">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.ourproject</groupId>
+  <artifactId>kune</artifactId>
+  <packaging>jar</packaging>
+  <version>0.0.6</version>
+  <description>
+    kune free/open/libre collaboration platform
+  </description>
+  <name>kune</name>
+  <url>http://kune.ourproject.org</url>
+  <properties>
+    <gwtVersion>1.7.0</gwtVersion>
+  </properties>
+  <dependencies>
+    <!-- guice -->
+    <dependency>
+      <groupId>com.google.code.guice</groupId>
+      <artifactId>guice</artifactId>
+      <version>1.0</version>
+    </dependency>
+    <dependency>
+      <groupId>com.google.code.guice</groupId>
+      <artifactId>guice-servlet</artifactId>
+      <version>1.0</version>
+    </dependency>
+    <dependency>
+      <groupId>aopalliance</groupId>
+      <artifactId>aopalliance</artifactId>
+      <version>1.0</version>
+    </dependency>
+
+    <!-- G WT deps (from central repo) -->
+    <dependency>
+      <groupId>com.google.gwt</groupId>
+      <artifactId>gwt-servlet</artifactId>
+      <version>${gwtVersion}</version>
+      <scope>runtime</scope>
+    </dependency>
+    <dependency>
+      <groupId>com.google.gwt</groupId>
+      <artifactId>gwt-user</artifactId>
+      <version>${gwtVersion}</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>com.google.gwt</groupId>
+      <artifactId>gwt-dev</artifactId>
+      <version>${gwtVersion}</version>
+      <classifier>${platform}-libs</classifier>
+      <type>zip</type>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>com.google.gwt</groupId>
+      <artifactId>gwt-dev</artifactId>
+      <version>${gwtVersion}</version>
+      <classifier>${platform}</classifier>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>com.google.gwt</groupId>
+      <artifactId>gwt-incubator</artifactId>
+      <version>march-02-2009</version>
+      <scope>provided</scope>
+    </dependency>
+    <!--
+      <dependency> <groupId>com.extjs</groupId>
+      <artifactId>gxt</artifactId> <version>1.0-beta2</version>
+      </dependency>
+    -->
+    <dependency>
+      <groupId>org.cobogw</groupId>
+      <artifactId>gwt</artifactId>
+      <version>1.2.2</version>
+    </dependency>
+    <dependency>
+      <groupId>com.gwtext</groupId>
+      <artifactId>gwtext</artifactId>
+      <version>2.0.5</version>
+    </dependency>
+    <dependency>
+      <groupId>com.gwtextux</groupId>
+      <artifactId>gwtextux</artifactId>
+      <version>0.4.0.924</version>
+    </dependency>
+    <dependency>
+      <groupId>com.allen_sauer.gwt.log.gwt-log</groupId>
+      <artifactId>gwt-log</artifactId>
+      <version>2.6.2</version>
+    </dependency>
+    <dependency>
+      <groupId>com.allen_sauer.gwt.voices.gwt-voices</groupId>
+      <artifactId>gwt-voices</artifactId>
+      <version>1.6.0</version>
+    </dependency>
+
+    <!-- utilities -->
+    <dependency>
+      <groupId>log4j</groupId>
+      <artifactId>log4j</artifactId>
+      <version>1.2.14</version>
+    </dependency>
+    <dependency>
+      <groupId>net.sf.dozer</groupId>
+      <artifactId>dozer</artifactId>
+      <version>4.0</version>
+    </dependency>
+    <dependency>
+      <groupId>com.calclab</groupId>
+      <artifactId>suco</artifactId>
+      <version>0.6.1</version>
+    </dependency>
+    <dependency>
+      <groupId>jmagick</groupId>
+      <artifactId>jmagick</artifactId>
+      <version>6.2.6-0</version>
+    </dependency>
+    <dependency>
+      <groupId>org.xwiki.platform</groupId>
+      <artifactId>xwiki-web-gwt-dom</artifactId>
+      <version>2.0-SNAPSHOT</version>
+      <!-- <version>2.0-SNAPSHOT-g164</version> -->
+    </dependency>
+
+    <!-- xmpp -->
+    <dependency>
+      <groupId>com.calclab.emite</groupId>
+      <artifactId>emite</artifactId>
+      <version>0.4.7</version>
+    </dependency>
+    <dependency>
+      <groupId>org.jivesoftware.smack</groupId>
+      <artifactId>smack</artifactId>
+      <version>3.0.4</version>
+    </dependency>
+    <dependency>
+      <groupId>org.jivesoftware.smackx</groupId>
+      <artifactId>smackx</artifactId>
+      <version>3.0.4</version>
+    </dependency>
+    <dependency>
+      <groupId>org.jivesoftware.smackx.debugger</groupId>
+      <artifactId>smackx-debugger</artifactId>
+      <version>3.0.4</version>
+    </dependency>
+
+    <!--  mysql -->
+    <dependency>
+      <groupId>mysql</groupId>
+      <artifactId>mysql-connector-java</artifactId>
+      <version>5.0.5</version>
+    </dependency>
+
+    <!--  hibernate JPA -->
+    <dependency>
+      <groupId>org.hibernate</groupId>
+      <artifactId>hibernate-search</artifactId>
+      <version>3.1.0.GA</version>
+    </dependency>
+    <dependency>
+      <groupId>org.hibernate</groupId>
+      <artifactId>hibernate</artifactId>
+      <version>3.2.6.ga</version>
+    </dependency>
+    <dependency>
+      <groupId>org.hibernate</groupId>
+      <artifactId>hibernate-annotations</artifactId>
+      <version>3.4.0.GA</version>
+    </dependency>
+    <dependency>
+      <groupId>org.hibernate</groupId>
+      <artifactId>hibernate-validator</artifactId>
+      <version>3.0.0.ga</version>
+    </dependency>
+    <dependency>
+      <groupId>org.hibernate</groupId>
+      <artifactId>hibernate-entitymanager</artifactId>
+      <version>3.4.0.GA</version>
+    </dependency>
+    <dependency>
+      <groupId>org.hibernate</groupId>
+      <artifactId>hibernate-tools</artifactId>
+      <version>3.2.3.GA</version>
+    </dependency>
+    <dependency>
+      <groupId>c3p0</groupId>
+      <artifactId>c3p0</artifactId>
+      <version>0.9.1.2</version>
+    </dependency>
+    <dependency>
+      <groupId>commons-lang</groupId>
+      <artifactId>commons-lang</artifactId>
+      <version>2.0</version>
+    </dependency>
+    <dependency>
+      <groupId>com.wideplay</groupId>
+      <artifactId>warp-persist</artifactId>
+      <version>1.0.1</version>
+    </dependency>
+    <dependency>
+      <groupId>org.slf4j</groupId>
+      <artifactId>slf4j-log4j12</artifactId>
+      <version>1.5.2</version>
+    </dependency>
+
+    <!-- REST: xml and json (stax) -->
+    <dependency>
+      <groupId>com.thoughtworks.xstream</groupId>
+      <artifactId>xstream</artifactId>
+      <version>1.2.2</version>
+    </dependency>
+    <dependency>
+      <groupId>stax</groupId>
+      <artifactId>stax-api</artifactId>
+      <version>1.0.1</version>
+    </dependency>
+    <dependency>
+      <groupId>org.codehaus.jettison</groupId>
+      <artifactId>jettison</artifactId>
+      <version>1.0-RC2</version>
+    </dependency>
+    <dependency>
+      <groupId>net.sf.json-lib</groupId>
+      <artifactId>json-lib</artifactId>
+      <version>2.1</version>
+      <classifier>jdk15</classifier>
+    </dependency>
+    <dependency>
+      <groupId>commons-collections</groupId>
+      <artifactId>commons-collections</artifactId>
+      <version>3.2</version>
+    </dependency>
+
+    <!-- File upload -->
+    <dependency>
+      <groupId>commons-beanutils</groupId>
+      <artifactId>commons-beanutils</artifactId>
+      <version>1.7.0</version>
+    </dependency>
+    <dependency>
+      <groupId>commons-io</groupId>
+      <artifactId>commons-io</artifactId>
+      <version>1.2</version>
+    </dependency>
+    <dependency>
+      <groupId>commons-logging</groupId>
+      <artifactId>commons-logging</artifactId>
+      <version>1.1</version>
+    </dependency>
+    <dependency>
+      <groupId>commons-fileupload</groupId>
+      <artifactId>commons-fileupload</artifactId>
+      <version>1.1.1</version>
+    </dependency>
+
+    <!-- db upgrades -->
+    <dependency>
+      <groupId>org.liquibase</groupId>
+      <artifactId>liquibase-core</artifactId>
+      <version>1.7.0</version>
+    </dependency>
+    <dependency>
+      <groupId>org.liquibase</groupId>
+      <artifactId>liquibase-plugin</artifactId>
+      <version>1.7.0.0</version>
+    </dependency>
+
+    <!-- jetty dependencies -->
+    <dependency>
+      <groupId>org.mortbay.jetty</groupId>
+      <artifactId>jetty-util</artifactId>
+      <version>6.1.5</version>
+      <!--
+      <version>7.0.0.pre5</version>
+      -->
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.mortbay.jetty</groupId>
+      <artifactId>maven-jetty-plugin</artifactId>
+      <!--
+        <artifactId>jetty-maven-plugin</artifactId>
+        <version>7.0.0.1beta0</version>
+      -->
+      <version>6.1.5</version>
+      <scope>provided</scope>
+    </dependency>
+    <dependency>
+      <groupId>javax.servlet</groupId>
+      <artifactId>servlet-api</artifactId>
+      <version>2.4</version>
+      <scope>provided</scope>
+    </dependency>
+
+    <!-- testing dependencies -->
+    <dependency>
+      <groupId>org.mockito</groupId>
+      <artifactId>mockito-all</artifactId>
+      <version>1.6</version>
+    </dependency>
+    <dependency>
+      <groupId>com.h2database</groupId>
+      <artifactId>h2</artifactId>
+      <version>1.0.20070617</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>4.4</version>
+      <!--
+        <scope>test</scope>
+      -->
+    </dependency>
+    <dependency>
+      <groupId>org.openqa.selenium.client-drivers</groupId>
+      <artifactId>selenium-java-client-driver</artifactId>
+      <version>1.0-beta-1</version>
+      <scope>test</scope>
+    </dependency>
+
+    <!-- public side -->
+    <dependency>
+      <groupId>org.jruby.rack</groupId>
+      <artifactId>jruby-rack</artifactId>
+      <version>0.9.4</version>
+    </dependency>
+  </dependencies>
+  <!--
+    http://gwt-maven.googlecode.com/svn/docs/maven-googlewebtoolkit2-plugin/index.html
+  -->
+  <pluginRepositories>
+    <pluginRepository>
+      <id>gwt-maven</id>
+      <url>http://gwt-maven.googlecode.com/svn/trunk/mavenrepo</url>
+    </pluginRepository>
+    <pluginRepository>
+      <id>Codehaus Snapshots</id>
+      <url>http://snapshots.repository.codehaus.org/</url>
+      <snapshots>
+        <enabled>false</enabled>
+      </snapshots>
+      <releases>
+        <enabled>false</enabled>  <!-- Workaround for MNG-2974, see note below -->
+      </releases>
+    </pluginRepository>
+  </pluginRepositories>
+  <repositories>
+    <repository>
+      <id>Codehaus Snapshots</id>
+      <url>http://snapshots.repository.codehaus.org/</url>
+      <snapshots>
+        <enabled>true</enabled>
+      </snapshots>
+      <releases>
+        <enabled>false</enabled>
+      </releases>
+    </repository>
+    <repository>
+      <id>repository.jboss.org</id>
+      <name>JBoss Maven Repository</name>
+      <url>http://repository.jboss.org/maven2</url>
+      <layout>default</layout>
+    </repository>
+    <repository>
+      <id>dyndns-repo</id>
+      <url>http://maven.dyndns.org/2</url>
+    </repository>
+    <repository>
+      <id>gwt-maven</id>
+      <url>
+        http://gwt-maven.googlecode.com/svn/trunk/mavenrepo/
+      </url>
+    </repository>
+    <repository>
+      <id>kune-maven</id>
+      <url>http://kune.ourproject.org/mavenrepo/</url>
+    </repository>
+    <repository>
+      <id>gwtext</id>
+      <url>http://www.gwt-ext.com/maven2/</url>
+    </repository>
+    <repository>
+      <id>openqa.org</id>
+      <name>Openqa Release Repository</name>
+      <url>http://archiva.openqa.org/repository/releases</url>
+      <layout>default</layout>
+      <snapshots>
+        <enabled>false</enabled>
+      </snapshots>
+      <releases>
+        <enabled>true</enabled>
+      </releases>
+    </repository>
+    <repository>
+      <id>openqa.org</id>
+      <name>Openqa Snapshot Repository</name>
+      <url>http://archiva.openqa.org/repository/snapshots</url>
+      <layout>default</layout>
+      <snapshots>
+        <enabled>true</enabled>
+        <updatePolicy>daily</updatePolicy>
+        <checksumPolicy>ignore</checksumPolicy>
+      </snapshots>
+      <releases>
+        <enabled>false</enabled>
+      </releases>
+    </repository>
+    <repository>
+      <id>xwiki</id>
+      <name>XWiki Repository</name>
+      <url>http://maven.xwiki.org/snapshots</url>
+      <releases>
+        <enabled>true</enabled>
+      </releases>
+      <snapshots>
+        <enabled>true</enabled>
+        <updatePolicy>daily</updatePolicy>
+        <checksumPolicy>warn</checksumPolicy>
+      </snapshots>
+    </repository>
+  </repositories>
+  <issueManagement>
+    <system>kune issues list at ourproject.org</system>
+    <url>http://ourproject.org/tracker/?group_id=407</url>
+  </issueManagement>
+  <developers>
+    <developer>
+      <id>dani</id>
+      <name>Daniel Gómez Blasco</name>
+      <email>danigb at gmail.com</email>
+    </developer>
+    <developer>
+      <name>Samer Hassan</name>
+      <email>samer2004 at gmail.com</email>
+    </developer>
+    <developer>
+      <name>Vicente J. Ruiz Jurado</name>
+      <email>vjrj at ourproject.org</email>
+    </developer>
+  </developers>
+  <scm>
+    <url>svn://scm.ourproject.org/svnroot/kune/trunk</url>
+  </scm>
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <version>2.3</version>
+        <configuration>
+          <forkMode>pertest</forkMode>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <configuration>
+          <source>1.5</source>
+          <target>1.5</target>
+          <!--
+            Uncomment and run mvn with -X -e if we have same compile
+            problems <compilerArgument>-verbose</compilerArgument>
+            <fork>true</fork> <verbose>true</verbose>
+          -->
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>com.totsp.gwt</groupId>
+        <artifactId>maven-googlewebtoolkit2-plugin</artifactId>
+        <version>2.0-RC1</version>
+        <configuration>
+          <logLevel>INFO</logLevel>
+          <!-- <style>OBF or PRETTY</style> -->
+          <style>PRETTY</style>
+          <!--
+            <output>${project.build.directory}/gwt/www</output>
+          -->
+          <logLevel>INFO</logLevel>
+          <noServer>true</noServer>
+          <extraJvmArgs>-Xmx640m</extraJvmArgs>
+          <gwtVersion>${gwtVersion}</gwtVersion>
+          <output>war/</output>
+          <runTarget>ws/Kune.html</runTarget>
+          <compileTargets>
+            <compileTarget>org.ourproject.kune.app.Kune</compileTarget>
+          </compileTargets>
+          <generatorRootClasses>
+            <value>org.ourproject.kune.MyBean</value>
+          </generatorRootClasses>
+          <generatorDestinationPackage> org.ourproject.kune.app.Kune </generatorDestinationPackage>
+          <generateGettersAndSetters> true </generateGettersAndSetters>
+          <generatePropertyChangeSupport> true </generatePropertyChangeSupport>
+        </configuration>
+        <executions>
+          <execution>
+            <goals>
+              <!-- <goal>mergewebxml</goal> -->
+              <!-- <goal>compile</goal> -->
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-war-plugin</artifactId>
+        <version>2.0</version>
+        <configuration>
+          <webXml>${project.build.directory}/WEB-INF/web.xml</webXml>
+        </configuration>
+      </plugin>
+      <plugin>
+        <artifactId>maven-eclipse-plugin</artifactId>
+        <version>2.3</version>
+        <configuration>
+          <downloadSources>true</downloadSources>
+          <downloadJavadocs>true</downloadJavadocs>
+          <wtpversion>1.5</wtpversion>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.mortbay.jetty</groupId>
+        <artifactId>maven-jetty-plugin</artifactId>
+        <version>6.1.5</version>
+        <!--
+          <artifactId>jetty-maven-plugin</artifactId>
+          <version>7.0.0.1beta0</version>
+        -->
+        <configuration>
+          <contextPath>/</contextPath>
+          <webAppSourceDirectory>war</webAppSourceDirectory>
+          <reload>manual</reload>
+          <scanIntervalSeconds>0</scanIntervalSeconds>
+        </configuration>
+      </plugin>
+      <!--
+        <plugin> <groupId>org.codehaus.mojo</groupId>
+        <artifactId>deb-maven-plugin</artifactId>
+        <version>1.0-SNAPSHOT</version> <configuration>
+        <description>kune free/open/libre collaboration
+        platform</description> <maintainer>Kune Development Team
+        &lt;kune-devel at lists.ourproject.org&gt;</maintainer>
+        <section>web</section> <priority>optional</priority>
+        <architecture>all</architecture> </configuration> <executions>
+        <execution> <goals> <goal>deb</goal> </goals> </execution>
+        </executions> </plugin>
+      -->
+      <plugin>
+        <groupId>org.liquibase</groupId>
+        <artifactId>liquibase-plugin</artifactId>
+        <version>1.7.0.0</version>
+        <executions>
+          <execution>
+            <phase>process-resources</phase>
+            <configuration>
+              <changeLogFile>
+                src/main/resources/db/liquibase_changelog.xml </changeLogFile>
+              <driver>com.mysql.jdbc.Driver</driver>
+              <url>jdbc:mysql://localhost/kune_dev</url>
+              <username>kune</username>
+              <password>db4kune</password>
+              <verbose>true</verbose>
+            </configuration>
+            <!--
+              <configuration> <verbose>true</verbose> <propertiesFile>
+              src/main/resources/db/liquibase.properties
+              </propertiesFile> </configuration>
+            -->
+            <goals>
+              <goal>update</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-jar-plugin</artifactId>
+        <version>2.2</version>
+        <executions>
+          <execution>
+            <id>core</id>
+            <phase>package</phase>
+            <goals>
+              <goal>jar</goal>
+            </goals>
+            <configuration>
+              <classifier>core</classifier>
+              <includes>
+                <include>**/KunePlatform.gwt.xml**</include>
+                <include>**/i18n/I18nTranslationService.**</include>
+                <include>**/i18n/I18nTranslationServiceMocked.**</include>
+                <include>**/TextUtils.**</include>
+                <include>**/IconLabelEditable.**</include>
+                <include>**/QuickTipsHelper.**</include>
+                <include>**/RichText.gwt.xml**</include>
+                <include>**/BasicDialog.**</include>
+                <include>**/HorizontalLine.**</include>
+                <include>**/AbstractLabel.**</include>
+                <include>**/IconLabel.**</include>
+                <include> **/EditableIconLabel.** </include>
+                <include> **/EditableClickListener.** </include>
+                <include>**/KuneStringUtils.**</include>
+                <include>**/IconHyperlink*.**</include>
+                <include>**/LabelWrapper*.**</include>
+                <include>**/KuneUiUtils.**</include>
+                <include>**/View.**</include>
+                <!--
+                  <include>**/platf/**</include>
+                  <include>**/platf/client/extend/**</include>
+                  <include>**/platf/client/*java</include>
+                  <include>**/platf/client/app/**</include>
+                  <include>**/platf/client/dispatch/**</include>
+                -->
+              </includes>
+            </configuration>
+          </execution>
+          <execution>
+            <id>helloworldmodule</id>
+            <phase>package</phase>
+            <goals>
+              <goal>jar</goal>
+            </goals>
+            <configuration>
+              <classifier>helloworldmodule</classifier>
+              <includes>
+                <include>**/HelloWorld*</include>
+              </includes>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>selenium-maven-plugin</artifactId>
+        <configuration>
+          <port>4441</port>
+        </configuration>
+        <executions>
+          <execution>
+            <phase>pre-integration-test</phase>
+            <goals>
+              <goal>start-server</goal>
+            </goals>
+            <configuration>
+              <background>true</background>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <forkMode>pertest</forkMode>
+          <!--
+            Skip the normal tests, we'll run them in the
+            integration-test phase
+          -->
+          <skip>true</skip>
+        </configuration>
+        <executions>
+          <execution>
+            <phase>integration-test</phase>
+            <goals>
+              <goal>test</goal>
+            </goals>
+            <configuration>
+              <skip>false</skip>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+      <!--
+        <plugin> <artifactId>maven-clean-plugin</artifactId>
+        <version>2.2</version> <configuration> <filesets> <fileset>
+        <directory>src/main/webapp/gwt/</directory> <includes>
+        <include>**/org.ourproject.kune.app.Kune*</include>
+        <followSymlinks>false</followSymlinks> </includes> </fileset>
+        </filesets> </configuration> </plugin>
+      -->
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-dependency-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>unpack</id>
+            <phase>compile</phase>
+            <goals>
+              <goal>unpack</goal>
+            </goals>
+            <configuration>
+              <artifactItems>
+                <artifactItem>
+                  <groupId>com.google.gwt</groupId>
+                  <artifactId>gwt-dev</artifactId>
+                  <version>${gwtVersion}</version>
+                  <classifier>${platform}-libs</classifier>
+                  <type>zip</type>
+                  <overWrite>false</overWrite>
+                  <outputDirectory>${settings.localRepository}/com/google/gwt/gwt-dev/${gwtVersion}</outputDirectory>
+                </artifactItem>
+              </artifactItems>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+    <outputDirectory>war/WEB-INF/classes</outputDirectory>
+    <testOutputDirectory>war/WEB-INF/test-classes</testOutputDirectory>
+    <resources>
+      <resource>
+        <directory>src/main/resources</directory>
+      </resource>
+      <resource>
+        <directory>src/main/java</directory>
+      </resource>
+    </resources>
+  </build>
+  <reporting>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-jxr-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-pmd-plugin</artifactId>
+        <version>2.4</version>
+        <configuration>
+          <linkXref>true</linkXref>
+          <sourceEncoding>utf-8</sourceEncoding>
+          <minimumTokens>100</minimumTokens>
+          <targetJdk>1.5</targetJdk>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>cobertura-maven-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <systemProperties>
+            <property>
+              <name> net.sourceforge.cobertura.datafile </name>
+              <value>
+                ${project.reporting.directory}/cobertura/cobertura.ser </value>
+            </property>
+          </systemProperties>
+          <forkMode>pertest</forkMode>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>jdepend-maven-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>findbugs-maven-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </reporting>
+
+  <!--  profiles (with activation per platform) -->
+  <profiles>
+    <profile>
+      <id>gwt-dev-windows</id>
+      <properties>
+        <platform>windows</platform>
+      </properties>
+      <activation>
+        <activeByDefault>false</activeByDefault>
+        <os>
+          <family>windows</family>
+        </os>
+      </activation>
+      <!-- FIXME: put here a similar temp directory to linux/unix systems -->
+      <build>
+        <directory>target/</directory>
+      </build>
+      <reporting>
+        <outputDirectory>target/</outputDirectory>
+      </reporting>
+    </profile>
+    <profile>
+      <id>gwt-dev-mac</id>
+      <properties>
+        <platform>mac</platform>
+      </properties>
+      <activation>
+        <activeByDefault>false</activeByDefault>
+        <os>
+          <family>mac</family>
+        </os>
+      </activation>
+      <build>
+        <directory>/var/tmp/kune-target/</directory>
+      </build>
+      <reporting>
+        <outputDirectory>/var/tmp/kune-target/</outputDirectory>
+      </reporting>
+    </profile>
+    <profile>
+      <id>gwt-dev-linux</id>
+      <properties>
+        <platform>linux</platform>
+      </properties>
+      <activation>
+        <activeByDefault>true</activeByDefault>
+        <os>
+          <name>linux</name>
+        </os>
+      </activation>
+      <build>
+        <directory>/var/tmp/kune-target/</directory>
+      </build>
+      <reporting>
+        <outputDirectory>/var/tmp/kune-target/</outputDirectory>
+      </reporting>
+    </profile>
+  </profiles>
+</project>

Modified: trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/GroupManagerDefault.java
===================================================================
--- trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/GroupManagerDefault.java	2009-07-19 18:10:48 UTC (rev 1135)
+++ trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/GroupManagerDefault.java	2009-07-22 11:56:12 UTC (rev 1136)
@@ -30,6 +30,7 @@
 import org.apache.lucene.queryParser.MultiFieldQueryParser;
 import org.apache.lucene.queryParser.ParseException;
 import org.apache.lucene.search.Query;
+import org.hibernate.exception.ConstraintViolationException;
 import org.ourproject.kune.platf.client.dto.GroupType;
 import org.ourproject.kune.platf.client.errors.AccessViolationException;
 import org.ourproject.kune.platf.client.errors.DefaultException;
@@ -153,7 +154,7 @@
             initGroup(user, userGroup, wantPersonalHomepage ? serverToolRegistry.getToolsForUserKeys()
                     : ServerToolRegistry.emptyToolList);
             super.persist(user, User.class);
-        } catch (final EntityExistsException e) {
+        } catch (final ConstraintViolationException e) {
             throw new GroupNameInUseException();
         }
         return userGroup;

Modified: trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/UserManagerDefault.java
===================================================================
--- trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/UserManagerDefault.java	2009-07-19 18:10:48 UTC (rev 1135)
+++ trunk/src/main/java/org/ourproject/kune/platf/server/manager/impl/UserManagerDefault.java	2009-07-22 11:56:12 UTC (rev 1136)
@@ -43,6 +43,7 @@
 import org.ourproject.kune.platf.server.domain.User;
 import org.ourproject.kune.platf.server.manager.I18nCountryManager;
 import org.ourproject.kune.platf.server.manager.I18nLanguageManager;
+import org.ourproject.kune.platf.server.manager.PropertiesManager;
 import org.ourproject.kune.platf.server.manager.PropertyGroupManager;
 import org.ourproject.kune.platf.server.manager.UserManager;
 import org.ourproject.kune.platf.server.properties.ChatProperties;
@@ -62,12 +63,13 @@
     private final I18nTranslationService i18n;
     private final PropertyGroupManager propGroupManager;
     private PropertyGroup userPropGroup;
+    private final PropertiesManager propManager;
 
     @Inject
     public UserManagerDefault(final Provider<EntityManager> provider, final User finder,
             final I18nLanguageManager languageManager, final I18nCountryManager countryManager,
             final XmppManager xmppManager, final ChatProperties properties, final I18nTranslationService i18n,
-            final PropertyGroupManager propGroupManager) {
+            final PropertyGroupManager propGroupManager, final PropertiesManager propManager) {
         super(provider, User.class);
         this.finder = finder;
         this.languageManager = languageManager;
@@ -76,23 +78,29 @@
         this.properties = properties;
         this.i18n = i18n;
         this.propGroupManager = propGroupManager;
+        this.propManager = propManager;
     }
 
     public User createUser(final String shortName, final String longName, final String email, final String passwd,
             final String langCode, final String countryCode, final String timezone) throws I18nNotFoundException {
+        I18nLanguage language;
+        I18nCountry country;
+        TimeZone tz;
         try {
-            final I18nLanguage language = languageManager.findByCode(langCode);
-            final I18nCountry country = countryManager.findByCode(countryCode);
-            final TimeZone tz = TimeZone.getTimeZone(timezone);
-            if (userPropGroup == null) {
-                userPropGroup = propGroupManager.find(User.PROPS_ID);
-            }
-            final User user = new User(shortName, longName, email, passwd, language, country, tz, new Properties(
-                    userPropGroup));
-            return user;
+            language = languageManager.findByCode(langCode);
+            country = countryManager.findByCode(countryCode);
+            tz = TimeZone.getTimeZone(timezone);
         } catch (final NoResultException e) {
             throw new I18nNotFoundException();
         }
+        if (userPropGroup == null) {
+            userPropGroup = propGroupManager.find(User.PROPS_ID);
+        }
+        final Properties userProp = new Properties(userPropGroup);
+        propManager.persist(userProp);
+        final User user = new User(shortName, longName, email, passwd, language, country, tz, userProp);
+        return user;
+
     }
 
     @Override

Modified: trunk/src/test/java/org/ourproject/kune/platf/server/PersistencePreLoadedDataTest.java
===================================================================
--- trunk/src/test/java/org/ourproject/kune/platf/server/PersistencePreLoadedDataTest.java	2009-07-19 18:10:48 UTC (rev 1135)
+++ trunk/src/test/java/org/ourproject/kune/platf/server/PersistencePreLoadedDataTest.java	2009-07-22 11:56:12 UTC (rev 1136)
@@ -15,11 +15,13 @@
 import org.ourproject.kune.platf.server.domain.I18nCountry;
 import org.ourproject.kune.platf.server.domain.I18nLanguage;
 import org.ourproject.kune.platf.server.domain.License;
+import org.ourproject.kune.platf.server.domain.PropertyGroup;
 import org.ourproject.kune.platf.server.domain.User;
 import org.ourproject.kune.platf.server.manager.GroupManager;
 import org.ourproject.kune.platf.server.manager.I18nCountryManager;
 import org.ourproject.kune.platf.server.manager.I18nLanguageManager;
 import org.ourproject.kune.platf.server.manager.LicenseManager;
+import org.ourproject.kune.platf.server.manager.PropertyGroupManager;
 import org.ourproject.kune.platf.server.manager.UserManager;
 
 import com.google.inject.Inject;
@@ -50,6 +52,8 @@
     protected I18nLanguageManager languageManager;
     @Inject
     protected I18nCountryManager countryManager;
+    @Inject
+    protected PropertyGroupManager propGroupManager;
 
     protected User user;
     protected License defLicense;
@@ -77,6 +81,10 @@
         assertEquals(0, userFinder.getAll().size());
         assertEquals(0, groupFinder.getAll().size());
         assertEquals(0, licenseFinder.getAll().size());
+        final PropertyGroup groupProps = new PropertyGroup(Group.PROPS_ID);
+        final PropertyGroup userProps = new PropertyGroup(User.PROPS_ID);
+        propGroupManager.persist(userProps);
+        propGroupManager.persist(groupProps);
         english = new I18nLanguage(Long.valueOf(1819), "English", "English", "en");
         languageManager.persist(english);
         gb = new I18nCountry(Long.valueOf(75), "GB", "GBP", ".", "£%n", "", ".", "United Kingdom", "western", ",");

Modified: trunk/src/test/java/org/ourproject/kune/platf/server/manager/UserManagerTest.java
===================================================================
--- trunk/src/test/java/org/ourproject/kune/platf/server/manager/UserManagerTest.java	2009-07-19 18:10:48 UTC (rev 1135)
+++ trunk/src/test/java/org/ourproject/kune/platf/server/manager/UserManagerTest.java	2009-07-22 11:56:12 UTC (rev 1136)
@@ -6,7 +6,7 @@
 
 import java.util.TimeZone;
 
-import javax.persistence.EntityExistsException;
+import javax.persistence.PersistenceException;
 
 import org.apache.lucene.queryParser.ParseException;
 import org.hibernate.validator.InvalidStateException;
@@ -65,7 +65,7 @@
         persist(user);
     }
 
-    @Test(expected = EntityExistsException.class)
+    @Test(expected = PersistenceException.class)
     public void testUserExist() throws I18nNotFoundException {
         final User user1 = userManager.createUser("test", "test 1 name", "test1 at example.com", "some password", "en",
                 "GB", "GMT");

Modified: trunk/war/WEB-INF/lib/gwt-servlet.jar
===================================================================
(Binary files differ)




More information about the kune-commits mailing list