JDBC River can not started


(Arthur Pan) #1

Hi,
I installed JDBC River and restart the elasticsearch. when I create a new river, it cat not started.
There are some error message in the elasticsearch.log.

[2012-07-19 11:10:34,390][INFO ][river.jdbc ] [Aardwolf] [jdbc][my_jdbc_river] starting JDBC connector: URL [jdbc:mysql://192.168.1.100:3306/forum], driver [com.mysql.jdbc.Driver], sql [select "index" as "_index", id as "_id",topic.* from topic where group_topic_type=0 and hidden=0 and active=1], river table [false], indexing to [jdbc]/[jdbc], poll [1m]
[2012-07-19 11:10:34,585][ERROR][river.jdbc ] com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at org.elasticsearch.river.jdbc.SQLService.getConnection(SQLService.java:102)
at org.elasticsearch.river.jdbc.JDBCRiver$JDBCConnector.run(JDBCRiver.java:194)
at java.lang.Thread.run(Thread.java:722)

I try it both "Ubuntu 11.10" and "mac lion 10.7.4", but it is in the same situation.

what is missing for it? how can I to do?

Thanks,
Arthur


(David Pilato) #2

As far as I understand the plugin.xml file, the JDBC river does not provide the
JDBC driver for all vendors and all versions !
So, I think you have to add your MySQL driver jar in the elasticsearch classpath
before launching the node.

HTH
David.

Le 19 juillet 2012 à 06:17, arthur pan jtp0102@gmail.com a écrit :

Hi,
I installed JDBC River and restart the elasticsearch. when I create a new
river, it cat not started.
There are some error message in the elasticsearch.log.

[2012-07-19 11:10:34,390][INFO ][river.jdbc ] [Aardwolf]
[jdbc][my_jdbc_river] starting JDBC connector: URL
[jdbc:mysql://192.168.1.100:3306/forum], driver [com.mysql.jdbc.Driver], sql
[select "index" as "_index", id as "_id",topic.* from topic where
group_topic_type=0 and hidden=0 and active=1], river table [false], indexing
to [jdbc]/[jdbc], poll [1m]
[2012-07-19 11:10:34,585][ERROR][river.jdbc ]
com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at
org.elasticsearch.river.jdbc.SQLService.getConnection(SQLService.java:102)
at
org.elasticsearch.river.jdbc.JDBCRiver$JDBCConnector.run(JDBCRiver.java:194)
at java.lang.Thread.run(Thread.java:722)

I try it both "Ubuntu 11.10" and "mac lion 10.7.4", but it is in the same
situation.

what is missing for it? how can I to do?

Thanks,
Arthur

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
David Pilato
http://dev.david.pilato.fr/
Twitter : @dadoonet


(Jörg Prante) #3

Thanks David for clarifying,

yes, to cope with various licensing issues, I deeply regret that I decided
to omit JDBC drivers from the river plugin.

Best regard,

Jörg


(Arthur Pan) #4

Thanks David and Jörg.

At first, please excuse my poor English.

I want develop a search function for my company's web and it use php.

Can show me how to add it in the plugin.xml? because, I never learned Java.
So, I don't know how to add it.
Then, how about the next step? do I open the JDBC river's source with some
software to compile it?

Thanks for your help.
Arthur

David Pilato於 2012年7月20日星期五UTC+8下午4時30分43秒寫道:

As far as I understand the plugin.xml file, the JDBC river does not
provide the JDBC driver for all vendors and all versions !

So, I think you have to add your MySQL driver jar in the elasticsearch
classpath before launching the node.

HTH

David.

Le 19 juillet 2012 à 06:17, arthur pan jtp0102@gmail.com a écrit :

Hi,
I installed JDBC River and restart the elasticsearch. when I create a
new
river, it cat not started.
There are some error message in the elasticsearch.log.

[2012-07-19 11:10:34,390][INFO ][river.jdbc ] [Aardwolf]
[jdbc][my_jdbc_river] starting JDBC connector: URL
[jdbc:mysql://192.168.1.100:3306/forum], driver
[com.mysql.jdbc.Driver], sql
[select "index" as "_index", id as "_id",topic.* from topic where
group_topic_type=0 and hidden=0 and active=1], river table [false],
indexing
to [jdbc]/[jdbc], poll [1m]
[2012-07-19 11:10:34,585][ERROR][river.jdbc ]
com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at

org.elasticsearch.river.jdbc.SQLService.getConnection(SQLService.java:102)

    at 

org.elasticsearch.river.jdbc.JDBCRiver$JDBCConnector.run(JDBCRiver.java:194)

    at java.lang.Thread.run(Thread.java:722) 

I try it both "Ubuntu 11.10" and "mac lion 10.7.4", but it is in the
same
situation.

what is missing for it? how can I to do?

Thanks,
Arthur

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
David Pilato
http://dev.david.pilato.fr/
Twitter : @dadoonet


(David Pilato) #5

Just download the driver :
http://www.mysql.fr/get/Downloads/Connector-J/mysql-connector-java-5.1.21.zip/from/http://cdn.mysql.com/

Unzip it and put the jar file in the Elasticsearch lib dir (as far as I remember, there's a lib dir)

Restart your node.

That's all.

HTH
David :wink:
Twitter : @dadoonet / @elasticsearchfr

Le 20 juil. 2012 à 19:57, Arthur pan jtp0102@gmail.com a écrit :

Thanks David and Jörg.

At first, please excuse my poor English.

I want develop a search function for my company's web and it use php.

Can show me how to add it in the plugin.xml? because, I never learned Java. So, I don't know how to add it.
Then, how about the next step? do I open the JDBC river's source with some software to compile it?

Thanks for your help.
Arthur

David Pilato於 2012年7月20日星期五UTC+8下午4時30分43秒寫道:
As far as I understand the plugin.xml file, the JDBC river does not provide the JDBC driver for all vendors and all versions !
So, I think you have to add your MySQL driver jar in the elasticsearch classpath before launching the node.

HTH
David.

Le 19 juillet 2012 à 06:17, arthur pan jtp0102@gmail.com a écrit :

Hi,
I installed JDBC River and restart the elasticsearch. when I create a new
river, it cat not started.
There are some error message in the elasticsearch.log.

[2012-07-19 11:10:34,390][INFO ][river.jdbc ] [Aardwolf]
[jdbc][my_jdbc_river] starting JDBC connector: URL
[jdbc:mysql://192.168.1.100:3306/forum], driver [com.mysql.jdbc.Driver], sql
[select "index" as "_index", id as "_id",topic.* from topic where
group_topic_type=0 and hidden=0 and active=1], river table [false], indexing
to [jdbc]/[jdbc], poll [1m]
[2012-07-19 11:10:34,585][ERROR][river.jdbc ]
com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at
org.elasticsearch.river.jdbc.SQLService.getConnection(SQLService.java:102)
at
org.elasticsearch.river.jdbc.JDBCRiver$JDBCConnector.run(JDBCRiver.java:194)
at java.lang.Thread.run(Thread.java:722)

I try it both "Ubuntu 11.10" and "mac lion 10.7.4", but it is in the same
situation.

what is missing for it? how can I to do?

Thanks,
Arthur

--
View this message in context: http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
David Pilato
http://dev.david.pilato.fr/
Twitter : @dadoonet


(Arthur Pan) #6

Thanks David's answer!!

I copied the jar file in the Elasticsearhc lib dir and restarted it, but It
is have another situation.

I created a new river.

curl -XPUT 'localhost:9200/_river/my_jdbc_river/_meta' -d '{
"type" : "jdbc",
"jdbc" : {
"driver" : "com.mysql.jdbc.Driver",
"url" : "jdbc:mysql://172.16.1.169:3306/Forum_dbo",
"user" : "forum",
"password" : "12345",
"sql" : "select * from Cate3"
}
}'

It is return this value:
{"ok":true,"_index":"_river","_type":"my_jdbc_river","_id":"_meta","_version":1}

but river is not working.
I view the Elasticsearch log file and found some message.

[2012-07-23 11:17:14,372][WARN ][river ] [Aardwolf]
failed to create river [jdbc][my_jdbc_river]
org.elasticsearch.common.settings.NoClassSettingsException: Failed to load
class with value [jdbc]
at org.elasticsearch.river.RiverModule.loadTypeModule(RiverModule.java:86)
at org.elasticsearch.river.RiverModule.spawnModules(RiverModule.java:57)
at
org.elasticsearch.common.inject.ModulesBuilder.add(ModulesBuilder.java:44)
at org.elasticsearch.river.RiversService.createRiver(RiversService.java:135)
at
org.elasticsearch.river.RiversService$ApplyRivers$2.onResponse(RiversService.java:270)
at
org.elasticsearch.river.RiversService$ApplyRivers$2.onResponse(RiversService.java:264)
at
org.elasticsearch.action.support.TransportAction$ThreadedActionListener$1.run(TransportAction.java:86)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
Caused by: java.lang.ClassNotFoundException: jdbc
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at org.elasticsearch.river.RiverModule.loadTypeModule(RiverModule.java:72)
... 9 more
[2012-07-23 11:17:14,383][INFO ][cluster.metadata ] [Aardwolf]
[_river] update_mapping [my_jdbc_river] (dynamic)

I checked account's permission of MySQL also then do it again, but it have
same situation.

what is missing?

Thanks for your help.
Arthur

David Pilato於 2012年7月21日星期六UTC+8上午2時23分36秒寫道:

Just download the driver :

http://www.mysql.fr/get/Downloads/Connector-J/mysql-connector-java-5.1.21.zip/from/http://cdn.mysql.com/

Unzip it and put the jar file in the Elasticsearch lib dir (as far as I
remember, there's a lib dir)

Restart your node.

That's all.

HTH
David :wink:
Twitter : @dadoonet / @elasticsearchfr

Le 20 juil. 2012 à 19:57, Arthur pan jtp0102@gmail.com a écrit :

Thanks David and Jörg.

At first, please excuse my poor English.

I want develop a search function for my company's web and it use php.

Can show me how to add it in the plugin.xml? because, I never learned
Java. So, I don't know how to add it.
Then, how about the next step? do I open the JDBC river's source with
some software to compile it?

Thanks for your help.
Arthur

David Pilato於 2012年7月20日星期五UTC+8下午4時30分43秒寫道:

As far as I understand the plugin.xml file, the JDBC river does not
provide the JDBC driver for all vendors and all versions !

So, I think you have to add your MySQL driver jar in the elasticsearch
classpath before launching the node.

HTH

David.

Le 19 juillet 2012 à 06:17, arthur pan jtp0102@gmail.com a écrit :

Hi,
I installed JDBC River and restart the elasticsearch. when I create a
new
river, it cat not started.
There are some error message in the elasticsearch.log.

[2012-07-19 11:10:34,390][INFO ][river.jdbc ] [Aardwolf]
[jdbc][my_jdbc_river] starting JDBC connector: URL
[jdbc:mysql://192.168.1.100:3306/forum], driver
[com.mysql.jdbc.Driver], sql
[select "index" as "_index", id as "_id",topic.* from topic where
group_topic_type=0 and hidden=0 and active=1], river table [false],
indexing
to [jdbc]/[jdbc], poll [1m]
[2012-07-19 11:10:34,585][ERROR][river.jdbc ]
com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at
sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at

org.elasticsearch.river.jdbc.SQLService.getConnection(SQLService.java:102)

    at 

org.elasticsearch.river.jdbc.JDBCRiver$JDBCConnector.run(JDBCRiver.java:194)

    at java.lang.Thread.run(Thread.java:722) 

I try it both "Ubuntu 11.10" and "mac lion 10.7.4", but it is in the
same
situation.

what is missing for it? how can I to do?

Thanks,
Arthur

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
David Pilato
http://dev.david.pilato.fr/
Twitter : @dadoonet


(David Pilato) #7

Try to delete _river index and start it again.

curl -XDELETE 'localhost:9200/_river

Not sure it will help.

David

Le 23 juil. 2012 à 06:24, Arthur pan jtp0102@gmail.com a écrit :

Thanks David's answer!!

I copied the jar file in the Elasticsearhc lib dir and restarted it, but It is have another situation.

I created a new river.

curl -XPUT 'localhost:9200/_river/my_jdbc_river/_meta' -d '{
"type" : "jdbc",
"jdbc" : {
"driver" : "com.mysql.jdbc.Driver",
"url" : "jdbc:mysql://172.16.1.169:3306/Forum_dbo",
"user" : "forum",
"password" : "12345",
"sql" : "select * from Cate3"
}
}'

It is return this value:
{"ok":true,"_index":"_river","_type":"my_jdbc_river","_id":"_meta","_version":1}

but river is not working.
I view the Elasticsearch log file and found some message.

[2012-07-23 11:17:14,372][WARN ][river ] [Aardwolf] failed to create river [jdbc][my_jdbc_river]
org.elasticsearch.common.settings.NoClassSettingsException: Failed to load class with value [jdbc]
at org.elasticsearch.river.RiverModule.loadTypeModule(RiverModule.java:86)
at org.elasticsearch.river.RiverModule.spawnModules(RiverModule.java:57)
at org.elasticsearch.common.inject.ModulesBuilder.add(ModulesBuilder.java:44)
at org.elasticsearch.river.RiversService.createRiver(RiversService.java:135)
at org.elasticsearch.river.RiversService$ApplyRivers$2.onResponse(RiversService.java:270)
at org.elasticsearch.river.RiversService$ApplyRivers$2.onResponse(RiversService.java:264)
at org.elasticsearch.action.support.TransportAction$ThreadedActionListener$1.run(TransportAction.java:86)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
Caused by: java.lang.ClassNotFoundException: jdbc
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at org.elasticsearch.river.RiverModule.loadTypeModule(RiverModule.java:72)
... 9 more
[2012-07-23 11:17:14,383][INFO ][cluster.metadata ] [Aardwolf] [_river] update_mapping [my_jdbc_river] (dynamic)

I checked account's permission of MySQL also then do it again, but it have same situation.

what is missing?

Thanks for your help.
Arthur

David Pilato於 2012年7月21日星期六UTC+8上午2時23分36秒寫道:
Just download the driver :
http://www.mysql.fr/get/Downloads/Connector-J/mysql-connector-java-5.1.21.zip/from/http://cdn.mysql.com/

Unzip it and put the jar file in the Elasticsearch lib dir (as far as I remember, there's a lib dir)

Restart your node.

That's all.

HTH
David :wink:
Twitter : @dadoonet / @elasticsearchfr

Le 20 juil. 2012 à 19:57, Arthur pan jtp0102@gmail.com a écrit :

Thanks David and Jörg.

At first, please excuse my poor English.

I want develop a search function for my company's web and it use php.

Can show me how to add it in the plugin.xml? because, I never learned Java. So, I don't know how to add it.
Then, how about the next step? do I open the JDBC river's source with some software to compile it?

Thanks for your help.
Arthur

David Pilato於 2012年7月20日星期五UTC+8下午4時30分43秒寫道:
As far as I understand the plugin.xml file, the JDBC river does not provide the JDBC driver for all vendors and all versions !
So, I think you have to add your MySQL driver jar in the elasticsearch classpath before launching the node.

HTH
David.

Le 19 juillet 2012 à 06:17, arthur pan jtp0102@gmail.com a écrit :

Hi,
I installed JDBC River and restart the elasticsearch. when I create a new
river, it cat not started.
There are some error message in the elasticsearch.log.

[2012-07-19 11:10:34,390][INFO ][river.jdbc ] [Aardwolf]
[jdbc][my_jdbc_river] starting JDBC connector: URL
[jdbc:mysql://192.168.1.100:3306/forum], driver [com.mysql.jdbc.Driver], sql
[select "index" as "_index", id as "_id",topic.* from topic where
group_topic_type=0 and hidden=0 and active=1], river table [false], indexing
to [jdbc]/[jdbc], poll [1m]
[2012-07-19 11:10:34,585][ERROR][river.jdbc ]
com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at
org.elasticsearch.river.jdbc.SQLService.getConnection(SQLService.java:102)
at
org.elasticsearch.river.jdbc.JDBCRiver$JDBCConnector.run(JDBCRiver.java:194)
at java.lang.Thread.run(Thread.java:722)

I try it both "Ubuntu 11.10" and "mac lion 10.7.4", but it is in the same
situation.

what is missing for it? how can I to do?

Thanks,
Arthur

--
View this message in context: http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
David Pilato
http://dev.david.pilato.fr/
Twitter : @dadoonet


(Arthur Pan) #8

Hi,
River is running success.

After that, I remove all index, but it still not work.
I searched and found some article that about how to install MySQL's JDBC
driver, and I found that my server not installed mysql's JDBC driver.
So, I decide to try it.

excute "sudo apt-get install libmysql-java" to install mysql's JDBC driver
then add path in the /etc/profile file.

copy /usr/share/java/mysql-connector-java-5.1.10.jar in to
Elasticsearch_root_dir/lib/ and restart Elasticsearch.

Create a new river.
curl -XPUT 'localhost:9200/_river/my_jdbc_river/_meta' -d '{
"type" : "jdbc",
"jdbc" : {
"driver" : "com.mysql.jdbc.Driver",
"url" : "jdbc:mysql://172.16.1.100:3306/forum",
"user" : "abc",
"password" : "12345",
"sql" : "select * from Cate3"
}
}'

It is working. :slight_smile:

Arthur pan於 2012年7月19日星期四UTC+8下午12時17分51秒寫道:

Hi,
I installed JDBC River and restart the elasticsearch. when I create a new
river, it cat not started.
There are some error message in the elasticsearch.log.

[2012-07-19 11:10:34,390][INFO ][river.jdbc ] [Aardwolf]
[jdbc][my_jdbc_river] starting JDBC connector: URL
[jdbc:mysql://192.168.1.100:3306/forum], driver [com.mysql.jdbc.Driver],
sql
[select "index" as "_index", id as "_id",topic.* from topic where
group_topic_type=0 and hidden=0 and active=1], river table [false],
indexing
to [jdbc]/[jdbc], poll [1m]
[2012-07-19 11:10:34,585][ERROR][river.jdbc ]
com.mysql.jdbc.Driver
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at
org.elasticsearch.river.jdbc.SQLService.getConnection(SQLService.java:102)
at
org.elasticsearch.river.jdbc.JDBCRiver$JDBCConnector.run(JDBCRiver.java:194)

    at java.lang.Thread.run(Thread.java:722) 

I try it both "Ubuntu 11.10" and "mac lion 10.7.4", but it is in the same
situation.

what is missing for it? how can I to do?

Thanks,
Arthur

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.


(alex) #9

Good afternoon to everybody,

Recently I have installed elasticsearch and the JDBC River, and seem to be working fine, even if I am quite new to the no-sql technologies and as novice am I, it could sound a bit silly my question.

When I try to see the status of my ‘river’:to retrieve the status with

http://localhost:9200/_river/my_jdbc_river/_status?pretty=true

This is displayed as a result:
{
"_index" : "_river",
"_type" : "my_jdbc_river",
"_id" : "_status",
"_version" : 1,
"exists" : true, "_source" : {"ok":true,"node":{"id":"hm-baF0PSOG57bQuhn6sMw","name":"Supernalia","transport_address":"inet[/217.169.9.63:9303]"}}
}

Taking the example of MySql, then if I would execute a Sql query to retrieve info like:

SELECT * FROM test.orders;

The results could be:

dustomer, department, product, quantity, created
'Big', 'American Fruits', 'Apples', '1', '0000-00-00 00:00:00'
'Large', 'German Fruits', 'Bananas', '1', '0000-00-00 00:00:00'
'Huge', 'German Fruits', 'Oranges', '2', '0000-00-00 00:00:00'
'Good', 'German Fruits', 'Apples', '2', '2012-06-01 00:00:00'
'Bad', 'English Fruits', 'Oranges', '3', '2012-06-01 00:00:00'

The question then is how could I get similar results using elasticsearch?

Thanks.


(alex) #10

Good afternoon to everybody,

Recently I have installed elasticsearch and the JDBC River, and seem to be working fine, even if I am quite new to the no-sql technologies and as novice am I, it could sound a bit silly my question.

When I try to see the status of my ‘river’:to retrieve the status with

http://localhost:9200/_river/my_jdbc_river/_status?pretty=true

This is displayed as a result:
{
"_index" : "_river",
"_type" : "my_jdbc_river",
"_id" : "_status",
"_version" : 1,
"exists" : true, "_source" : {"ok":true,"node":{"id":"hm-baF0PSOG57bQuhn6sMw","name":"Supernalia","transport_address":"inet[/217.169.9.63:9303]"}}
}

Taking the example of MySql, then if I would execute a Sql query to retrieve info like:

SELECT * FROM test.orders;

The results could be:

dustomer, department, product, quantity, created
'Big', 'American Fruits', 'Apples', '1', '0000-00-00 00:00:00'
'Large', 'German Fruits', 'Bananas', '1', '0000-00-00 00:00:00'
'Huge', 'German Fruits', 'Oranges', '2', '0000-00-00 00:00:00'
'Good', 'German Fruits', 'Apples', '2', '2012-06-01 00:00:00'
'Bad', 'English Fruits', 'Oranges', '3', '2012-06-01 00:00:00'

The question then is how could I get similar results using elasticsearch?

Thanks.


(David Pilato) #11

Something like

curl -XGET http://localhost:9200/my_jdbc_river/orders/_search?q=*

?

HTH
david.

Le 27 juillet 2012 à 18:03, alex alejandro@themartingale.com a écrit :

Good afternoon to everybody,

Recently I have installed elasticsearch and the JDBC River, and seem to be
working fine, even if I am quite new to the no-sql technologies and as
novice am I, it could sound a bit silly my question.

When I try to see the status of my ‘river’:to retrieve the status with

http://localhost:9200/_river/my_jdbc_river/_status?pretty=true

This is displayed as a result:
{
"_index" : "_river",
"_type" : "my_jdbc_river",
"_id" : "_status",
"_version" : 1,
"exists" : true, "_source" :
{"ok":true,"node":{"id":"hm-baF0PSOG57bQuhn6sMw","name":"Supernalia","transport_address":"inet[/217.169.9.63:9303]"}}
}

Taking the example of MySql, then if I would execute a Sql query to retrieve
info like:

SELECT * FROM test.orders;

The results could be:

dustomer, department, product, quantity, created
'Big', 'American Fruits', 'Apples', '1', '0000-00-00 00:00:00'
'Large', 'German Fruits', 'Bananas', '1', '0000-00-00 00:00:00'
'Huge', 'German Fruits', 'Oranges', '2', '0000-00-00 00:00:00'
'Good', 'German Fruits', 'Apples', '2', '2012-06-01 00:00:00'
'Bad', 'English Fruits', 'Oranges', '3', '2012-06-01 00:00:00'

The question then is *how could I get similar results using elasticsearch?
*

Thanks.

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565p4020922.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
David Pilato
http://www.scrutmydocs.org/
http://dev.david.pilato.fr/
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs


(alex) #12

Good morning dadoonet,

 Thanks for your soon reply. As you had suggested me, I have tried:

curl -XGET http://localhost:9200/my_jdbc_river/orders/_search?q=*

but then I get the result:

{"error":"IndexMissingException[[my_jdbc_river] missing]","status":404}

Also I have tried:

curl -XGET http://localhost:9200/_river/my_jdbc_river/orders/_search?q=*

and get the result:

No handler found for uri [/_river/my_jdbc_river/orders/_search?q=*] and method [GET]

And also tried:

http://dev-vm-03:9200/jdbc/orders/_search?q=*

Results:

{"took":473,"timed_out":false,"_shards":{"total":5,"successful":5,"failed":0},"hits":{"total":0,"max_score":null,"hits":[]}}

It seems that the info is there (total: 5 – for the 5 rows I think). The point is that if there is this request structure:

http://localhost:9200/{index}/{type}/{id}

And the River-JDBC follow:

Index: jdbc/jdbc [as it is said in: https://github.com/jprante/elasticsearch-river-jdbc] it should work like you said it before, but still I can Not retrieve the list of orders like:

dustomer, department, product, quantity, created
'Big', 'American Fruits', 'Apples', '1', '0000-00-00 00:00:00'
'Large', 'German Fruits', 'Bananas', '1', '0000-00-00 00:00:00'
'Huge', 'German Fruits', 'Oranges', '2', '0000-00-00 00:00:00'
'Good', 'German Fruits', 'Apples', '2', '2012-06-01 00:00:00'
'Bad', 'English Fruits', 'Oranges', '3', '2012-06-01 00:00:00'

Even if I created the index like this:

curl -XPUT 'localhost:9200/_river/my_jdbc_river/_meta' -d '{
"type" : "jdbc",
"jdbc" : {
"driver" : "com.mysql.jdbc.Driver",
"url" : "jdbc:mysql://database:3306/test",
"user" : "root",
"password" : "",
"sql" : "select * from orders;"
}
}'

It is quite frustrating and a bit confusing this, even if it is just a ‘select basic query’, and there is Not even one example of “getting” info in the https://github.com/jprante/elasticsearch-river-jdbc main documentation, or at least I didn’t find any yet.

This could be very easy and fast, but after many hours trying to understand and make it work properly I still didn’t get the basic results I need. Any idea or suggestion is more than welcome and very useful. Thanks in advance.

P.D.: The objective after achieving this is to create a Joomla component which could “search” the entire site and MySql database.


(David Pilato) #13

Try with :

curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*

or

curl -XGET http://localhost:9200/_search?q=*

The last one will give you all indexed documents in ES (also the jdbc river
settings).
But, you should find at least one of your "orders".

{"took":473,"timed_out":false,"_shards":{"total":5,"successful":5,"failed":0},"hits":{"total":0,"max_score":null,"hits":[]}}

It seems that the info is there (total: 5 – for the 5 rows I think).
No. An index is broken in 5 shards by default. This answer only means that ES
has successfuly searched in the 5 shards.

hits.total=0, that's the number of documents ES have found.

HTH
David.

Le 30 juillet 2012 à 13:05, alex alejandro@themartingale.com a écrit :

Good morning dadoonet,

 Thanks for your soon reply. As you had suggested me, I have tried:

/curl -XGET http://localhost:9200/my_jdbc_river/orders/_search?q=*/

but then I get the result:

{"error":"IndexMissingException[[my_jdbc_river] missing]","status":404}

Also I have tried:

/curl -XGET http://localhost:9200/_river/my_jdbc_river/orders/_search?q=*/

and get the result:

No handler found for uri [/_river/my_jdbc_river/orders/_search?q=] and
method [GET]*

And also tried:

/http://dev-vm-03:9200/jdbc/orders/_search?q=*/

Results:

{"took":473,"timed_out":false,"_shards":{"total":5,"successful":5,"failed":0},"hits":{"total":0,"max_score":null,"hits":[]}}

It seems that the info is there (total: 5 – for the 5 rows I think). The
point is that if there is this request structure:

http://localhost:9200/{index}/{type}/{id}

And the River-JDBC follow:

Index: jdbc/jdbc [as it is said in:
https://github.com/jprante/elasticsearch-river-jdbc] it should work like you
said it before, but still I can Not retrieve the list of orders like:

dustomer, department, product, quantity, created
'Big', 'American Fruits', 'Apples', '1', '0000-00-00 00:00:00'
'Large', 'German Fruits', 'Bananas', '1', '0000-00-00 00:00:00'
'Huge', 'German Fruits', 'Oranges', '2', '0000-00-00 00:00:00'
'Good', 'German Fruits', 'Apples', '2', '2012-06-01 00:00:00'
'Bad', 'English Fruits', 'Oranges', '3', '2012-06-01 00:00:00'

Even if I created the index like this:

curl -XPUT 'localhost:9200/_river/my_jdbc_river/_meta' -d '{
"type" : "jdbc",
"jdbc" : {
"driver" : "com.mysql.jdbc.Driver",
"url" : "jdbc:mysql://database:3306/test",
"user" : "root",
"password" : "",
"sql" : "select * from orders;"
}
}'

It is quite frustrating and a bit confusing this, even if it is just a
‘select basic query’, and there is Not even one example of “getting” info in
the https://github.com/jprante/elasticsearch-river-jdbc main documentation,
or at least I didn’t find any yet.

This could be very easy and fast, but after many hours trying to understand
and make it work properly I still didn’t get the basic results I need. Any
idea or suggestion is more than welcome and very useful. Thanks in advance.

P.D.: The objective after achieving this is to create a Joomla component
which could “search” the entire site and MySql database.

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565p4021009.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.

--
David Pilato
http://www.scrutmydocs.org/
http://dev.david.pilato.fr/
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs


(alex) #14

Thanks very much David!! It is working fine now!!

 I had executed this suggested command:

curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*

And then it was displayed and clear that the index was there but still empty, then fixed my login info to MySql, deleted the former Index, created a new one and after executing the other command:

curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*&pretty=true

I could effectively get the complete list of ‘orders’ <b>result</b> like this:

{
"took" : 2627,
"timed_out" : false,
"_shards" : {
"total" : 5,
"successful" : 5,
"failed" : 0
},
"hits" : {
"total" : 5,
"max_score" : 1.0,
"hits" : [ {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "4",
"_score" : 1.0, "_source" : {"product":"Apples","created":"2012-05-31T23:00:00Z","department":"German Fruits","quantity":2,"customer":"Good"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "5",
"_score" : 1.0, "_source" : {"product":"Oranges","created":"2012-05-31T23:00:00Z","department":"English Fruits","quantity":3,"customer":"Bad"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "1",
"_score" : 1.0, "_source" : {"product":"Apples","created":null,"department":"American Fruits","quantity":1,"customer":"Big"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "2",
"_score" : 1.0, "_source" : {"product":"Bananas","created":null,"department":"German Fruits","quantity":1,"customer":"Large"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "3",
"_score" : 1.0, "_source" : {"product":"Oranges","created":null,"department":"German Fruits","quantity":2,"customer":"Huge"}
} ]
}
}

Note: Also probably we had this strange magic behavior as we were working like a team, with another colleague and someway her IP address appears in the Log file, and mine in her Log file, and any change she was making [at the same Server but in a different Virtual Machine with different IP] was affecting me and my changes affecting her.

Then she stooped everything, deleted everything (I still could see some of her ‘remaining nodes’ somehow) and I tried to do it again everything from the beginning. Ok it was not the standard environment to install and test it, I know but I am happy that it is working well now.

Thanks, now I know that the problem was the concurrent work, the Data Base connection and the structure of retrieving info.

Alex


(David Pilato) #15

Magic? No! Only Elastic! :wink:

Each Time you launch a new node in your network, ES find all other nodes of your cluster.
To change it, simply change your cluster name in elasticsearch.yml file.

David

--

Le 30 juil. 2012 à 18:42, alex alejandro@themartingale.com a écrit :

Thanks very much David!! It is working fine now!!

I had executed this suggested command:

/curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*/

And then it was displayed and clear that the index was there but still
empty, then fixed my login info to MySql, deleted the former Index, created
a new one and after executing the other command:

/curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*&pretty=true/

I could effectively get the complete list of ‘orders’ result like
this:

{
"took" : 2627,
"timed_out" : false,
"_shards" : {
"total" : 5,
"successful" : 5,
"failed" : 0
},
"hits" : {
"total" : 5,
"max_score" : 1.0,
"hits" : [ {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "4",
"_score" : 1.0, "_source" :
{"product":"Apples","created":"2012-05-31T23:00:00Z","department":"German
Fruits","quantity":2,"customer":"Good"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "5",
"_score" : 1.0, "_source" :
{"product":"Oranges","created":"2012-05-31T23:00:00Z","department":"English
Fruits","quantity":3,"customer":"Bad"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "1",
"_score" : 1.0, "_source" :
{"product":"Apples","created":null,"department":"American
Fruits","quantity":1,"customer":"Big"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "2",
"_score" : 1.0, "_source" :
{"product":"Bananas","created":null,"department":"German
Fruits","quantity":1,"customer":"Large"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "3",
"_score" : 1.0, "_source" :
{"product":"Oranges","created":null,"department":"German
Fruits","quantity":2,"customer":"Huge"}
} ]
}
}

Note: Also probably we had this strange magic behavior as we were working
like a team, with another colleague and someway her IP address appears in
the Log file, and mine in her Log file, and any change she was making [at
the same Server but in a different Virtual Machine with different IP] was
affecting me and my changes affecting her.

Then she stooped everything, deleted everything (I still could see some of
her ‘remaining nodes’ somehow) and I tried to do it again everything from
the beginning. Ok it was not the standard environment to install and test
it, I know but I am happy that it is working well now.

Thanks, now I know that the problem was the concurrent work, the Data Base
connection and the structure of retrieving info.

Alex

--
View this message in context: http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565p4021024.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.


(Jörg Prante) #16

Hi Alex,

thanks for trying the JDBC river, it is my personal project, please don't
blame Elasticsearch for that.

I will take it very seriously that full out-of-the-box working examples are
missing and quick start seems not easy, so I will add a tutorial "Getting
started" with detailed steps to the wiki of the JDBC river github project
soon.

David, thanks for giving advise to Alex! Much appreciated!

Best regards,

Jörg

On Monday, July 30, 2012 6:42:25 PM UTC+2, alex wrote:

Thanks very much David!! It is working fine now!!

 I had executed this suggested command: 

/curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*/

And then it was displayed and clear that the index was there but still
empty, then fixed my login info to MySql, deleted the former Index,
created
a new one and after executing the other command:

/curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*&pretty=true/

I could effectively get the complete list of ‘orders’ *result* like 

this:

{
"took" : 2627,
"timed_out" : false,
"_shards" : {
"total" : 5,
"successful" : 5,
"failed" : 0
},
"hits" : {
"total" : 5,
"max_score" : 1.0,
"hits" : [ {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "4",
"_score" : 1.0, "_source" :
{"product":"Apples","created":"2012-05-31T23:00:00Z","department":"German
Fruits","quantity":2,"customer":"Good"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "5",
"_score" : 1.0, "_source" :
{"product":"Oranges","created":"2012-05-31T23:00:00Z","department":"English

Fruits","quantity":3,"customer":"Bad"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "1",
"_score" : 1.0, "_source" :
{"product":"Apples","created":null,"department":"American
Fruits","quantity":1,"customer":"Big"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "2",
"_score" : 1.0, "_source" :
{"product":"Bananas","created":null,"department":"German
Fruits","quantity":1,"customer":"Large"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "3",
"_score" : 1.0, "_source" :
{"product":"Oranges","created":null,"department":"German
Fruits","quantity":2,"customer":"Huge"}
} ]
}
}

Note: Also probably we had this strange magic behavior as we were
working
like a team, with another colleague and someway her IP address appears in
the Log file, and mine in her Log file, and any change she was making [at
the same Server but in a different Virtual Machine with different IP] was
affecting me and my changes affecting her.

Then she stooped everything, deleted everything (I still could see some of
her ‘remaining nodes’ somehow) and I tried to do it again everything from
the beginning. Ok it was not the standard environment to install and test
it, I know but I am happy that it is working well now.

Thanks, now I know that the problem was the concurrent work, the Data Base
connection and the structure of retrieving info.

Alex

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565p4021024.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.


(David Pilato) #17

My pleasure. As I told you before, with this very nice plugin, you will have many questions about it. I'm sure we can share the support effort !

At least, I will help you a little on it! :wink:

Cheers

--

Le 30 juil. 2012 à 19:56, Jörg Prante joergprante@gmail.com a écrit :

Hi Alex,

thanks for trying the JDBC river, it is my personal project, please don't blame Elasticsearch for that.

I will take it very seriously that full out-of-the-box working examples are missing and quick start seems not easy, so I will add a tutorial "Getting started" with detailed steps to the wiki of the JDBC river github project soon.

David, thanks for giving advise to Alex! Much appreciated!

Best regards,

Jörg

On Monday, July 30, 2012 6:42:25 PM UTC+2, alex wrote:
Thanks very much David!! It is working fine now!!

 I had executed this suggested command: 

/curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*/

And then it was displayed and clear that the index was there but still
empty, then fixed my login info to MySql, deleted the former Index, created
a new one and after executing the other command:

/curl -XGET http://localhost:9200/jdbc/jdbc/_search?q=*&pretty=true/

I could effectively get the complete list of ‘orders’ *result* like 

this:

{
"took" : 2627,
"timed_out" : false,
"_shards" : {
"total" : 5,
"successful" : 5,
"failed" : 0
},
"hits" : {
"total" : 5,
"max_score" : 1.0,
"hits" : [ {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "4",
"_score" : 1.0, "_source" :
{"product":"Apples","created":"2012-05-31T23:00:00Z","department":"German
Fruits","quantity":2,"customer":"Good"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "5",
"_score" : 1.0, "_source" :
{"product":"Oranges","created":"2012-05-31T23:00:00Z","department":"English
Fruits","quantity":3,"customer":"Bad"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "1",
"_score" : 1.0, "_source" :
{"product":"Apples","created":null,"department":"American
Fruits","quantity":1,"customer":"Big"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "2",
"_score" : 1.0, "_source" :
{"product":"Bananas","created":null,"department":"German
Fruits","quantity":1,"customer":"Large"}
}, {
"_index" : "jdbc",
"_type" : "jdbc",
"_id" : "3",
"_score" : 1.0, "_source" :
{"product":"Oranges","created":null,"department":"German
Fruits","quantity":2,"customer":"Huge"}
} ]
}
}

Note: Also probably we had this strange magic behavior as we were working
like a team, with another colleague and someway her IP address appears in
the Log file, and mine in her Log file, and any change she was making [at
the same Server but in a different Virtual Machine with different IP] was
affecting me and my changes affecting her.

Then she stooped everything, deleted everything (I still could see some of
her ‘remaining nodes’ somehow) and I tried to do it again everything from
the beginning. Ok it was not the standard environment to install and test
it, I know but I am happy that it is working well now.

Thanks, now I know that the problem was the concurrent work, the Data Base
connection and the structure of retrieving info.

Alex

--
View this message in context: http://elasticsearch-users.115913.n3.nabble.com/JDBC-River-can-not-started-tp4020565p4021024.html
Sent from the ElasticSearch Users mailing list archive at Nabble.com.


(sowmyak) #18

Hi,

I have a problem using JDBC plug in with elasticsearch and mysql.
I am able to poll and retrieve the values using Polling.

But, When I am using the method of Updating Mechanisms, I am not able to index the values into ElasticSearch.

when I am using -XGET to retrieve the indexes, it is giving me 0 hits.

This is the procedure that I have followed for getting my updates on mysql table reflected on elasticsearch index.

Step 1: create table class_info(rno int, name varchar(100)); //Create a table in mysql database
Step 2 : create table my_jdbc_river(_index varchar(64), _type varchar(64), _id varchar(64), source_timestamp timestamp not null default current_timestamp, source_operation varchar(8), source_sql varchar(255), target_timestamp timestamp, target_operation varchar(8) default 'n/a', target_failed boolean, target_message varchar(255), primary key(_index, _type, _id, source_timestamp, source_operation));
//create a river table in mysql database

Step 3: Create a trigger on class_info table to insert the rows into my_jdbc_river on insert operation
delimiter $$

create trigger check_root after insert on class_info for each row begin insert into my_jdbc_river values("index", "type", "id", null, 'create', 'select * from check_es', null, null, true, null); end$$

delimiter ;

I am not sure whether the parameters to insert statement are correct or not.

Step 4: Create a river on ElasticSearch
curl -XPUT 'localhost:9200/_river/my_jdbc_river/_meta' -d '{ "type" : "jdbc", "jdbc" : { "driver" : "com.mysql.jdbc.Driver", "url" : "jdbc:mysql://localhost:3306/testes", "user" : "root", "password" : "p00ph34d", "poll" : "300s","rivertable" : true, "interval" : "305s" }, "index" : { "index" : "jdbc","type" : "jdbc", "bulk_size" : 100,"max_bulk_requests" : 30, "bulk_timeout" : "60s"} }'

And, when i am inserting the values into class_info they are not being indexed in elasticsearch.

Please let me know the correct procedure I am missing anything or misunderstood the concept.

Thanks!


(system) #19