jabrena / spring-boot-and-r-language

A repository to explore how to interact with R from Java with Spring Boot
Apache License 2.0
1 stars 0 forks source link
data-science java r-language spring-boot statistics

Spring Boot & R Stat Server

Java CI

Cloud IDEs:


Motivation

A repository to explore how to interact with R from Java with Spring Boot in order to use both programming languages to extract knowledge from data samples.

Features

How to run the project from Spring Boot

docker compose build
./mvnw spring-boot:run -Dspring-boot.run.profiles=dev
./mvnw spring-boot:run -Dspring-boot.run.profiles=prod

curl "http://localhost:8080/"
curl -v http://localhost:8080/download/employee.csv

How to run the project from Docker compose

docker compose build
docker compose up -d --profile dev
docker compose up -d --profile prod

curl "http://localhost:3000/"
curl "http://localhost:3000/echo"
curl "http://localhost:3000/echo?msg=hello"
curl "http://localhost:3000/plot"
curl "http://localhost:3000/sum" -H "Content-Type: application/json" --data '{"a":4, "b":5}' 

#Swagger from Plumber
open http://localhost:3000/__docs__/

docker compose down

RStudio:

open http://localhost:8787/

References

Previous works:

Made with ❤️ from Madrid