Project

General

Profile

Feature #1572

using p2j/testcases/simple/* as a guide/template, please create a runtime configuration that can be used to run chemtutor

Added by Greg Shah almost 12 years ago. Updated over 11 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Costin Savin
Target version:
-
Start date:
09/24/2012
Due date:
% Done:

100%

billable:
No
vendor_id:
GCD
version_reported:
version_resolved:

Related issues

Blocked by Core Development - Feature #1571: create a bash script to automate the process of creating an H2 database for chemtutor and importing its base data set Closed 09/24/2012

History

#1 Updated by Greg Shah almost 12 years ago

The result should use the H2 DB that is created by your script in #1571. For that reason, this task is dependent upon it. The idea is to make it easy for someone to run the chemtutor application. Please note: we want to start the chemtutor app directly when a user connects, we don't want to use ask.p.

Ask questions of Adrian and Constantin as needed.

#2 Updated by Costin Savin over 11 years ago

  • Status changed from New to WIP

#3 Updated by Greg Shah over 11 years ago

I haven't taken a close look yet, but I do see some things that need to be cleaned up:

1. Please remove log files and other extraneous files (e.g. NewFile.xml or terminfo.src.vt320.20060907_patch) that are not needed.

2. Please remove all the jar files from the project. Create a script (or an ANT target) to copy the jar files at deployment time from a directory. That directory can be specified as a parameter to the script.

#4 Updated by Costin Savin over 11 years ago

For p2j location a link is created to the p2j location and added inside the chemtutor project as p2j and can be accessed as chemtutor/p2j.
Is this ok to be used?
The libs with the jars are temporary they should be copied there from p2j location but p2j.jar contained the testcases package it should be created separately to exclude this package.

#5 Updated by Greg Shah over 11 years ago

You can use the ./p2j/ path. Don't encode the top-level chemtutor directory in anything.

The libs with the jars are temporary they should be copied there from p2j location but p2j.jar contained the testcases package it should be created separately to exclude this package.

I don't understand. The jars are there in bazaar. I would like the build to copy them dynamically from the current p2j/ instead of residing in bazaar. Otherwise we always have to remember to update/delete/add jars in 2 places, p2j and chemtutor. That is not the point of the chemtutor project.

#6 Updated by Costin Savin over 11 years ago

Cleaned up the unnecessary jar files and log files.
Client and server scripts + directory configuration under /deploy-chemtutor/server /deploy-chemtutor/server.
Important build script tasks:

ctconvert - this will convert the chemtutor progress source code to java
deploy.init.db - this will handle building filling and indexing the h2 database with the available data.The database file is put inside /deploy-chemtutor/db
jar - this creates the chemtutor.jar under /build/lib from the converted source code.
p2j-jar - this will call the jar target from the p2j project which will build all the jars from p2j project
p2j-deploy-exclude-testcases this builds the p2j.jar excluding the com.goldencode.testcases package which conflicts with the ones from chemtutor.jar
deploy.chemtutor - this will copy chemtutor.jar, the necessary files from p2j project and the p2j.jar which doesn't contain the testcases package to /deploy-chemtutor/lib , it also calls the database.init.db
dist - this will call deploy.chemtutor and archives the chemtutor-deploy directory contents to chemtutor${timestamp}.tar inside the distribution directory

#7 Updated by Greg Shah over 11 years ago

I see a problem with chemtutor/deploy-chemtutor/server/stdsrvkey.store.

Please look inside that file. You will find references to TIMCO inside! Please create new key(s), CA and a store file as needed to replace this file. You will have to update the directory too. You can follow the process documented in the P2J Runtime Installation, Configuration and Administration Guide.

#8 Updated by Greg Shah over 11 years ago

Updated build.xml and configuration files to meet requirements. Started working on readme.html and generating different stdservkey.store
Tried to generate it with openssl but the result look different from initial stdservkey.store do you know how it is generated? Also there is an entry inside directory.xml:
<node class="container" name="certificates">
   <node class="container" name="cas">
      <node class="bytes" name="chemtutor-root">
         <node-attribute name="value" value="...snip..."/>
      </node>
   </node>
...
what exactly does the value represent? 

Both the certificates in the directory (there must be at least 2) and the stdsrvkey.store are created using the processes described in the P2J Runtime Installation, Configuration and Administration Guide. Follow the instructions in Part 2 for the chapters "Certificate Authority" and "Key-Stores and Trust-Stores". You must follow both processes.

The value in certificates/cas/... are certificate authorities. In certificates/peers/.. are the per-server certificates.

#9 Updated by Costin Savin over 11 years ago

The syntax of the command line from Certificate Authority which is supposed to load the /security/certificates/cas/<application-->-root is not correct:
java -Xmx256m com.goldencode.p2j.util.LoadCert -config ./server.xml /security/certificates/cas/acme-root /var/ssl/acme-root-ca-cert.pem

This syntax doesn't work (probably deprecated)
after some look in the code for parameters the run configuration that worked is:
java -cp ../lib/p2j.jar com.goldencode.p2j.util.LoadCert server.xml - /security/certificates/cas/chemtutor-root /var/ssl/chemtutor-root-ca-cert.pem for chemtutor when run from the server directory
The Certificate Authority chapter should probably have to be updated.

#10 Updated by Greg Shah over 11 years ago

Please update the documentation to fix the problem.

#11 Updated by Greg Shah over 11 years ago

  • Status changed from WIP to Review

#12 Updated by Greg Shah over 11 years ago

  • Status changed from Review to New
  • % Done changed from 0 to 100

#13 Updated by Greg Shah over 11 years ago

  • Status changed from New to Closed

Also available in: Atom PDF