Skip to content

A simple example for Spring Boot + ElasticSearch

Notifications You must be signed in to change notification settings

eljo/elasticuser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

elasticuser

A very simple demo that models users stored in an ElasticSearch backend, exposed via Spring Data REST along with an integration test.

Building

Use ./mvnw clean package to run the (rather non-existant) unit tests, integration tests and to create the JAR and docker image.

Examples

(see also: Building a RESTful Web Service)

Create an user:

curl -i -X POST -H "Content-Type:application/json" -d '{"email": "[email protected]", "firstName": "foo", "lastName": "bar"}' http://localhost:8080/users

List users:

curl http://localhost:8080/users

Create/Update an user:

curl -i -X PUT -H "Content-Type:application/json" -d '{"email": "[email protected]", "firstName": "car", "lastName": "bar"}' http://localhost:8080/users/[email protected]

Delete an user:

curl -i -X DELETE http://localhost:8080/users/[email protected]

About

A simple example for Spring Boot + ElasticSearch

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published