A microservice for accessing the TSimulus time series generator.
10K+
A microservice for accessing the TSimulus time series generator.
This project intend to provide a micro-service that exposes the features of the TSimulus library through a simple HTTP connection.
It provides a runnable JAR file that contains an Akka-based microservice.
> java -jar tsimulus-ws.jar -h 0.0.0.0 -p 8001
This command will ask the service to listen to incoming connections on port 8001 from any client. Replace 0.0.0.0 by localhost for limiting the access to the service to clients running on your machine.
Once running, the service can be accessed by submitting POST request to port 8001:
The syntax of JSON documents is described in the TSimulus library documentation.
You can also retrieve the Docker image which contains the Tsimulus microservice. The Docker image has been created with a Dockerfile.
docker pull ceticasbl/tsimulus-ms
sudo docker run --name tsimulus-ms -ti -p 8001:8001 -d ceticasbl/tsimulus-ms
When it's done, as explained in the previous section "How to use it?", the service can be accessed by submitting POST request to port 8001.
It exists also a docker image for 64-bit ARM architecture. The docker image has been created with the Dockerfile from the arm64 folder.
docker pull ceticasbl/tsimulus-ms-arm64
sudo docker run --name tsimulus-ms-arm64 -ti -p 8001:8001 -d ceticasbl/tsimulus-ms-arm64
You can also run the microservice with OpenShift. For that, we use Kubernetes files which can be found in the kubernetes folder. In your OpenShift project, first, create the Kubernetes deployment:
oc create -f tsimulus-deployment.yml
Then, create the Kubernetes service:
oc create -f tsimulus-service.yml
Finally, create a route by exposing the service tsimulus-ms.
oc expose service tsimulus-ms
Now the service is accessible at http://tsimulus-ms-tsimulus.apps.10.2.2.2.xip.io/. When it's done, as explained in the first section "How to use it?", the service can be accessed by submitting POST request to port 8001.
Content type
Image
Digest
Size
273.9 MB
Last updated
over 6 years ago
docker pull ceticasbl/tsimulus-ms