Skip to content
Browse files

Merge pull request #3 from nboire/master

Upgrade to ElasticSearch v0.19.10 
Upgrade to play2.0.2
  • Loading branch information...
2 parents f75e584 + eb01d2e commit 21ca5c8e7aabba5190c52fcf34c3c788e624f3e5 @nboire nboire committed Oct 3, 2012
View
2 .gitignore
@@ -6,6 +6,8 @@
*.ear
.DS_Store
+.idea
+.settings
*.iml
*.ipr
*.iws
View
2 .travis.yml
@@ -1,6 +1,6 @@
language: java
env:
- - PLAY_VERSION=2.0
+ - PLAY_VERSION=2.0.2
before_script:
- wget http://download.playframework.org/releases/play-${PLAY_VERSION}.zip
- unzip -q play-${PLAY_VERSION}.zip
View
13 README.md
@@ -1,21 +1,22 @@
# play2-elasticsearch
===================
-This module provides [Elasticsearch](http://www.elasticsearch.org/)(v0.19.4) in a play2 application
+This module provides [Elasticsearch](http://www.elasticsearch.org/)(v0.19.10) in a play2 application
## Versions
0.1 -> init version
0.2 -> Percolators support
0.3 -> IndexResult : add pagination data
+ 0.4 -> upgrade ES to 0.19.10
## Roadmap
- 0.4 -> Add binding for Ebean Model via an IndexModel.class
+ 0.5 -> Add binding for Ebean Model via an IndexModel.class
## Installing
The dependency declaration is
```
-"com.github.cleverage" % "elasticsearch_2.9.1" % "0.3"
+"com.github.cleverage" % "elasticsearch_2.9.1" % "0.4"
```
The resolver repository is
@@ -36,7 +37,7 @@ object ApplicationBuild extends Build {
val appDependencies = Seq(
// Add your project dependencies here,
- "com.github.cleverage" % "elasticsearch_2.9.1" % "0.3"
+ "com.github.cleverage" % "elasticsearch_2.9.1" % "0.4"
)
val main = PlayProject(appName, appVersion, appDependencies, mainLang = JAVA).settings(
@@ -109,3 +110,7 @@ See samples/elasticsearch-java application for more sample
## Javadoc
http://cleverage.github.com/play2-elasticsearch/javadoc/
+
+## Author
+@nboire & @mguillermin
+
View
10 module/app/com/github/cleverage/elasticsearch/plugin/IndexPlugin.java
@@ -52,10 +52,12 @@ public void onStart()
@Override
public void onStop()
{
- try {
- client.stop();
- } catch (Exception e) {
- Logger.error("ElasticSearch : error when stop plugin ",e);
+ if(client!= null) {
+ try {
+ client.stop();
+ } catch (Exception e) {
+ Logger.error("ElasticSearch : error when stop plugin ",e);
+ }
}
Logger.info("ElasticSearch : Plugin has stopped");
}
View
17 module/conf/reference.conf
@@ -0,0 +1,17 @@
+## ElasticSearch Configuration
+##############################
+## define local mode or not
+elasticsearch.local=true
+
+## list clients
+#elasticsearch.client="192.168.0.46:9300"
+# ex : elasticsearch.client="192.168.0.46:9300,192.168.0.47:9300"
+
+## Name of the index
+elasticsearch.index.name="play2-elasticsearch"
+
+## define package or class separate by commas for loading @IndexType and @IndexMapping information
+elasticsearch.index.clazzs="indexing.*"
+
+## show request & result json of search request in log
+elasticsearch.index.show_request=true
View
9 module/project/Build.scala
@@ -5,15 +5,16 @@ import PlayProject._
object ApplicationBuild extends Build {
val appName = "elasticsearch"
- val appVersion = "0.3.1"
+ val appVersion = "0.4"
val appDependencies = Seq(
// Add your project dependencies here
- "org.elasticsearch" % "elasticsearch" % "0.19.4"
+ "org.elasticsearch" % "elasticsearch" % "0.19.10"
)
val main = PlayProject(appName, appVersion, appDependencies, mainLang = JAVA).settings(
- organization := "com.github.cleverage"
+ organization := "com.github.cleverage",
+ resolvers += "oss sonytape (release)" at "http://oss.sonatype.org/content/repositories/releases/"
)
-}
+}
View
2 module/project/build.properties
@@ -1 +1 @@
-sbt.version=0.11.2
+sbt.version=0.11.3
View
2 module/project/plugins.sbt
@@ -5,4 +5,4 @@ logLevel := Level.Warn
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
// Use the Play sbt plugin for Play projects
-addSbtPlugin("play" % "sbt-plugin" % "2.0")
+addSbtPlugin("play" % "sbt-plugin" % "2.0.2")
View
2 samples/elasticsearch-java/project/Build.scala
@@ -9,7 +9,7 @@ object ApplicationBuild extends Build {
val appDependencies = Seq(
// Add your project dependencies here,
- "com.github.cleverage" % "elasticsearch_2.9.1" % "0.3"
+ "com.github.cleverage" % "elasticsearch_2.9.1" % "0.4"
)
val main = PlayProject(appName, appVersion, appDependencies, mainLang = JAVA).settings(
View
2 samples/elasticsearch-java/project/build.properties
@@ -1 +1 @@
-sbt.version=0.11.2
+sbt.version=0.11.3
View
2 samples/elasticsearch-java/project/plugins.sbt
@@ -5,4 +5,4 @@ logLevel := Level.Warn
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
// Use the Play sbt plugin for Play projects
-addSbtPlugin("play" % "sbt-plugin" % "2.0")
+addSbtPlugin("play" % "sbt-plugin" % "2.0.2")

0 comments on commit 21ca5c8

Please sign in to comment.
Something went wrong with that request. Please try again.