Generator

Using the Generator

Create custom Omniscope files and exportable DataPlayers - automatically on demand

Note: unlike most of our applications, the Generator is not a general-use application and some development skill is required to be able to use it. In addition, you will need a machine running a web server, such as Apache, and an application container, such as Apache TomCat, in order to be able to use it.

The Omniscope Enterprise Generator automates the creation and deployment of on-demand, personalised snapshots of database views/tables as Omniscope files, including exportable .SWF DataPlayers. The Generator allows on-demand generation of Omniscope files (including exportable SWF DataPlayers files) using a pre-defined Omniscope file configured as a template for future refreshed and personalised files.

 

Generator installation:

The Generator is part of the Omniscope application, so you will need to have that installed and an Enterprise licence in order to be able to run it. If you wish to run the Generator as a service, please see the instructions on the Windows Services page.

Once you have done this, you should see the Visokio Enterprise service available in your services list in Control Panel and the Generator should be able to accept connections. You can check this by visiting http://localhost:8301/servicecheck.txt which should give you a positive message rather than an error. Once this happens you are ready to send requests to the Generator.

 

Generator Toolkit: 

We have prepared a toolkit for Java applications containing utility methods for connecting to the server, a servlet implementation, source code, JavaDoc and an example servlet application to load data from SQLServer into an .IOK file on demand. You can download the toolkit here.

 

Generator Implementation:

The Generator uses the HTTP protocol to receive requests, so you can use any type of web service to access it. The general information the Generator requires is shown below:

The Generator HTTP request takes the form of a http post with a multi-part type to:

 

http://localhost:8301

 

with the following parameters:

  • templateIok a multipart request file containing an IOK "template" file configured to look the way you want the final file to appear. This should be binary data with MIME type "application/vnd.visokio.omniscope-iok"
  • templateIom (alternative for IOM files - depending on your needs and/or license), MIME type "application/vnd.visokio.omniscope-iom"
  • applyHistory a boolean string option, default "false", to re-apply any structural changes to the updated data
  • dataXml which is another multipart request file containing the data in the xml format specified at http://www.visokio.com/xmldata/ 
Examples of how these are used can be seen in the SQLServer example application in the toolkit.

 

Generator Example: 

If you would like to see the Generator in action and you have a SQLServer database and an Apache Tomcat web server you can deploy the SQLServer example in the toolkit as a web application on your server. Once it is deployed you will need to edit the conf.xml file in the WEB-INF directory of the application (usually in C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\SqlServer\WEB-INF on Windows) to make it contain your database connection settings. 

Once you have set it all up as described above you can visit the url:

 

http://localhost/servlet/{name_of_table_or_view}.iok

 

For example, if your table was called "test_table", the URL would be http://localhost:8080/SqlServer/servlet/test_table.iok. 

In addition, if you wish to change the template file which is used to create the iok file, you can place a template iok file in the templates folder called "test_table.iok". This file will then be automatically used to create the template.

Please note that this is only an example and a database is not required to use the Generator.