Skip to content

Commit

Permalink
Configuration for MongoDB added.
Browse files Browse the repository at this point in the history
  • Loading branch information
skrusche63 committed Feb 5, 2015
1 parent 0d162bf commit 7e67b09
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main/resources/application.conf
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ file {
path=""
}

mongo {
mongo.input.uri="mongodb://127.0.0.1:27017/beowulf.input"
}

mysql {
url="127.0.0.1:8889"
database="analytics"
Expand Down
10 changes: 10 additions & 0 deletions src/main/scala/de/kp/spark/fsm/Configuration.scala
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,16 @@ object Configuration extends CoreConf {

}

override def mongo:HConf = {

val cfg = config.getConfig("mongo")
val conf = new HConf()

conf.set("mongo.input.uri",cfg.getString("mongo.input.uri"))
conf

}

override def mysql:(String,String,String,String) = {

val cfg = config.getConfig("mysql")
Expand Down

0 comments on commit 7e67b09

Please sign in to comment.