Skip to content

hanhsuan/estimateCVRiskRESTAPI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

estimateCVRiskRESTAPI

purpose

Using C to expose R package estimateCVRisk to REST API. Writing this just for fun without all error handling that needed, please don't use in production environment. Other examples about using C to call R function could find here.

container

Building container:

sudo docker build -t [image tag] .

Using container:

sudo docker run -d -p [host port]:[api port] [image tag] [api port]

nerdctl and podman are ok too.

simple test

API test command:

curl -X POST -d '@[payload file name with path]' -H "Content-Type: application/json" http://[IP]:[api port]

DIY

If someone would like to compile this, could follow Dockerfile to setup environment. However, C stack warning message might show, the following command could temperately set to unlimited on debian-like.

sudo prlimit --stack=unlimited --pid $$; ulimit -s unlimited

About

use c to expose estimateCVRisk to REST API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published