I have released the initial version of the WebAPI project to GitHub. This is a source only release, there are no release packages. To leverage this release you will need to clone the repository and build the source using a maven compatible IDE. I’m currently using NetBeans. The readme file on GitHub has been updated to reflect the necessary build and configuration steps.
I’m looking forward to feedback and contributions to this API as the project moves forward. I’ll be releasing the first version of HERMES soon. HERMES will be the first application to leverage the VocabularyService of the WebAPI.
Nice work @Frank . I was able to clone the project and build it with maven. @ajmazurie and I plan test a configuration on the knowledge base dev server. Would you please add in the WebAPI README a couple of example REST calls to vocabulary we could make for testing purposes?
I’ve deployed @Frank 's cool WebAPI services as a demo on the OHDSI development server.
This deployment of the WebAPI is connected to database views that only show data from unrestricted vocabularies on the OHDSI dev server postgres vocabulary V5 database, so there should be no issues in making it publicly available.
It’s running in a tomcat docker container.
Here are the URLs (based on Frank’s examples) if you would like to try it out:
It’s currently a manual process to set the DBMS connection configuration in the WebAPI web.xml file, build the latest WebAPI war file in Netbeans on my local computer and then copy it over to the docker server.
Basically the dockerfile just copies the war file and jdbc driver file into the right directories in a docker container that’s based off the standard tomcat docker image. It’s simple but quite powerful. I can simultaneously run multiple copies of the WebAPI on the same server in separate docker tomcat instances with different configurations (including different DBMSs) for development/unit testing/production, mapping the exposed docker containers port to different host ports in the docker run command.
I’m not sure if the Dockerfile belongs in the WebAPI project on github because it’s more of a deployment/operational detail - docker is NOT a dependency for running the WebAPI. So for now I’ll just post the Dockerfile contents below:
# use the standard docker tomcat image as the base image for this image
FROM tomcat
MAINTAINER Lee Evans <levans@ohdsi.org>
# Install the WebAPI WAR file to the tomcat webapps directory
ADD WebAPI.war /usr/local/tomcat/webapps/
# Install the postgresql jdbc driver to the tomcat lib directory
ADD postgresql-9.3-1102.jdbc3.jar /usr/local/tomcat/lib/
# expose the standard tomcat port to the host
EXPOSE 8080
# Start the Tomcat web server (which will auto install the above WAR file)
CMD /usr/local/tomcat/bin/catalina.sh run