XNAT OHIF Viewer Plugin 1.1.1
This plugin integrates the OHIF Cornerstone-based viewer into XNAT. It replaces previous support for the XimgViewer plugin.
A) Deploying the Pre-built plugin
New since 1.0.0: single plugin deployment.
-
Stop your tomcat with "sudo service tomcat7 stop"
-
Copy the dist/ohif-viewer-x.y.z-SNAPSHOT.jar plugin to the plugins folder for your XNAT installation. The location of the plugins folder varies based on how and where you have installed your XNAT. If you are running a virtual machine created through the XNAT Vagrant project, you can copy the plugin to the appropriate configuration folder and then copy it within the VM from /vagrant to /data/xnat/home/plugins.
-
sudo service tomcat7 start
B) (Optional) Initialising the viewer in a populated database
In the likely event you are installing this plugin on an XNAT with an already populated database, an admin may call the REST command POST XNAT_ROOT_URL/xapi/viewer/generate-all-metadata in order to initiate a process that will scour the database and generate metadata for every session. This process will use as many threads as are available on the server machine, but may take a long time. Note this step is not essential to use the viewer, however if this step is skipped the user will incur a delay when a particular experiment is displayed in the viewer for the first time.
Upgrading from 0.X.X
As of 1.0.0, the automatic JSON generation on session creation/modification is now handled by server side event handlers, and hosting the old VIEWER.war as a seperate application is no longer required.
If you are upgrading the plugin from 0.X.X:
- Deactivate any related automation scripts in the Administration/Automation interface.
- Remove the old VIEWER.war, the VIEWER is now included within the plugin jar.
- replace the old plugin jar with the new one.
Building (Note this is for developers and is not required to use the plugin)
To build the XNAT OHIF viewer plugin
-
If you haven't already, clone this repository and cd to the newly cloned folder.
-
Build the plugin:
./gradlew clean fatjar
On Windows, you can use the batch file:
gradlew.bat clean fatjar
This should build the plugin in the file build/libs/ohif-viewer-plugin-X.X.X-SNAPSHOT.jar Note: the fatjar command is currently required as EtherJ.jar is not currently hosted in a place gradle can find it, this will change in the future. The viewer application itself (src/main/resources/META-INF/resources/VIEWER) is a custom build of a modified OHIF viewer (https://github.com/JamesAPetts/OHIF-Viewer-XNAT/tree/xnat-prod).