Hibernate Search with Elasticsearch

Hi everyone,

I am new to the forum and I am also new to ElasticSearch!
However for this project, I am trying to replace HibernateSearch with
ElasticSearch. I am using Spring Framework, and I have also taken a look at
both Spring-ElasticSearch and Spring-Data-ElasticSearch. However, I am
still new to using these open source programs and don't really know where I
should start. I'd appreciate it if someone could give me a push in the
right direction on how to incorporate ElasticSearch into my code. Thank
you!

(I posted this on the archives so if this pops up twice I'm sorry!! I
didn't understand how this forum worked)

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Have a look here. https://github.com/dadoonet/legacy-search

It's an Hibernate demo project which uses Spring as well.
If you navigate through branches, it will show you how to add elasticsearch.

I won't try to connect Hibernate Search and replace Lucene implementation by elasticsearch.

My 2 cents
David

Le 12 févr. 2015 à 00:18, William Yang williamyang93@gmail.com a écrit :

Hi everyone,

I am new to the forum and I am also new to ElasticSearch!
However for this project, I am trying to replace HibernateSearch with ElasticSearch. I am using Spring Framework, and I have also taken a look at both Spring-ElasticSearch and Spring-Data-ElasticSearch. However, I am still new to using these open source programs and don't really know where I should start. I'd appreciate it if someone could give me a push in the right direction on how to incorporate ElasticSearch into my code. Thank you!

(I posted this on the archives so if this pops up twice I'm sorry!! I didn't understand how this forum worked)

You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

Hey David,

Thanks for responding - I found that link too and tried to follow it but I
got confused what postgresql is. If I don't know what it is, where do I
find it?
Also I think I had some problems with a common dependency, I don't have the
exact error code on me right now, but there was something wrong with the
dependency.

What would I put as the goal when I try to run it in spring? clean install,
or just jetty:run?

On Wed, Feb 11, 2015 at 10:04 PM, David Pilato david@pilato.fr wrote:

Have a look here. https://github.com/dadoonet/legacy-search

It's an Hibernate demo project which uses Spring as well.
If you navigate through branches, it will show you how to add
elasticsearch.

I won't try to connect Hibernate Search and replace Lucene implementation
by elasticsearch.

My 2 cents
David

Le 12 févr. 2015 à 00:18, William Yang williamyang93@gmail.com a écrit :

Hi everyone,

I am new to the forum and I am also new to ElasticSearch!
However for this project, I am trying to replace HibernateSearch with
ElasticSearch. I am using Spring Framework, and I have also taken a look
at both Spring-ElasticSearch and Spring-Data-ElasticSearch. However, I am
still new to using these open source programs and don't really know where I
should start. I'd appreciate it if someone could give me a push in the
right direction on how to incorporate ElasticSearch into my code. Thank
you!

(I posted this on the archives so if this pops up twice I'm sorry!! I
didn't understand how this forum worked)

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the
Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr
https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-Pnid4LTy8ArhN6uqcTvH8LVDNt4MCCxrQmiYatAQxJNpQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

postgresql is a database. I guess you are using Hibernate with a database, right?
Unless you are using only Hibernate search?

What do you mean "run in Spring"?
Spring is the framework right?

mvn jetty:run should work fine

David

Le 12 févr. 2015 à 07:11, William Yang williamyang93@gmail.com a écrit :

Hey David,

Thanks for responding - I found that link too and tried to follow it but I got confused what postgresql is. If I don't know what it is, where do I find it?
Also I think I had some problems with a common dependency, I don't have the exact error code on me right now, but there was something wrong with the dependency.

What would I put as the goal when I try to run it in spring? clean install, or just jetty:run?

On Wed, Feb 11, 2015 at 10:04 PM, David Pilato david@pilato.fr wrote:
Have a look here. https://github.com/dadoonet/legacy-search

It's an Hibernate demo project which uses Spring as well.
If you navigate through branches, it will show you how to add elasticsearch.

I won't try to connect Hibernate Search and replace Lucene implementation by elasticsearch.

My 2 cents
David

Le 12 févr. 2015 à 00:18, William Yang williamyang93@gmail.com a écrit :

Hi everyone,

I am new to the forum and I am also new to ElasticSearch!
However for this project, I am trying to replace HibernateSearch with ElasticSearch. I am using Spring Framework, and I have also taken a look at both Spring-ElasticSearch and Spring-Data-ElasticSearch. However, I am still new to using these open source programs and don't really know where I should start. I'd appreciate it if someone could give me a push in the right direction on how to incorporate ElasticSearch into my code. Thank you!

(I posted this on the archives so if this pops up twice I'm sorry!! I didn't understand how this forum worked)

You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-Pnid4LTy8ArhN6uqcTvH8LVDNt4MCCxrQmiYatAQxJNpQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/B29F2368-4B2E-41F9-A84C-16519688106B%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

Oh I will be using MySQL in the future, right now I'm adding it upon
AppFuse (which is a website that lets you log in, add users, and search for
users).
So I guess, Yes, right now I am only using Hibernate search. What should I
do about the postgresql part until I get to using MySQL?

And yes, when I said "run in Spring," I meant how to build it in the Spring
Framework...there was an error (that I don't remember right now) that
wouldn't let me compile it because a dependency was missing.

On Wed, Feb 11, 2015 at 10:25 PM, David Pilato david@pilato.fr wrote:

postgresql is a database. I guess you are using Hibernate with a database,
right?
Unless you are using only Hibernate search?

What do you mean "run in Spring"?
Spring is the framework right?

mvn jetty:run should work fine

David

Le 12 févr. 2015 à 07:11, William Yang williamyang93@gmail.com a écrit :

Hey David,

Thanks for responding - I found that link too and tried to follow it but I
got confused what postgresql is. If I don't know what it is, where do I
find it?
Also I think I had some problems with a common dependency, I don't have
the exact error code on me right now, but there was something wrong with
the dependency.

What would I put as the goal when I try to run it in spring? clean
install, or just jetty:run?

On Wed, Feb 11, 2015 at 10:04 PM, David Pilato david@pilato.fr wrote:

Have a look here. https://github.com/dadoonet/legacy-search

It's an Hibernate demo project which uses Spring as well.
If you navigate through branches, it will show you how to add
elasticsearch.

I won't try to connect Hibernate Search and replace Lucene implementation
by elasticsearch.

My 2 cents
David

Le 12 févr. 2015 à 00:18, William Yang williamyang93@gmail.com a
écrit :

Hi everyone,

I am new to the forum and I am also new to ElasticSearch!
However for this project, I am trying to replace HibernateSearch with
ElasticSearch. I am using Spring Framework, and I have also taken a look
at both Spring-ElasticSearch and Spring-Data-ElasticSearch. However, I
am still new to using these open source programs and don't really know
where I should start. I'd appreciate it if someone could give me a push in
the right direction on how to incorporate ElasticSearch into my code.
Thank you!

(I posted this on the archives so if this pops up twice I'm sorry!! I
didn't understand how this forum worked)

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the
Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr
https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-Pnid4LTy8ArhN6uqcTvH8LVDNt4MCCxrQmiYatAQxJNpQ%40mail.gmail.com
https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-Pnid4LTy8ArhN6uqcTvH8LVDNt4MCCxrQmiYatAQxJNpQ%40mail.gmail.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the
Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/B29F2368-4B2E-41F9-A84C-16519688106B%40pilato.fr
https://groups.google.com/d/msgid/elasticsearch/B29F2368-4B2E-41F9-A84C-16519688106B%40pilato.fr?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-P%3DA9DYE0m9zxmPPJ%3DZut_SG77ansxN9cdvkVJAykqzsEw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

I think you need to change:
https://github.com/dadoonet/legacy-search/blob/01-direct/src/main/resources/jdbc.properties https://github.com/dadoonet/legacy-search/blob/01-direct/src/main/resources/jdbc.properties
https://github.com/dadoonet/legacy-search/blob/01-direct/pom.xml#L88-L92 https://github.com/dadoonet/legacy-search/blob/01-direct/pom.xml#L88-L92

You can also look at this though it did not move for 2 years: https://github.com/55social/hibernate-search-elasticsearch-connector https://github.com/55social/hibernate-search-elasticsearch-connector

--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet https://twitter.com/dadoonet | @elasticsearchfr https://twitter.com/elasticsearchfr | @scrutmydocs https://twitter.com/scrutmydocs

Le 12 févr. 2015 à 08:05, William Yang williamyang93@gmail.com a écrit :

Oh I will be using MySQL in the future, right now I'm adding it upon AppFuse (which is a website that lets you log in, add users, and search for users).
So I guess, Yes, right now I am only using Hibernate search. What should I do about the postgresql part until I get to using MySQL?

And yes, when I said "run in Spring," I meant how to build it in the Spring Framework...there was an error (that I don't remember right now) that wouldn't let me compile it because a dependency was missing.

On Wed, Feb 11, 2015 at 10:25 PM, David Pilato <david@pilato.fr mailto:david@pilato.fr> wrote:
postgresql is a database. I guess you are using Hibernate with a database, right?
Unless you are using only Hibernate search?

What do you mean "run in Spring"?
Spring is the framework right?

mvn jetty:run should work fine

David

Le 12 févr. 2015 à 07:11, William Yang <williamyang93@gmail.com mailto:williamyang93@gmail.com> a écrit :

Hey David,

Thanks for responding - I found that link too and tried to follow it but I got confused what postgresql is. If I don't know what it is, where do I find it?
Also I think I had some problems with a common dependency, I don't have the exact error code on me right now, but there was something wrong with the dependency.

What would I put as the goal when I try to run it in spring? clean install, or just jetty:run?

On Wed, Feb 11, 2015 at 10:04 PM, David Pilato <david@pilato.fr mailto:david@pilato.fr> wrote:
Have a look here. https://github.com/dadoonet/legacy-search https://github.com/dadoonet/legacy-search

It's an Hibernate demo project which uses Spring as well.
If you navigate through branches, it will show you how to add elasticsearch.

I won't try to connect Hibernate Search and replace Lucene implementation by elasticsearch.

My 2 cents
David

Le 12 févr. 2015 à 00:18, William Yang <williamyang93@gmail.com mailto:williamyang93@gmail.com> a écrit :

Hi everyone,

I am new to the forum and I am also new to ElasticSearch!
However for this project, I am trying to replace HibernateSearch with ElasticSearch. I am using Spring Framework, and I have also taken a look at both Spring-ElasticSearch and Spring-Data-ElasticSearch. However, I am still new to using these open source programs and don't really know where I should start. I'd appreciate it if someone could give me a push in the right direction on how to incorporate ElasticSearch into my code. Thank you!

(I posted this on the archives so if this pops up twice I'm sorry!! I didn't understand how this forum worked)

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com mailto:elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com https://groups.google.com/d/msgid/elasticsearch/52ce9435-750d-41ef-a97a-a6561fea4368%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to elasticsearch+unsubscribe@googlegroups.com mailto:elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr https://groups.google.com/d/msgid/elasticsearch/EA2119B7-B656-4C5D-916A-C79D186C3336%40pilato.fr?utm_medium=email&utm_source=footer.

For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com mailto:elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-Pnid4LTy8ArhN6uqcTvH8LVDNt4MCCxrQmiYatAQxJNpQ%40mail.gmail.com https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-Pnid4LTy8ArhN6uqcTvH8LVDNt4MCCxrQmiYatAQxJNpQ%40mail.gmail.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to elasticsearch+unsubscribe@googlegroups.com mailto:elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/B29F2368-4B2E-41F9-A84C-16519688106B%40pilato.fr https://groups.google.com/d/msgid/elasticsearch/B29F2368-4B2E-41F9-A84C-16519688106B%40pilato.fr?utm_medium=email&utm_source=footer.

For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com mailto:elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-P%3DA9DYE0m9zxmPPJ%3DZut_SG77ansxN9cdvkVJAykqzsEw%40mail.gmail.com https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-P%3DA9DYE0m9zxmPPJ%3DZut_SG77ansxN9cdvkVJAykqzsEw%40mail.gmail.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/A7360115-29FD-489C-8EB7-403045A6E322%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

Hi again David,

The error that I get when trying to do jetty:run is:

[ERROR] Failed to execute goal on project legacy-search: Could not resolve
dependencies for project fr.pilato.demo:legacy-search:war:1.0-SNAPSHOT:
Could not find artifact commons-logging:commons-logging:jar:99-empty in
central (http://repo.maven.apache.org/maven2) -> [Help 1]

Do you know what's happening here?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/d51844a3-ee0a-4c4d-bdc5-3da78afea105%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

David,

I fixed the dependency problem - couldn't find the empty-99 commons-logging.

However, I'm getting this now:

11:18:46,164 WARN [JDBCExceptionReporter] SQL Error: 0, SQLState: null

11:18:46,164 ERROR [JDBCExceptionReporter] Cannot create
PoolableConnectionFactory (Connection refused. Check that the hostname and
port are correct and that the postmaster is accepting TCP/IP connections.)

11:18:46,164 WARN [SettingsFactory] Could not obtain connection to query
metadata

Is it because I'm trying to connect to the wrong database? If so, I have
MySQL on my computer, but I don't know how to incorporate it in the jbdc
properties you provided me. Where do I get the driverClassName and the url??

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/d6c6dc74-ee2d-4add-9989-a21bd76c3b8b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Hi David,
I managed to figure out the MySQL things!
I'm now getting these errors and I don't know why. I'm testing only an
empty database called "test", there aren't any tables in it:

11:43:10,397 ERROR [SchemaExport] Unsuccessful: alter table Person add
constraint FK8E4887752ACD7745 foreign key (marketing_id) references
Marketing

11:43:10,397 ERROR [SchemaExport] Cannot add foreign key constraint

11:43:10,523 ERROR [SchemaExport] Unsuccessful: alter table Person add
constraint FK8E488775BD8AD345 foreign key (address_id) references Address

11:43:10,523 ERROR [SchemaExport] Cannot add foreign key constraint

11:43:10,523 ERROR [SchemaExport] Unsuccessful: create sequence
hibernate_sequence

11:43:10,523 ERROR [SchemaExport] You have an error in your SQL syntax;
check the manual that corresponds to your MySQL server version for the
right syntax to use near 'sequence hibernate_sequence' at line 1

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/f12b9057-e17b-494a-bfaf-e9ca7c6e8906%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

I think you need to modify this line as well: https://github.com/dadoonet/legacy-search/blob/00-legacy/src/main/webapp/WEB-INF/person-dao-context.xml#L29 https://github.com/dadoonet/legacy-search/blob/00-legacy/src/main/webapp/WEB-INF/person-dao-context.xml#L29

--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet https://twitter.com/dadoonet | @elasticsearchfr https://twitter.com/elasticsearchfr | @scrutmydocs https://twitter.com/scrutmydocs

Le 12 févr. 2015 à 20:44, William Yang williamyang93@gmail.com a écrit :

Hi David,
I managed to figure out the MySQL things!
I'm now getting these errors and I don't know why. I'm testing only an empty database called "test", there aren't any tables in it:

11:43:10,397 ERROR [SchemaExport] Unsuccessful: alter table Person add constraint FK8E4887752ACD7745 foreign key (marketing_id) references Marketing

11:43:10,397 ERROR [SchemaExport] Cannot add foreign key constraint

11:43:10,523 ERROR [SchemaExport] Unsuccessful: alter table Person add constraint FK8E488775BD8AD345 foreign key (address_id) references Address

11:43:10,523 ERROR [SchemaExport] Cannot add foreign key constraint

11:43:10,523 ERROR [SchemaExport] Unsuccessful: create sequence hibernate_sequence

11:43:10,523 ERROR [SchemaExport] You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'sequence hibernate_sequence' at line 1

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com mailto:elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/f12b9057-e17b-494a-bfaf-e9ca7c6e8906%40googlegroups.com https://groups.google.com/d/msgid/elasticsearch/f12b9057-e17b-494a-bfaf-e9ca7c6e8906%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/30F9D287-F683-43B2-943A-EF5E9373EED7%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

I still need this line even though I want to replace Hibernate with
ElasticSearch?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/956c6735-3221-49d4-9e3e-b6ef2c2e89d1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Well. I thought you asked me to run the example I wrote.
If so, the example uses in 00-legacy branch a database, insert, get, delete (CRUD) and search using the database (with hibernate).
Branch 01-direct adds elasticsearch for the search part. Hibernate and the database is still used for CRUD operations.

--
David Pilato | Technical Advocate | Elasticsearch.com
@dadoonet https://twitter.com/dadoonet | @elasticsearchfr https://twitter.com/elasticsearchfr | @scrutmydocs https://twitter.com/scrutmydocs

Le 12 févr. 2015 à 21:00, William Yang williamyang93@gmail.com a écrit :

I still need this line even though I want to replace Hibernate with ElasticSearch?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com mailto:elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/956c6735-3221-49d4-9e3e-b6ef2c2e89d1%40googlegroups.com https://groups.google.com/d/msgid/elasticsearch/956c6735-3221-49d4-9e3e-b6ef2c2e89d1%40googlegroups.com?utm_medium=email&utm_source=footer.
For more options, visit https://groups.google.com/d/optout https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/5B4195C3-6498-4DCB-A58F-74CDF9F6FF01%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

Ah I see, I will try to go through the other branches as well.

However, when I try to do the CRUD operations (What does that stand for by
the way?), I get a

16:20:55,055 DEBUG [PersonRestAPI] create(1, )

16:20:55,055 DEBUG [PersonService] get(1)=null

Do you know the cause of that?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/e01521fd-fee5-4e21-b0c9-05cd50892fb5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

CRUD=Create, Read, Update, Delete

No. What exact operation did you run?

David

Le 13 févr. 2015 à 01:22, William Yang williamyang93@gmail.com a écrit :

Ah I see, I will try to go through the other branches as well.

However, when I try to do the CRUD operations (What does that stand for by the way?), I get a
16:20:55,055 DEBUG [PersonRestAPI] create(1, )

16:20:55,055 DEBUG [PersonService] get(1)=null

Do you know the cause of that?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/e01521fd-fee5-4e21-b0c9-05cd50892fb5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/4B3E165A-DC75-4462-BD46-A64739FFE710%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

I ran jetty:run on branch00.

I think that happened because when I used curl -XPUT, nothing happened.
However, when I initialized a database and it produced results, I was able
to use the search function.

On Thu, Feb 12, 2015 at 9:57 PM, David Pilato david@pilato.fr wrote:

CRUD=Create, Read, Update, Delete

No. What exact operation did you run?

David

Le 13 févr. 2015 à 01:22, William Yang williamyang93@gmail.com a écrit :

Ah I see, I will try to go through the other branches as well.

However, when I try to do the CRUD operations (What does that stand for by
the way?), I get a

16:20:55,055 DEBUG [PersonRestAPI] create(1, )

16:20:55,055 DEBUG [PersonService] get(1)=null

Do you know the cause of that?

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/e01521fd-fee5-4e21-b0c9-05cd50892fb5%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/e01521fd-fee5-4e21-b0c9-05cd50892fb5%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the
Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit
https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/4B3E165A-DC75-4462-BD46-A64739FFE710%40pilato.fr
https://groups.google.com/d/msgid/elasticsearch/4B3E165A-DC75-4462-BD46-A64739FFE710%40pilato.fr?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-PkNO1FHDte0A2KwhYgOX0mZfPiVURRe-TOb7ncc_iDwyQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

I meant "what exact curl command you run?"

David

Le 13 févr. 2015 à 07:17, William Yang williamyang93@gmail.com a écrit :

I ran jetty:run on branch00.

I think that happened because when I used curl -XPUT, nothing happened.
However, when I initialized a database and it produced results, I was able to use the search function.

On Thu, Feb 12, 2015 at 9:57 PM, David Pilato david@pilato.fr wrote:
CRUD=Create, Read, Update, Delete

No. What exact operation did you run?

David

Le 13 févr. 2015 à 01:22, William Yang williamyang93@gmail.com a écrit :

Ah I see, I will try to go through the other branches as well.

However, when I try to do the CRUD operations (What does that stand for by the way?), I get a
16:20:55,055 DEBUG [PersonRestAPI] create(1, )

16:20:55,055 DEBUG [PersonService] get(1)=null

Do you know the cause of that?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/e01521fd-fee5-4e21-b0c9-05cd50892fb5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "elasticsearch" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/elasticsearch/XfY9hJsKcOM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/4B3E165A-DC75-4462-BD46-A64739FFE710%40pilato.fr.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-PkNO1FHDte0A2KwhYgOX0mZfPiVURRe-TOb7ncc_iDwyQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/AFFA21AB-DE4E-4B9D-B2EA-053B71F2A439%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

I ran this part in cmd and nothing happened after I did jetty:run in Spring
for branch00

Create one person

curl -XPUT http://127.0.0.1:8080/api/1/person/1 -d '{"name":"David Pilato"}'

Read that person

curl http://127.0.0.1:8080/api/1/person/1

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-PknGA%3DUDAfZau6GOcjhjZfMyKuZ6HtAsiSnf%3D_t8%2B7mTA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Ok. But still the injection works? So you can start from here.
The REST part should not be a concern here as unrelated to your original question.

David

Le 13 févr. 2015 à 08:07, William Yang williamyang93@gmail.com a écrit :

I ran this part in cmd and nothing happened after I did jetty:run in Spring for branch00

Create one person

curl -XPUT http://127.0.0.1:8080/api/1/person/1 -d '{"name":"David Pilato"}'

Read that person

curl http://127.0.0.1:8080/api/1/person/1

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAHV%3D-PknGA%3DUDAfZau6GOcjhjZfMyKuZ6HtAsiSnf%3D_t8%2B7mTA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/D7157CC4-826B-493E-B5A4-13F3A5911206%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.

Couple other questions - where do I do this action?

Delete the index

DELETE person
Also, for some reason the advanced search isn't working..why is that? I am
on branch-04 right now

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/6bc6377b-c4dc-4f56-88ca-97f1d66db62a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

So I went through all of the branches. How do I begin to change my project
to ElasticSearch?

Do I just go through each branch to see what you changed in every single
one and then add the files to my project?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/8f04ff23-b5fe-4e37-830f-434050b55536%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.