+++ /dev/null
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- ~ Copyright 2011 GRNET S.A. All rights reserved.
- ~
- ~ Redistribution and use in source and binary forms, with or
- ~ without modification, are permitted provided that the following
- ~ conditions are met:
- ~
- ~ 1. Redistributions of source code must retain the above
- ~ copyright notice, this list of conditions and the following
- ~ disclaimer.
- ~
- ~ 2. Redistributions in binary form must reproduce the above
- ~ copyright notice, this list of conditions and the following
- ~ disclaimer in the documentation and/or other materials
- ~ provided with the distribution.
- ~
- ~ THIS SOFTWARE IS PROVIDED BY GRNET S.A. ``AS IS'' AND ANY EXPRESS
- ~ OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- ~ WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- ~ PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GRNET S.A OR
- ~ CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- ~ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- ~ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- ~ USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- ~ AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- ~ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
- ~ ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- ~ POSSIBILITY OF SUCH DAMAGE.
- ~
- ~ The views and conclusions contained in the software and
- ~ documentation are those of the authors and should not be
- ~ interpreted as representing official policies, either expressed
- ~ or implied, of GRNET S.A.
- -->
-
-<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>
-
- <parent>
- <artifactId>aquarium</artifactId>
- <groupId>gr.grnet</groupId>
- <version>0.0.2-SNAPSHOT</version>
- </parent>
-
- <groupId>gr.grnet.aquarium</groupId>
- <artifactId>logic</artifactId>
- <version>0.0.2-SNAPSHOT</version>
- <name>Aquarium Business Logic</name>
-
- <repositories>
- <repository>
- <id>Sonatype-public</id>
- <name>SnakeYAML repository</name>
- <url>http://oss.sonatype.org/content/groups/public/</url>
- </repository>
-
- <repository>
- <id>sonatype-nexus-snapshots</id>
- <name>Sonatype Nexus Snapshots</name>
- <url>http://oss.sonatype.org/content/repositories/snapshots</url>
- </repository>
-
- <repository>
- <id>java-crontab-syntax-parser-repo</id>
- <name>Java CronTab Syntax Parser</name>
- <url>
- http://kenai.com/projects/crontab-parser/sources/maven-repo/content/
- </url>
- </repository>
-
- <repository>
- <id>akka</id>
- <name>Akka</name>
- <url>http://akka.io/repository/</url>
- </repository>
-
- <repository>
- <id>typesafe-releases</id>
- <name>Typesafe releases</name>
- <url>http://repo.typesafe.com/typesafe/releases</url>
- </repository>
-
- <repository>
- <id>twitter</id>
- <name>Twitter</name>
- <url>http://maven.twttr.com</url>
- </repository>
-
- <repository>
- <id>scala-tools-snapshots</id>
- <name>Scala-Tools Dependencies Repository for Releases</name>
- <url>http://scala-tools.org/repo-snapshots</url>
- </repository>
- </repositories>
-
- <dependencies>
- <dependency>
- <groupId>gr.grnet.aquarium</groupId>
- <artifactId>shared</artifactId>
- <version>0.0.2-SNAPSHOT</version>
- <classifier>resources</classifier>
- <type>zip</type>
- <scope>provided</scope>
- </dependency>
-
- <dependency>
- <groupId>net.liftweb</groupId>
- <artifactId>lift-json_2.9.1</artifactId>
- <version>2.4-M5</version>
- </dependency>
-
- <dependency>
- <groupId>net.liftweb</groupId>
- <artifactId>lift-json-ext_2.9.1</artifactId>
- <version>2.4-M5</version>
- </dependency>
-
- <dependency>
- <groupId>org.yaml</groupId>
- <artifactId>snakeyaml</artifactId>
- <version>1.9</version>
- </dependency>
-
- <dependency>
- <groupId>com.kenai.crontab-parser</groupId>
- <artifactId>crontab-parser</artifactId>
- <version>1.0.1</version>
- </dependency>
-
- <dependency>
- <groupId>com.rabbitmq</groupId>
- <artifactId>amqp-client</artifactId>
- <version>2.5.0</version>
- </dependency>
-
- <dependency>
- <groupId>com.ckkloverdos</groupId>
- <artifactId>streamresource_2.9.1</artifactId>
- <version>0.2.0</version>
- </dependency>
-
- <dependency>
- <groupId>com.thoughtworks.xstream</groupId>
- <artifactId>xstream</artifactId>
- <version>1.4.1</version>
- </dependency>
-
- <dependency>
- <groupId>org.mongodb</groupId>
- <artifactId>mongo-java-driver</artifactId>
- <version>2.7.2</version>
- </dependency>
-
- <dependency>
- <groupId>se.scalablesolutions.akka</groupId>
- <artifactId>akka-actor</artifactId>
- <version>1.3-RC4</version>
- </dependency>
-
- <dependency>
- <groupId>se.scalablesolutions.akka</groupId>
- <artifactId>akka-remote</artifactId>
- <version>1.3-RC4</version>
- </dependency>
-
- <dependency>
- <groupId>se.scalablesolutions.akka</groupId>
- <artifactId>akka-amqp</artifactId>
- <version>1.3-RC4</version>
- </dependency>
-
- <dependency>
- <groupId>se.scalablesolutions.akka</groupId>
- <artifactId>akka-slf4j</artifactId>
- <version>1.3-RC4</version>
- </dependency>
-
- <dependency>
- <groupId>se.scalablesolutions.akka</groupId>
- <artifactId>akka-testkit</artifactId>
- <version>1.3-RC4</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>javax.ws.rs</groupId>
- <artifactId>jsr311-api</artifactId>
- <version>1.1.1</version>
- </dependency>
-
- <dependency>
- <groupId>cc.spray.can</groupId>
- <artifactId>spray-can</artifactId>
- <version>0.9.2-SNAPSHOT</version>
- </dependency>
-
- <!-- <dependency>
- <groupId>com.yammer.metrics</groupId>
- <artifactId>metrics-core</artifactId>
- <version>2.0.0-BETA18-SNAPSHOT</version>
- </dependency>-->
-
- <dependency>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-core</artifactId>
- <version>3.5.0</version>
- </dependency>
-
- <dependency>
- <groupId>org.apache.solr</groupId>
- <artifactId>solr-core</artifactId>
- <version>3.5.0</version>
- <exclusions>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-analyzers</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-highlighter</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-memory</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-misc</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-queries</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-spatial</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-spellchecker</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.lucene</groupId>
- <artifactId>lucene-grouping</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.solr</groupId>
- <artifactId>solr-commons-csv</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.solr</groupId>
- <artifactId>solr-noggit</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.apache.solr</groupId>
- <artifactId>solr-solrj</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>commons-fileupload</groupId>
- <artifactId>commons-fileupload</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>commons-httpclient</groupId>
- <artifactId>commons-httpclient</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>org.slf4j</groupId>
- <artifactId>jcl-over-slf4j</artifactId>
- </exclusion>
-
- <exclusion>
- <groupId>javax.servlet</groupId>
- <artifactId>servlet-api</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
- </dependencies>
-
- <build>
- <plugins>
- <plugin>
- <artifactId>maven-assembly-plugin</artifactId>
- <version>2.2.2</version>
- <configuration>
- <archive>
- <manifest>
- <mainClass>gr.grnet.aquarium.Main</mainClass>
- </manifest>
- </archive>
- <descriptorRefs>
- <descriptorRef>jar-with-dependencies</descriptorRef>
- </descriptorRefs>
- </configuration>
- <executions>
- <execution>
- <id>make-assembly</id>
- <!-- this is used for inheritance merges -->
- <phase>package</phase>
- <!-- bind to the packaging phase -->
- <goals>
- <goal>single</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
-</project>
+++ /dev/null
-version = 0.0.2-SNAPSHOT
-
-### Queue related settings
-# Comma separated list of amqp servers to use. The servers must be in an
-# active-active mode.
-amqp.servers=localhost
-
-# Comma separated list of amqp servers to use. The servers must be in an
-# active-active mode.
-amqp.port=5672
-
-# User name for connecting with the AMQP server
-amqp.username=aquarium
-
-# Passwd for connecting with the AMQP server
-amqp.passwd=aquarium
-
-# Virtual host on the AMQP server
-amqp.vhost=/
-
-# REST service listening port
-rest.port=8080
-
-### Message store related settings
-# Provider for persistence services.
-# Currently one of: mongo
-persistence.provider=mongodb
-
-# Hostname for the persistence service
-persistence.host=localhost
-
-# Port for connecting to the persistence service
-persistence.port=27017
-
-# Username for connecting to the persistence service
-persistence.username=aquarium
-
-# Password for connecting to the persistence service
-persistence.password=aquarium
-
-#######
-# DO NOT TOUCH the following options, unless you know what you are doing
-#######
-
-# Actor subsystem
-actor.provider.class=gr.grnet.aquarium.actor.SimpleLocalActorProvider
-# Class that initializes the REST service
-rest.service.class=gr.grnet.aquarium.rest.actor.RESTActorService
-# Store subsystem
-store.provider.class=gr.grnet.aquarium.store.mongodb.MongoDBStoreProvider
-# Override the user store (if present, it will not be given by the store provider above)
-#user.store.class=gr.grnet.aquarium.store.memory.MemUserStore
-# Override the event store (if present, it will not be given by the store provider above)
-#event.store.class=
-# Override the IM event store (if present, it will not be given by the store provider above)
-#imevent.store.class=
-# Override the Wallet store (if present, it will not be given by the store provider above)
-#wallet.store.class=
-
-
-# The lower mark for the UserActors' LRU, managed by UserActorManager.
-user.actor.LRU.lower.mark=800
-# The upper mark for the UserActors' LRU, managed by UserActorManager.
-user.actors.LRU.upper.mark=1000
-
-# Comma separated list of exchanges known to aquarium
-amqp.exchanges=aquarium
-
-# The name of the DB schema to use
-persistence.db=aquarium
\ No newline at end of file
~ or implied, of GRNET S.A.
-->
-<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/xsd/maven-4.0.0.xsd">
+<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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>gr.grnet</groupId>
<artifactId>aquarium</artifactId>
<version>0.0.2-SNAPSHOT</version>
- <packaging>pom</packaging>
<!-- Project details-->
<name>Aquarium</name>
<url>http://download.java.net/maven/2/</url>
</repository>
<repository>
- <id>EclipseLink Repo</id>
- <url>http://www.eclipse.org/downloads/download.php?r=1&nf=1&file=/rt/eclipselink/maven.repo</url>
- </repository>
- <repository>
<name>JBoss</name>
<id>jboss</id>
<url>http://repository.jboss.org/nexus/content/groups/public/</url>
<artifactId>slf4j-log4j12</artifactId>
<version>1.6.3</version>
</dependency>
+ <dependency>
+ <groupId>net.liftweb</groupId>
+ <artifactId>lift-json_2.9.1</artifactId>
+ <version>2.4-M5</version>
+ </dependency>
+
+ <dependency>
+ <groupId>net.liftweb</groupId>
+ <artifactId>lift-json-ext_2.9.1</artifactId>
+ <version>2.4-M5</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.yaml</groupId>
+ <artifactId>snakeyaml</artifactId>
+ <version>1.9</version>
+ </dependency>
+
+ <dependency>
+ <groupId>com.kenai.crontab-parser</groupId>
+ <artifactId>crontab-parser</artifactId>
+ <version>1.0.1</version>
+ </dependency>
+
+ <dependency>
+ <groupId>com.rabbitmq</groupId>
+ <artifactId>amqp-client</artifactId>
+ <version>2.5.0</version>
+ </dependency>
+
+ <dependency>
+ <groupId>com.ckkloverdos</groupId>
+ <artifactId>streamresource_2.9.1</artifactId>
+ <version>0.2.0</version>
+ </dependency>
+
+ <dependency>
+ <groupId>com.thoughtworks.xstream</groupId>
+ <artifactId>xstream</artifactId>
+ <version>1.4.1</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.mongodb</groupId>
+ <artifactId>mongo-java-driver</artifactId>
+ <version>2.7.2</version>
+ </dependency>
+
+ <dependency>
+ <groupId>se.scalablesolutions.akka</groupId>
+ <artifactId>akka-actor</artifactId>
+ <version>1.3-RC4</version>
+ </dependency>
+
+ <dependency>
+ <groupId>se.scalablesolutions.akka</groupId>
+ <artifactId>akka-remote</artifactId>
+ <version>1.3-RC4</version>
+ </dependency>
+
+ <dependency>
+ <groupId>se.scalablesolutions.akka</groupId>
+ <artifactId>akka-amqp</artifactId>
+ <version>1.3-RC4</version>
+ </dependency>
+
+ <dependency>
+ <groupId>se.scalablesolutions.akka</groupId>
+ <artifactId>akka-slf4j</artifactId>
+ <version>1.3-RC4</version>
+ </dependency>
+
+ <dependency>
+ <groupId>se.scalablesolutions.akka</groupId>
+ <artifactId>akka-testkit</artifactId>
+ <version>1.3-RC4</version>
+ <scope>test</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>javax.ws.rs</groupId>
+ <artifactId>jsr311-api</artifactId>
+ <version>1.1.1</version>
+ </dependency>
+
+ <dependency>
+ <groupId>cc.spray.can</groupId>
+ <artifactId>spray-can</artifactId>
+ <version>0.9.2-SNAPSHOT</version>
+ </dependency>
+
+ <!-- <dependency>
+ <groupId>com.yammer.metrics</groupId>
+ <artifactId>metrics-core</artifactId>
+ <version>2.0.0-BETA18-SNAPSHOT</version>
+ </dependency>-->
+
+ <dependency>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-core</artifactId>
+ <version>3.5.0</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.solr</groupId>
+ <artifactId>solr-core</artifactId>
+ <version>3.5.0</version>
+ <exclusions>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-analyzers</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-highlighter</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-memory</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-misc</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-queries</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-spatial</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-spellchecker</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.lucene</groupId>
+ <artifactId>lucene-grouping</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.solr</groupId>
+ <artifactId>solr-commons-csv</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.solr</groupId>
+ <artifactId>solr-noggit</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.apache.solr</groupId>
+ <artifactId>solr-solrj</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>commons-fileupload</groupId>
+ <artifactId>commons-fileupload</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>commons-httpclient</groupId>
+ <artifactId>commons-httpclient</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl-over-slf4j</artifactId>
+ </exclusion>
+
+ <exclusion>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
</dependencies>
- <!--Configuration shared with subprojects-->
+ <!--Build configuration-->
<build>
<sourceDirectory>src/main/scala</sourceDirectory>
<testSourceDirectory>src/test/scala</testSourceDirectory>
</execution>
</executions>
</plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <version>2.5</version>
- <executions>
- <execution>
- <id>default-copy-resources</id>
- <phase>process-resources</phase>
- <goals>
- <goal>copy-resources</goal>
- </goals>
- <configuration>
- <overwrite>true</overwrite>
- <outputDirectory>${project.build.directory}</outputDirectory>
- <resources>
- <resource>
- <directory>${project.basedir}/src</directory>
- <includes>
- <include>packageLinkDefs.properties</include>
- </includes>
- <filtering>true</filtering>
- </resource>
- </resources>
- </configuration>
- </execution>
- </executions>
- </plugin>
<!-- Redmine maven plugin -->
<plugin>
<groupId>org.nuiton.jredmine</groupId>
<reportFormat>plain</reportFormat>
</configuration>
</plugin>
- <!-- Shared resources -->
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-dependency-plugin</artifactId>
- <executions>
- <execution>
- <id>unpack-shared-resources</id>
- <goals>
- <goal>unpack-dependencies</goal>
- </goals>
- <phase>generate-resources</phase>
- <configuration>
- <outputDirectory>${project.build.directory}/generated-resources
- </outputDirectory>
- <includeArtifactIds>shared</includeArtifactIds>
- <includeGroupIds>gr.grnet.aquarium</includeGroupIds>
- <excludeTransitive>true</excludeTransitive>
- </configuration>
- </execution>
- </executions>
- </plugin>
<!-- Bundle up source code on release/snapshot -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<preparationGoals>clean verify</preparationGoals>
</configuration>
</plugin>
+ <!--Build an executable jar with all dependencies-->
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <version>2.2.2</version>
+ <configuration>
+ <archive>
+ <manifest>
+ <mainClass>gr.grnet.aquarium.Main</mainClass>
+ </manifest>
+ </archive>
+ <descriptorRefs>
+ <descriptorRef>jar-with-dependencies</descriptorRef>
+ </descriptorRefs>
+ </configuration>
+ <executions>
+ <execution>
+ <id>make-assembly</id>
+ <phase>package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+
</plugins>
</build>
- <!--Sub projects-->
- <modules>
- <module>logic</module>
- <module>shared</module>
- </modules>
</project>
+++ /dev/null
-<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>
-
- <parent>
- <groupId>gr.grnet</groupId>
- <artifactId>aquarium</artifactId>
- <version>0.0.2-SNAPSHOT</version>
- </parent>
-
- <groupId>gr.grnet.aquarium</groupId>
- <artifactId>shared</artifactId>
- <version>0.0.2-SNAPSHOT</version>
-
- <packaging>pom</packaging>
- <name>Aquarium Shared Resources</name>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-assembly-plugin</artifactId>
- <executions>
- <execution>
- <id>make shared resources</id>
- <goals>
- <goal>single</goal>
- </goals>
- <phase>package</phase>
- <configuration>
- <descriptors>
- <descriptor>src/main/assembly/resources.xml</descriptor>
- </descriptors>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- <profiles>
- <profile>
- <id>exporttestdbmysql</id>
- <activation>
- <activeByDefault>false</activeByDefault>
- <property>
- <name>export</name>
- <value>1</value>
- </property>
- </activation>
- <build>
- <plugins>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>dbunit-maven-plugin</artifactId>
- <version>1.0-beta-3</version>
- <dependencies>
- <dependency>
- <groupId>mysql</groupId>
- <artifactId>mysql-connector-java</artifactId>
- <version>5.1.17</version>
- </dependency>
- </dependencies>
- <configuration>
- <driver>com.mysql.jdbc.Driver</driver>
- <url>jdbc:mysql://localhost/aquarium</url>
- <username>aquarium</username>
- <password>aquarium</password>
- <ordered>true</ordered>
- <format>flat</format>
- <dest>target/dbunit/export.xml</dest>
- </configuration>
- <executions>
- <execution>
- <phase>test</phase>
- <goals>
- <goal>export</goal>
- </goals>
- <!-- specific configurations -->
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- </profile>
- </profiles>
-
-</project>
-
+++ /dev/null
-<assembly>
- <id>resources</id>
- <formats>
- <format>zip</format>
- </formats>
- <includeBaseDirectory>false</includeBaseDirectory>
- <fileSets>
- <fileSet>
- <directory>src/main/resources</directory>
- <outputDirectory></outputDirectory>
- </fileSet>
- </fileSets>
-</assembly>
+++ /dev/null
-<persistence xmlns="http://java.sun.com/xml/ns/persistence"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
- http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
- version="1.0">
-
- <persistence-unit name="aquarium" transaction-type="RESOURCE_LOCAL">
-
- <class>gr.grnet.aquarium.model.Entity</class>
- <class>gr.grnet.aquarium.model.Group</class>
- <class>gr.grnet.aquarium.model.User</class>
- <class>gr.grnet.aquarium.model.Organization</class>
- <class>gr.grnet.aquarium.model.ServiceItem</class>
- <class>gr.grnet.aquarium.model.RuntimeData</class>
- <class>gr.grnet.aquarium.model.Bill</class>
- <class>gr.grnet.aquarium.model.Action</class>
- <class>gr.grnet.aquarium.model.DefaultPermission</class>
- <class>gr.grnet.aquarium.model.Permission</class>
- <class>gr.grnet.aquarium.model.ServiceTemplate</class>
- <class>gr.grnet.aquarium.model.ResourceType</class>
- <class>gr.grnet.aquarium.model.EntityType</class>
- <class>gr.grnet.aquarium.model.Agreement</class>
- <class>gr.grnet.aquarium.model.PriceList</class>
-
- <properties>
-
- <!-- Common configuration -->
- <property name="javax.persistence.jdbc.driver"
- value="com.mysql.jdbc.Driver"/>
- <property name="javax.persistence.jdbc.url"
- value="jdbc:mysql://localhost/aquarium"/>
- <property name="javax.persistence.jdbc.password" value="aquarium"/>
- <property name="javax.persistence.jdbc.user" value="aquarium"/>
-
- <!-- EclipseLink configuration -->
- <property name="eclipselink.target-database"
- value="org.eclipse.persistence.platform.database.MySQLPlatform"/>
- <property name="eclipselink.logging.level" value="FINE"/>
- <property name="eclipselink.logging.timestamp" value="false"/>
- <property name="eclipselink.logging.session" value="false"/>
- <property name="eclipselink.logging.thread" value="false"/>
- <property name="eclipselink.logging.level.sql" value="FINEST"/>
- <property name="eclipselink.ddl-generation" value="create-tables"/>
- <property name="eclipselink.ddl-generation.output-mode" value="database"/>
-
- <!-- Hibernate configuration -->
- <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/>
- <property name="hibernate.hbm2ddl.auto" value="update"/>
- <property name="hibernate.show_sql" value="true"/>
-
- <!-- OpenJPA configuration -->
- <property name="openjpa.jdbc.DBDictionary" value="mysql"/>
- <property name="openjpa.Log" value="DefaultLevel=TRACE, SQL=TRACE"/>
- <property name="openjpa.jdbc.SynchronizeMappings" value="buildSchema(ForeignKeys=true)"/>
-
- </properties>
- </persistence-unit>
-
- <persistence-unit name="aquarium-test" transaction-type="RESOURCE_LOCAL">
-
- <class>gr.grnet.aquarium.model.Entity</class>
- <class>gr.grnet.aquarium.model.Group</class>
- <class>gr.grnet.aquarium.model.User</class>
- <class>gr.grnet.aquarium.model.Organization</class>
- <class>gr.grnet.aquarium.model.ServiceItem</class>
- <class>gr.grnet.aquarium.model.RuntimeData</class>
- <class>gr.grnet.aquarium.model.Bill</class>
- <class>gr.grnet.aquarium.model.Action</class>
- <class>gr.grnet.aquarium.model.DefaultPermission</class>
- <class>gr.grnet.aquarium.model.Permission</class>
- <class>gr.grnet.aquarium.model.ServiceTemplate</class>
- <class>gr.grnet.aquarium.model.ResourceType</class>
- <class>gr.grnet.aquarium.model.EntityType</class>
- <class>gr.grnet.aquarium.model.Agreement</class>
- <class>gr.grnet.aquarium.model.PriceList</class>
-
- <properties>
-
- <!-- Common configuration -->
- <property name="javax.persistence.jdbc.driver"
- value="org.h2.Driver"/>
- <property name="javax.persistence.jdbc.url"
- value="jdbc:h2:aquarium-test"/>
- <property name="javax.persistence.jdbc.password" value=""/>
- <property name="javax.persistence.jdbc.user" value=""/>
-
- <!-- EclipseLink configuration -->
- <property name="eclipselink.target-database"
- value="org.eclipse.persistence.platform.database.H2Platform"/>
- <property name="eclipselink.logging.level" value="FINE"/>
- <property name="eclipselink.logging.timestamp" value="false"/>
- <property name="eclipselink.logging.session" value="false"/>
- <property name="eclipselink.logging.thread" value="false"/>
- <property name="eclipselink.logging.level.sql" value="FINEST"/>
- <property name="eclipselink.ddl-generation" value="create-tables"/>
- <property name="eclipselink.ddl-generation.output-mode" value="database"/>
-
- <!-- Hibernate configuration -->
- <property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect"/>
- <property name="hibernate.hbm2ddl.auto" value="update"/>
- <property name="hibernate.show_sql" value="true"/>
-
- <!-- OpenJPA configuration -->
- <property name="openjpa.jdbc.DBDictionary" value="org.apache.openjpa.jdbc.sql.H2Dictionary"/>
- <property name="openjpa.Log" value="DefaultLevel=TRACE, SQL=TRACE"/>
- <property name="openjpa.jdbc.SynchronizeMappings" value="buildSchema(ForeignKeys=true)"/>
-
- </properties>
- </persistence-unit>
-</persistence>
\ No newline at end of file
+++ /dev/null
-The resources in this directory are copied to all generated jars.
\ No newline at end of file
--- /dev/null
+package gr.grnet.aquarium.store.mongodb
+
+import gr.grnet.aquarium.util.{RandomEventGenerator, TestMethods}
+import gr.grnet.aquarium.MasterConf._
+import org.junit.Assume._
+import gr.grnet.aquarium.LogicTestsAssumptions
+import org.junit.{After, Test}
+
+/**
+ *
+ * @author Georgios Gousios <gousiosg@gmail.com>
+ */
+class IMStoreTest extends TestMethods with RandomEventGenerator {
+
+ @Test
+ def testStoreEvent() = {
+ assumeTrue(LogicTestsAssumptions.EnableStoreTests)
+
+ val event = nextUserEvent()
+ val store = MasterConf.IMStore
+ val result = store.storeUserEvent(event)
+
+ assert(result.isJust)
+ }
+
+ @Test
+ def testfindUserEventById() = {
+
+ }
+
+ @After
+ def after() = {
+ val a = getMongo
+
+ val col = a.mongo.getDB(MasterConf.get(Keys.persistence_db)
+ ).getCollection(MongoDBStore.EVENTS_COLLECTION)
+
+ val res = col.find
+ while (res.hasNext)
+ col.remove(res.next)
+ }
+
+ private def getMongo = MasterConf.IMStore.asInstanceOf[MongoDBStore]
+}
\ No newline at end of file