Skip to content

Commit

Permalink
[POC-4] modules reorganized
Browse files Browse the repository at this point in the history
  • Loading branch information
apfadler committed Jun 6, 2016
1 parent 5b3958e commit a9c8530
Show file tree
Hide file tree
Showing 35 changed files with 559 additions and 179 deletions.
244 changes: 244 additions & 0 deletions common/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,244 @@
<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.quil</groupId>
<artifactId>common</artifactId>
<packaging>jar</packaging>
<version>0.1-SNAPSHOT</version>
<name>common</name>
<url>http://maven.apache.org</url>

<properties>
<ignite.version>1.5.0.final</ignite.version>
</properties>

<repositories>
<repository>
<id>scala-tools.org</id>
<name>Scala-tools Maven2 Repository</name>
<url>http://scala-tools.org/repo-releases</url>
</repository>
<repository>
<id>quil-dev</id>
<name>Quil Maven Repository</name>
<url>https://github.com/apfadler/quil-maven/raw/master/</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>scala-tools.org</id>
<name>Scala-tools Maven2 Repository</name>
<url>http://scala-tools.org/repo-releases</url>
</pluginRepository>
</pluginRepositories>

<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.7</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.13</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.7.13</version>
</dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>
<dependency>
<groupId>org.apache.ignite</groupId>
<artifactId>ignite-core</artifactId>
<version>${ignite.version}</version>
</dependency>
<dependency>
<groupId>org.apache.ignite</groupId>
<artifactId>ignite-spring</artifactId>
<version>${ignite.version}</version>
</dependency>
<dependency>
<groupId>org.apache.ignite</groupId>
<artifactId>ignite-indexing</artifactId>
<version>${ignite.version}</version>
</dependency>
<dependency>
<groupId>org.apache.ignite</groupId>
<artifactId>ignite-aws</artifactId>
<version>${ignite.version}</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.4</version>
</dependency>
<dependency>
<groupId>com.googlecode.json-simple</groupId>
<artifactId>json-simple</artifactId>
<version>1.1.1</version>
</dependency>
<dependency>
<groupId>org.scala-lang</groupId>
<artifactId>scala-library</artifactId>
<version>2.11.7</version>
</dependency>
<dependency>
<groupId>org.scala-lang</groupId>
<artifactId>scala-compiler</artifactId>
<version>2.11.7</version>
</dependency>
<dependency>
<groupId>org.quil</groupId>
<artifactId>quantlib</artifactId>
<version>1.7</version>
</dependency>

<dependency>
<groupId>io.spray</groupId>
<artifactId>spray-json_2.10</artifactId>
<version>1.3.2</version>
</dependency>

</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<configuration>
<encoding>${project.build.sourceEncoding}</encoding>
</configuration>
<executions>
<execution>
<goals>
<goal>copy-resources</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<recompileMode>incremental</recompileMode>
<!-- <args> <arg>-target:jvm-1.7</arg> </args> -->
<javacArgs>
<javacArg>-source</javacArg>
<javacArg>1.7</javacArg>
<javacArg>-target</javacArg>
<javacArg>1.7</javacArg>
</javacArgs>
</configuration>
<executions>
<execution>
<id>scala-compile</id>
<phase>process-resources</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
<execution>
<id>scala-test-compile</id>
<phase>process-test-resources</phase>
<goals>
<goal>testCompile</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>

<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
<classpathPrefix>libs/</classpathPrefix>
</manifest>
</archive>
<outputDirectory>../dist/libs</outputDirectory>
</configuration>

</plugin>
</plugins>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings
only. It has no influence on the Maven build itself. -->
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>
net.alchim31.maven
</groupId>
<artifactId>
scala-maven-plugin
</artifactId>
<versionRange>
[3.1.6,)
</versionRange>
<goals>
<goal>compile</goal>
<goal>testCompile</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore></ignore>
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

<profiles>
<profile>
<id>MoCo</id>
<dependencies>
<dependency>
<groupId>MoCo</groupId>
<artifactId>MoCo</artifactId>
<version>1.2.17</version>
<scope>system</scope>
<systemPath>C:/dev/libs/MoCo.jar</systemPath>
</dependency>
</dependencies>
</profile>
</profiles>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.quil.JSON.Document;
import org.quil.interpreter.QuantLibTemplates.GenericScalaScript;
import org.quil.interpreter.QuantLibTemplates.Parameters;
import org.quil.server.Cache;


import scala.tools.nsc.Interpreter;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,16 @@
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Set;

import javax.cache.Cache.Entry;

import org.apache.ignite.Ignite;
import org.apache.ignite.IgniteCache;
import org.apache.ignite.IgniteLogger;
import org.apache.ignite.Ignition;
import org.apache.ignite.cache.CacheMode;
import org.apache.ignite.cache.query.annotations.QuerySqlField;
import org.apache.ignite.configuration.CacheConfiguration;
import org.apache.ignite.resources.LoggerResource;
import org.quil.JSON.Document;
import org.quil.repository.FileSystemRepository;
import org.quil.server.Tasks.PricePortfolio;
import org.quil.server.Tasks.PriceTrade;
import org.quil.server.Tasks.ScriptedTask;
import org.quil.server.Tasks.Task;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.quil.JSON.Document;

public class ObjectIndex {

Expand Down
6 changes: 5 additions & 1 deletion dist/sampledata/Task.QuantLibScript.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,9 @@
"EUR_Swap_1Y" : "0.05"
}
},
"TradeData" :{}
"TradeData" :{
"Notional": "10000.00",
"Cpty" : "A",
"ID" : "1"
}
}
20 changes: 20 additions & 0 deletions dist/sampledata/Task.QuantlibObjects.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"Interpreter" : "org.quil.interpreter.QuantLibObjects.QLObjectsInterpreter",
"Task" : "PriceTrade",

"Parametrization" : {
Repository : "QLObjects",
Elements : ["Curves", "Mappings"]
},

"MarketData" : {
"Base" :"ExampleMarket",
"Additional" : {
"EUR_Swap_1Y" : "0.05"
}
},

"Trades" : "Trades",

"Where" : " true "
}
16 changes: 16 additions & 0 deletions interpreter/interpreter.iml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_5" inherit-compiler-output="false">
<output url="file://$MODULE_DIR$/target/classes" />
<output-test url="file://$MODULE_DIR$/target/test-classes" />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/test/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/main/scala" isTestSource="false" />
<excludeFolder url="file://$MODULE_DIR$/target" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
Loading

0 comments on commit a9c8530

Please sign in to comment.