How to install Jade over an acedb server

Jean Thierry-Mieg, CNRS

Tutorial for the ace97 workshop
Cornell, july 1997

Contents


Introduction

Jade is a JAVA program written in collaboration with Lincoln Stein to hook complex displays to arbitrary servers. The whole system will be described later in the week. The purpose of the present document is to explain how to install Jade as a front end to a running acedb server.

At this conference

Note that during this conference, daemons are already configured on moot, port 20100 (worm server, don t modify), 20110, 20120, 20130, 201040 and 20150. They point to /ace97/jadeclients/j1 to j5, these j1-5 clients are linked to a code that you could change, and they are called as
j3 -host moot -port 20000130
in turn port 20000130 is declared to run the server /ace97/t3 /ace97/t3/db and those are links that cam be modified to aceserver and to some database directory.

You can therefore modify the jade code and run on the worm server 20100 or modify the server code and link it at position s3 and have your own data in s3/db. Don t change the names, make links. so the inetd does not have to be reconfigured. If needed, we can add more services.

The Java classes

Somewhere on your disk space : mkdir jade , cd jade, and ftp in that position the the jade distribution file available at ncbi or during this conference in ~JThierry-Mieg/jade/distrib and open it.

This file contains the .jar classes, the source code, several tools and the applet documents that you should copy or edit. The important point is to copy/edit the applet worm.html

param name="netclient" value="moot.cadif.cornell.edu"
param name="port" value="20100"

to point to the webserver and port used by the jade2ace adaptor. NOT to the port and host used by the aceserver. Note also that the jade2ace adaptor MUST run on the webserver.

The magic of JAVA is that it works on all machines, so you do not have to recompile or select the correct binary.

Test

To test this installation type
appletviewer worm.html
the expected result is the appearance of the Jade applet which should blush red, beeing yet unable to connect to the server.

Configuration of the server

First of all, verify that the aceserver works by contacting it via aceclient. Then verify that the class jade is defined The model for class jade is part of the ace.4_5 binary. Then add the jade default object and read the standard jade.config.ace files which are part of the jade distrib.

Test

To test this installation, start an aceclient and type:

aceclient  -port 
acedb> Find Jade
acedb> show
acedb> edit ....  // to adjust the configuration
acedb> edit .... 
acedb> Find table
acedb> List      // there should be  a table called classes
acedb> table -n classses  // run this table by name
acedb> quit

Expected behaviour, a list of the visible classes.

The jade2ace adaptor

Recover, say from ncbi, either the source code or the precompiled binary for your machine, then make jade2ace if it is not in the bin file and remember the full path to this executable, you will need it for the daemoniac incantations.

Test

To test this installation, connect to the server using netclient

netclient -host acehost -port aceport
help
find model
show -c 3
quit

Expected behaviour, a copy of the model of the first three classes

Daemoniac declarations

You need to declare the jade2ace adaptor as a service on the webserver. To do this you should be root.
At the end of the file services, add the lines

## jad2xxx clients
jade1 20300/tcp

At the end of the file inetd.conf, add the lines
## jade clients
jade1  stream  tcp nowait myname /fulpathto/jade2ace jade2ace -host acehost -port aceport

where myname is your login name, acehost, aceport are the host and port of the acedb server you want to connect to. Note that you can declare several such services on the same webserver to connect to various aceservers. Using jade2xxx in place of jade2ace and configuring it correctly, not explained here, you can connect to flat files or to an SQL database.

Then HUP portmap and inetd.

Test

To verify, try
telnet webserver jade2aceport
example telnet moot 20100 Expected behaviour: the telnet line shouls answer
200 Ready and waiting
type say help, then quit If this does not work, verify your /etc files, hup again or reboot.

Semantic configuration

this will be a topic for later this week. Essentially, use tablemaker in xace to construct the tables that you need to pass to the jade displays, save these tables as acedb objetcs internally and declare them in the jade:default object

Expected behaviour, the java map display should work.

Adapt your own code

One of the ideas under jade is that it should be much easier to write your own display code in java than in C. We hope that some of this will happen at the workshop. A little bit of documentation is available in the README file and in the stub java class: jade/maps/Minimal.java

// Modified July 1997