/cdi-resteasy-hibernate-angularjs-tomcat-sample

Airports [Sample] - Java EE / CDI / RestEasy / Hibernate / AngularJS

Primary LanguageJava

cdi-resteasy-hibernate-angularjs-tomcat-sample

Sample application with full CRUD for Airport codes to showcase following technologies:

  • Java 7
  • CDI
  • RestEasy (JAX-RS)
  • JPA / Hibernate
  • AngularJS
  • Bootstrap
  • Maven (build)

Setup

  • Use your favorite IDE to deploy and run the application.
  • Use maven command to deploy to Tomcat. NOTE: maven settings.xml need to be configured with your local server.
$ mvn tomcat7:deploy

Access

  • via browser using url:
http://localhost:8080/sample 

Alt text

  • via REST client using url:
GET http://localhost:8080/sample/api/airpots
GET http://localhost:8080/sample/api/airpots/123 (using id)
GET http://localhost:8080/sample/api/airpots/NYC (using code)
GET http://localhost:8080/sample/api/airpots/search/Wash (using text) 
POST http://localhost:8080/sample/api/airpots
PUT http://localhost:8080/sample/api/airpots
DELETE http://localhost:8080/sample/api/airpots/123 (using id)