Skip to content

Commit

Permalink
- Stub implementation putting all classes in place without functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
mallocator committed Mar 7, 2013
1 parent 7e87841 commit ade9635
Show file tree
Hide file tree
Showing 5 changed files with 151 additions and 48 deletions.
134 changes: 86 additions & 48 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,55 +1,93 @@
<?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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<name>Elastichsearch Hadoop River</name>

This comment has been minimized.

Copy link
@mallocator

mallocator via email Apr 12, 2013

Author Owner

This comment has been minimized.

Copy link
@mallocator

mallocator Apr 12, 2013

Author Owner

Have you checked out the latest version? Because you are commenting here on an old commit, that didn't really work at all.

I'm using the current version in our system and that seems to work just fine.

This comment has been minimized.

Copy link
@mallocator

mallocator Apr 15, 2013

Author Owner

I've just committed the delete functionality.
See 2ef8ee6 for details.

Feel free to let me know if this works for you.

<modelVersion>4.0.0</modelVersion>
<groupId>org.elasticsearch</groupId>
<artifactId>rivers-hadoop</artifactId>
<packaging>jar</packaging>
<description>Hadoop River for ElasticSearch</description>
<inceptionYear>2013</inceptionYear>
<version>1.0.0-SNAPSHOT</version>

<groupId>net.pyxzl</groupId>
<artifactId>hadoop-river</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<elasticsearch.version>0.20.5</elasticsearch.version>
<hadoop.version>1.1.1</hadoop.version>

<name>hadoop-river</name>
<url>http://maven.apache.org</url>
<mavenAssemblyPlugin>2.4</mavenAssemblyPlugin>
<mavenJarPluginVersion>2.4</mavenJarPluginVersion>
<mavenCompilerPlugin>3.0</mavenCompilerPlugin>
</properties>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<scm>
<url>scm:git://github.com/mallocator/Elasticsearch-MySQL-River.git</url>
<connection>scm:git://github.com/mallocator/Elasticsearch-MySQL-River.git</connection>
<developerConnection>scm:git://github.com/mallocator/Elasticsearch-MySQL-River.git</developerConnection>
</scm>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-all</artifactId>
<version>1.8.5</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-integration</artifactId>
<version>1.2.1</version>
</dependency>
<dependency>
<groupId>net.avh4.util</groupId>
<artifactId>imagecomparison</artifactId>
<version>0.0.2</version>
<scope>test</scope>
</dependency>
</dependencies>
<dependencies>
<dependency>
<groupId>org.elasticsearch</groupId>
<artifactId>elasticsearch</artifactId>
<version>${elasticsearch.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.hadoop</groupId>
<artifactId>hadoop-core</artifactId>
<version>${hadoop.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>${mavenCompilerPlugin}</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<compilerArgument>-Xlint</compilerArgument>
<showWarnings>true</showWarnings>
<showDeprecation>true</showDeprecation>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>${mavenJarPluginVersion}</version>
<configuration>
<archive>
<manifest>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
</manifest>
<manifestEntries>
<Implementation-Vendor-Component>${project.artifactId}</Implementation-Vendor-Component>
<Implementation-Build-Date>${maven.build.timestamp}</Implementation-Build-Date>
<SVN-Build>${buildNumber}</SVN-Build>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>${mavenAssemblyPlugin}</version>
<configuration>
<appendAssemblyId>false</appendAssemblyId>
<outputDirectory>${project.build.directory}/releases/</outputDirectory>
<descriptors>
<descriptor>${basedir}/src/main/assemblies/plugin.xml</descriptor>
</descriptors>
</configuration>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package org.elasticsearch.plugin.river.hadoop;

import org.elasticsearch.common.inject.Inject;
import org.elasticsearch.plugins.AbstractPlugin;
import org.elasticsearch.river.RiversModule;
import org.elasticsearch.river.hadoop.HadoopRiverModule;

public class HadoopRiverPlugin extends AbstractPlugin {

@Inject
public HadoopRiverPlugin() {}

public String name() {
return "river-hadoop";
}

public String description() {
return "River MySQL Plugin";
}

public void onModule(final RiversModule module) {
module.registerRiver("hadoop", HadoopRiverModule.class);
}
}
28 changes: 28 additions & 0 deletions src/main/java/org/elasticsearch/river/hadoop/HadoopRiver.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
package org.elasticsearch.river.hadoop;

import org.elasticsearch.common.inject.Inject;
import org.elasticsearch.river.AbstractRiverComponent;
import org.elasticsearch.river.River;
import org.elasticsearch.river.RiverName;
import org.elasticsearch.river.RiverSettings;

public class HadoopRiver extends AbstractRiverComponent implements River {

@Inject
public HadoopRiver(RiverName riverName, RiverSettings settings) {
super(riverName, settings);
// TODO Auto-generated constructor stub
}

@Override
public void start() {
// TODO Auto-generated method stub

}

@Override
public void close() {
// TODO Auto-generated method stub

}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package org.elasticsearch.river.hadoop;

import org.elasticsearch.common.inject.AbstractModule;
import org.elasticsearch.river.River;

public class HadoopRiverModule extends AbstractModule {

@Override
protected void configure() {
bind(River.class).to(HadoopRiver.class).asEagerSingleton();
}
}
1 change: 1 addition & 0 deletions src/main/resources/es-plugin.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
plugin=org.elasticsearch.plugin.river.hadoop.HadoopRiverPlugin

0 comments on commit ade9635

Please sign in to comment.