Giter Site home page Giter Site logo

webservice's Introduction

webservice

Hello,

This webservice is developed with Spring boot as a base.

A small controller is defined to meet the following requirements.(https://github.com/shakeelabbas1/webservice/blob/master/src/main/java/com/service/controller/ServiceRequestController.java)

"localhost:8080/handleJson" OR "localhost:8080/handleParam" to recieve payload. It does reply with a response with confirmation. "localhost:8080/getAll" to get all the messages persisted in database.

Cosumer thread to read messages from Redis and save it to database is defined here https://github.com/shakeelabbas1/webservice/blob/master/src/main/java/com/service/threads/ConsumerThread.java

A websocket listener can be acccessed by pasting below URL. http://localhost:8080/

Real time messages can be seen here http://localhost:8080/realTimeMessages.html

How to make all this work.

  1. Start the docker
  2. Start postgresql using below command sudo docker run --name some-postgres -e POSTGRES_PASSWORD=mysecretpassword -d postgres
  3. Start redis using below command sudo docker run --name some-redis -d redis
  4. Start a new container with java8 installed
  5. Get the IP address of postgresql and fill here https://github.com/shakeelabbas1/webservice/blob/master/src/main/resources/application.properties
  6. Get the IP address of Redis and fill here https://github.com/shakeelabbas1/webservice/blob/master/src/main/resources/beans.xml
  7. Build and run the Spring boot jar.

webservice's People

Contributors

shakeelabbas1 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.