Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- DIR="/cygdrive/c/elasticsearch-jdbc-2.3.4.1/"
- bin=${DIR}/../bin
- lib=${DIR}/../lib
- echo '{
- "type" : "jdbc",
- "jdbc" : {
- "url" : "jdbc:postgresql://localhost:5432/demodb?loglevel=0",
- "user" : "postgres",
- "password" : "abc123",
- "sql" : "select * from srt",
- "index_settings" : {
- "index" : {
- "number_of_shards" : 10
- }
- }
- }
- }
- ' | java \
- -cp "C:\elasticsearch-jdbc-2.3.4.1\bin\*" \
- -Dlog4j.configurationFile="C:\elasticsearch-jdbc-2.3.4.1\bin\log4j2.xml" \
- org.xbib.tools.Runner \
- org.xbib.tools.JDBCImporter
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement