Difference between revisions of "The MIRC Module"
Line 29: | Line 29: | ||
==The MIRC Configuration File== | ==The MIRC Configuration File== | ||
+ | |||
+ | The <b><tt>MIRC</tt></b> plugin and the three TFS pipelines are configured in the <b><tt>config.xml</tt></b> file, but all the other configuration information for a TFS site is contained in the <b><tt>mirc.xml</tt></b> file, located in the root of the plugin (typically <b><tt>CTP/mircsite</tt></b>). | ||
+ | |||
+ | <pre> | ||
+ | <mirc | ||
+ | UI="integrated" | ||
+ | addresstype="dynamic" | ||
+ | date="2012.12.23 at 09:28:28 CST" | ||
+ | disclaimerurl="" | ||
+ | downloadenb="yes" | ||
+ | email="johnperry@dls.net" | ||
+ | masthead="ChildrensLogo2.jpg" | ||
+ | mastheadheight="109" | ||
+ | mode="rad" | ||
+ | popup="login" | ||
+ | roles="department" | ||
+ | rsnaVersion="Z97" | ||
+ | sharestats="yes" | ||
+ | showptids="yes" | ||
+ | showsitename="yes" | ||
+ | siteid="1343228846573" | ||
+ | sitename="JP's Teaching Files" | ||
+ | siteurl="http://192.168.0.4:80" | ||
+ | timeout="7" | ||
+ | version="Z105"> | ||
+ | <Libraries> | ||
+ | <Library | ||
+ | address="/storage/ss4" | ||
+ | authenb="yes" | ||
+ | autoindex="no" | ||
+ | dcmenb="yes" | ||
+ | deflib="no" | ||
+ | enabled="yes" | ||
+ | id="ss4" | ||
+ | jpegquality="-1" | ||
+ | local="yes" | ||
+ | maxsize="100" | ||
+ | subenb="yes" | ||
+ | tceenb="yes" | ||
+ | timeout="0" | ||
+ | zipenb="yes"> | ||
+ | <title>JP's MIRC Storage Service</title> | ||
+ | <tagline/> | ||
+ | </Library> | ||
+ | <Library | ||
+ | address="/storage/ss1" | ||
+ | authenb="yes" | ||
+ | autoindex="no" | ||
+ | dcmenb="yes" | ||
+ | deflib="yes" | ||
+ | enabled="yes" | ||
+ | id="ss1" | ||
+ | jpegquality="-1" | ||
+ | local="yes" | ||
+ | maxsize="75" | ||
+ | subenb="yes" | ||
+ | tceenb="yes" | ||
+ | timeout="0" | ||
+ | zipenb="no"> | ||
+ | <title>My MIRC Site</title> | ||
+ | <tagline/> | ||
+ | </Library> | ||
+ | <Library | ||
+ | address="http://mirc.childrensmemorial.org/storage/ss12" | ||
+ | deflib="no" | ||
+ | enabled="yes" | ||
+ | local="no"> | ||
+ | <title>CMH: Children's Memorial Hospital General Pediatric Cases</title> | ||
+ | </Library> | ||
+ | <Library | ||
+ | address="http://147.140.2.19:8080/storage/ss2" | ||
+ | deflib="no" | ||
+ | enabled="yes" | ||
+ | local="no"> | ||
+ | <title>Thomas Jefferson University Hospital - Neuro</title> | ||
+ | </Library> | ||
+ | </Libraries> | ||
+ | <FileService | ||
+ | maxsize="75" | ||
+ | timeout="0"/> | ||
+ | <news> | ||
+ | <title>20110902 DX CHEST STUDY</title> | ||
+ | <image> | ||
+ | /storage/ss4/docs/20121002065223174/9999.68816769595213868527999756405838373430_base.jpeg | ||
+ | </image> | ||
+ | <url>/storage/ss4/docs/20121002065223174/MIRCdocument.xml</url> | ||
+ | </news> | ||
+ | </mirc> | ||
+ | </pre> | ||
==The MIRC Base Servlet== | ==The MIRC Base Servlet== |
Revision as of 17:08, 3 January 2013
UNDER CONSTRUCTION
The MIRC module (MIRC.jar) contains the code of the CTP plugin that implements TFS, the RSNA Teaching File System. This article describes the theory of operation of the packages and files contained in the MIRC module. The intended audience for this article is software engineers extending or maintaining any of that software.
See Setting Up a MIRC Development Environment for information on obtaining and building the MIRC module. It will be helpful to get the source code and build it so you can reference the Javadocs as you go along.
1 Overview
The MIRC module contains many packages. In general, major system functions (as well as some minor ones) are encapsulated in their own packages, but because many functions interact, this principle is not universally maintained. Most system functions have classes and files that are contained in the jar file. Often, the files are XSL programs used for the generation of web pages or Javascript and CSS files referenced by the web pages. These files are served directly from the jar file without having to be installed on the disk. See The Util Module for a description of how the server serves files from the classpath.
2 The TFS-installer
The TFS-installer uses the same installer program as CTP. It includes a full installation of CTP, but it includes a different config.xml file snd additional libraries.
To prevent the loss of site-specific configuration information, the installer does not overwrite the config.xml file during an upgrade installation. The standard TFS config.xml file includes the MIRC plugin and pipelines for the File Service, the DICOM Service, and the TCE Service.
The additional libraries include the Apache XML libraries because the standard Java XML libraries don't support passing DOM objects as parameters to XSL transforms. This capability is used widely in TFS, but not CTP, so they are only included in the TFS installer.
3 The MIRC Plugin
All the code for TFS is included in the MIRC plugin, including all the servlets, the TFS-specific pipeline stages, and many XSL, Javascript, CSS, image, and files. The plugin is loaded when CTP loads the configuration, and it is started after the server is started but before any of the pipelines are started.
The root attribute of the MIRC plugin's configuration file element defines the root directory of all the TFS files. The default location is mircsite under the CTP directory, but it can be changed if it is desired to locate the teaching files on another drive or network system. Because the installer never overwrites any of the teaching file information, in most cases it is safe in the CTP directory tree.
When the plugin is started, it loads various databases and adds all the TFS servlets to the server. It also ensures that if the admin user exists, it has the author, publisher, and department roles. Finally, it rebuilds the RadLex index (if necessary), and starts several daemon threads to monitor the status of non-local libraries (LibraryMonitor), draft documents (DraftDocumentMonitor)), and the activity report submission process that sends information on the site to the RSNA (SummarySubmitter).
When CTP shuts down, the MIRC plugin receives a shutdown method call, which triggers the closing of all the databases.
4 The MIRC Configuration File
The MIRC plugin and the three TFS pipelines are configured in the config.xml file, but all the other configuration information for a TFS site is contained in the mirc.xml file, located in the root of the plugin (typically CTP/mircsite).
<mirc UI="integrated" addresstype="dynamic" date="2012.12.23 at 09:28:28 CST" disclaimerurl="" downloadenb="yes" email="johnperry@dls.net" masthead="ChildrensLogo2.jpg" mastheadheight="109" mode="rad" popup="login" roles="department" rsnaVersion="Z97" sharestats="yes" showptids="yes" showsitename="yes" siteid="1343228846573" sitename="JP's Teaching Files" siteurl="http://192.168.0.4:80" timeout="7" version="Z105"> <Libraries> <Library address="/storage/ss4" authenb="yes" autoindex="no" dcmenb="yes" deflib="no" enabled="yes" id="ss4" jpegquality="-1" local="yes" maxsize="100" subenb="yes" tceenb="yes" timeout="0" zipenb="yes"> <title>JP's MIRC Storage Service</title> <tagline/> </Library> <Library address="/storage/ss1" authenb="yes" autoindex="no" dcmenb="yes" deflib="yes" enabled="yes" id="ss1" jpegquality="-1" local="yes" maxsize="75" subenb="yes" tceenb="yes" timeout="0" zipenb="no"> <title>My MIRC Site</title> <tagline/> </Library> <Library address="http://mirc.childrensmemorial.org/storage/ss12" deflib="no" enabled="yes" local="no"> <title>CMH: Children's Memorial Hospital General Pediatric Cases</title> </Library> <Library address="http://147.140.2.19:8080/storage/ss2" deflib="no" enabled="yes" local="no"> <title>Thomas Jefferson University Hospital - Neuro</title> </Library> </Libraries> <FileService maxsize="75" timeout="0"/> <news> <title>20110902 DX CHEST STUDY</title> <image> /storage/ss4/docs/20121002065223174/9999.68816769595213868527999756405838373430_base.jpeg </image> <url>/storage/ss4/docs/20121002065223174/MIRCdocument.xml</url> </news> </mirc>