Skip to content

Commit

Permalink
Merge pull request #27 from danielcsant/task/preparing-release
Browse files Browse the repository at this point in the history
Preparing release
  • Loading branch information
aalfonso-stratio committed Jan 12, 2016
2 parents bcf38fd + e9b7b3e commit e847215
Show file tree
Hide file tree
Showing 5 changed files with 303 additions and 70 deletions.
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,29 @@ val receiverStream = RabbitMQUtils.createStream(sparkStreamingContext, params)

```
JavaReceiverInputDStream receiverStream = RabbitMQUtils.createJavaStream(javaSparkStreamingContext, params);
```

| Parameter | Description | Optional |
|---------------------------|------------------------------|--------------------------------------|
| host | RabbitMQ host | Yes (default: localhost) |
| queueName | Queue name | Yes |
| exchangeName | Exchange name | Yes (default: rabbitmq-exchange) |
| exchangeType | Exchange type | Yes (default: direct) |
| routingKeys | Routing keys comma separated | Yes |
| vHost | RabbitMQ vHost | Yes |
| username | RabbitMQ username | Yes |
| password | RabbitMQ password | Yes |
| storageLevel | Apache Spark storage level | Yes (default: MEMORY_AND_DISK_SER_2) |
| x-max-length | RabbitMQ queue property | Yes |
| x-message-ttl | RabbitMQ queue property | Yes |
| x-expires | RabbitMQ queue property | Yes |
| x-max-length-bytes | RabbitMQ queue property | Yes |
| x-dead-letter-exchange | RabbitMQ queue property | Yes |
| x-dead-letter-routing-key | RabbitMQ queue property | Yes |
| x-max-priority | RabbitMQ queue property | Yes |

# License #

Licensed to STRATIO (C) under one or more contributor license agreements.
Expand Down
102 changes: 33 additions & 69 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,21 @@
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>

<parent>
<groupId>com.stratio</groupId>
<artifactId>parent</artifactId>
<version>0.5.0</version>
</parent>

<groupId>com.stratio.receiver</groupId>
<artifactId>rabbitmq</artifactId>
<version>0.2.0-SNAPSHOT</version>
<packaging>pom</packaging>

<modules>
<module>rabbitmq_spark_1.4</module>
<module>rabbitmq_spark_1.5</module>
</modules>

<url>https://github.com/Stratio/RabbitMQ-Receiver</url>
<name>Spark Streaming RabbitMQ Receiver</name>
Expand Down Expand Up @@ -113,23 +125,6 @@
</developer>
</developers>

<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
</license>
</licenses>

<issueManagement>
<system>GitHub</system>
<url>https://github.com/Stratio/RabbitMQ-Receiver/issues</url>
</issueManagement>

<organization>
<name>Stratio</name>
<url>http://stratio.com</url>
</organization>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
Expand All @@ -144,16 +139,6 @@
<artifactId>amqp-client</artifactId>
<version>${rabbitmq.version}</version>
</dependency>
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-streaming_${scala.binary.version}</artifactId>
<version>${spark.version}</version>
</dependency>
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-sql_${scala.binary.version}</artifactId>
<version>${spark.version}</version>
</dependency>
<dependency>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
Expand All @@ -162,66 +147,45 @@
</dependencies>

<build>
<outputDirectory>target/scala-${scala.binary.version}/classes</outputDirectory>
<testOutputDirectory>target/scala-${scala.binary.version}/test-classes</testOutputDirectory>
<plugins>
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<recompileMode>incremental</recompileMode>
<useZincServer>true</useZincServer>
</configuration>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
</plugin>

<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.2.1</version>
<executions>
<execution>
<id>scala-compile-first</id>
<phase>process-resources</phase>
<goals>
<goal>add-source</goal>
<goal>compile</goal>
</goals>
</execution>
<execution>
<id>scala-test-compile</id>
<phase>process-test-resources</phase>
<id>attach-sources</id>
<goals>
<goal>testCompile</goal>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.2</version>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
<goal>test-jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>spark-1.4</id>
<properties>
<spark.version>1.4.1</spark.version>
<spark.version.folder>1.4</spark.version.folder>
</properties>
</profile>
<profile>
<id>spark-1.5</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<properties>
<spark.version.folder>1.5</spark.version.folder>
<spark.version>1.5.2</spark.version>
</properties>
</profile>
</profiles>
</project>
124 changes: 124 additions & 0 deletions rabbitmq_spark_1.4/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (C) 2016 Stratio (http://stratio.com)
Licensed 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.
-->

<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>rabbitmq_spark_1.4</artifactId>

<packaging>jar</packaging>

<parent>
<groupId>com.stratio.receiver</groupId>
<artifactId>rabbitmq</artifactId>
<version>0.2.0-SNAPSHOT</version>
</parent>

<build>
<testResources>
<testResource>
<directory>../src/test/resources</directory>
<filtering>true</filtering>
</testResource>
</testResources>
<sourceDirectory>../src/main/scala</sourceDirectory>
<testSourceDirectory>../src/test/scala</testSourceDirectory>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.8</version>
<executions>
<execution>
<id>copy-dependencies</id>
<phase>package</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>${project.build.directory}/alternateLocation</outputDirectory>
<overWriteReleases>false</overWriteReleases>
<overWriteSnapshots>false</overWriteSnapshots>
<overWriteIfNewer>true</overWriteIfNewer>
<excludeArtifactIds>::*</excludeArtifactIds>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>net.alchim31.maven</groupId>
<artifactId>scala-maven-plugin</artifactId>
<configuration>
<checkMultipleScalaVersions>false</checkMultipleScalaVersions>
<recompileMode>incremental</recompileMode>
</configuration>
<executions>
<execution>
<id>scala-compile-first</id>
<phase>process-resources</phase>
<goals>
<goal>add-source</goal>
</goals>
</execution>
<execution>
<id>scala-compile</id>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
<execution>
<id>scala-testCompile</id>
<phase>test-compile</phase>
<goals>
<goal>testCompile</goal>
</goals>
</execution>
<execution>
<id>scala-doc</id>
<phase>prepare-package</phase>
<goals>
<goal>doc</goal>
<goal>doc-jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>

<properties>
<scala.binary.version>2.10</scala.binary.version>
<spark.version>1.4.1</spark.version>
</properties>

<dependencies>
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-streaming_${scala.binary.version}</artifactId>
<version>${spark.version}</version>
</dependency>
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-sql_${scala.binary.version}</artifactId>
<version>${spark.version}</version>
</dependency>
</dependencies>

</project>
Loading

0 comments on commit e847215

Please sign in to comment.