Skip to content

manojfaria/neo4j-employees-java-bolt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Neo4j Employees Example Application

This is a sample application demonstrating Employees APIs built using javaspark framework and accessing neo4j content on the backend.

Technology Stack

These are the components of sample Employee Application:

  • Application Type: RESTful API

  • Web framework: Spark-Java (Micro-Webframework)

  • Neo4j Database Connector: Neo4j-Java-Driver for Cypher Docs

  • Database: Neo4j-Server (You may use your own neo4j instance OR Sandbox instance provided by neo4j)

  • Frontend: <coming soon>

Employee API Endpoints:

Listed below are the API endpoints for this sample application.

// list all employees
curl http://localhost:4567/employees

// Add an employee
curl -X POST -H "Content-Type: application/json" -d '{ "id":"1", "name":"Manoj Faria" }' http://localhost:4567/employees
Hint: On Windows you may have to escape the double quotes and replace the single quotes by double quotes.

// list employee using empid
curl http://localhost:4567/employees/1

Execution Instructions:

Ensure your local neo4j instance (or sandbox neo4j instance) is running.

Change the neo4j connection info (i.e. servername, port number, userid and password) in EmployeeApp.java to match your neo4j instance.

Build the jar file (target\Employee-0.0.1-SNAPSHOT-jar-with-dependencies.jar) using the below stated command:

mvn package

Start the application using:

java -jar target\Employee-0.0.1-SNAPSHOT-jar-with-dependencies.jar

Go to http://localhost:4567/employees or try out any of the curl statements listed above.

About

This is a sample application demonstrating an Employees APIs built using javaspark framework and accessing neo4j content on the backend.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages