Skip to content

Commit

Permalink
new project structure for better extensions support.
Browse files Browse the repository at this point in the history
  • Loading branch information
aaberg committed Apr 3, 2014
1 parent 7cf7cdf commit 3af4553
Show file tree
Hide file tree
Showing 89 changed files with 283 additions and 152 deletions.
174 changes: 174 additions & 0 deletions core/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,174 @@
<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>org.sql2o</groupId>
<artifactId>sql2o</artifactId>
<packaging>jar</packaging>
<version>1.4.1-SNAPSHOT</version>
<name>sql2o</name>
<description>Easy database query library</description>
<url>http://www.sql2o.org</url>
<licenses>
<license>
<name>MIT</name>
<url>http://www.opensource.org/licenses/MIT</url>
<distribution>repo</distribution>
</license>
</licenses>
<parent>
<groupId>org.sql2o</groupId>
<artifactId>sql2o-parent</artifactId>
<version>1.4.1-SNAPSHOT</version>
</parent>
<developers>
<developer>
<email>lars@aaberg.cc</email>
<id>aaberg</id>
<name>Lars Aaberg</name>
<url>https://github.com/aaberg/</url>
</developer>
<developer>
<email>aldenquimby@gmail.com</email>
<id>aldenquimby</id>
<name>Alden Quimby</name>
<url>https://github.com/aldenquimby</url>
</developer>
</developers>

<dependencies>

<!-- optional dependencies -->
<dependency>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
<version>1.6.2</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.6.4</version>
<optional>true</optional>
</dependency>

<!-- databases for verification -->
<dependency>
<scope>test</scope>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<version>1.3.160</version>
</dependency>
<dependency>
<scope>test</scope>
<groupId>org.hsqldb</groupId>
<artifactId>hsqldb</artifactId>
<version>2.2.8</version>
</dependency>
<dependency>
<scope>test</scope>
<groupId>postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>9.1-901.jdbc4</version>
</dependency>
<!-- Uncomment to run oracle tests. -->
<!--
<dependency>
<scope>test</scope>
<groupId>com.oracle</groupId>
<artifactId>ojdbc6</artifactId>
<version>11.2.0.3</version>
</dependency>
-->
<!-- other ORMs for performance testing -->
<dependency>
<scope>test</scope>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-core</artifactId>
<version>4.3.1.Final</version>
</dependency>
<dependency>
<scope>test</scope>
<groupId>org.jdbi</groupId>
<artifactId>jdbi</artifactId>
<version>2.53</version>
</dependency>
<dependency>
<scope>test</scope>
<groupId>org.jooq</groupId>
<artifactId>jooq</artifactId>
<version>3.3.0</version>
</dependency>
<dependency>
<scope>test</scope>
<groupId>commons-dbutils</groupId>
<artifactId>commons-dbutils</artifactId>
<version>1.5</version>
</dependency>
<dependency>
<scope>test</scope>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.2.4</version>
</dependency>
<dependency>
<scope>test</scope>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<version>4.0.2.RELEASE</version>
</dependency>


</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.2.1</version>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
<testSource>1.5</testSource>
<testTarget>1.5</testTarget>
</configuration>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.2.1</version>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.9</version>
<executions>
<execution>
<id>attach-javadoc</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<stylesheet>java</stylesheet>
</configuration>
</plugin>
</plugins>
</build>
</project>
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
26 changes: 26 additions & 0 deletions extensions/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<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>org.sql2o.extensions</groupId>
<artifactId>extensions-parent</artifactId>
<name>Sql2o - Extensions</name>
<packaging>pom</packaging>

<parent>
<groupId>org.sql2o</groupId>
<artifactId>sql2o-parent</artifactId>
<version>1.4.1-SNAPSHOT</version>
</parent>

<modules>
<module>postgres</module>
</modules>

<dependencies>
<!-- All dependencies depends on sql2o core project -->
<dependency>
<groupId>org.sql2o</groupId>
<artifactId>sql2o</artifactId>
<version>1.4.1-SNAPSHOT</version>
</dependency>
</dependencies>
</project>
13 changes: 13 additions & 0 deletions extensions/postgres/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<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>
<artifactId>sql2o-postgres</artifactId>
<packaging>jar</packaging>
<name>sql2o-postgres</name>
<description>Postgres extension for sql2o</description>
<url>http://www.sql2o.org</url>
<parent>
<groupId>org.sql2o.extensions</groupId>
<artifactId>extensions-parent</artifactId>
<version>1.4.1-SNAPSHOT</version>
</parent>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package org.sql2o.extensions.postgres;

/**
* Created by lars on 03.04.14.
*
* Created the class as a placeholder. Should be deleted when actual functionality is added.
*/
public class Dummy {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
package org.sql2o.extensions.postgres;

import org.hamcrest.CoreMatchers;
import org.hamcrest.MatcherAssert;
import org.junit.Test;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import static org.hamcrest.CoreMatchers.*;
import static org.hamcrest.MatcherAssert.*;

/**
* Created by lars on 03.04.14.
*
* Created the class as a placeholder. Should be deleted when actual functionality is added.
*/
public class DummyTest {

Logger logger = LoggerFactory.getLogger(DummyTest.class);

@Test
public void testSomething(){
String awesome = "awesome";
String postgres = "awesome";

assertThat(postgres, is(awesome));
logger.info("postgres is {}", awesome);
}
}
Loading

0 comments on commit 3af4553

Please sign in to comment.