MaximizerDatabase/com4j client/server design
From LeonWiki!
Purpose
Isolate Maximizer database access so that all db access code lives on the database server. By doing this, we allow any applications anywhere, access to any Maximizer database.
Description
We are using com4j to access the COM components provided by Maximizer that allow calls on the database. COM is not a distributed technology and hence can't make calls to other components on the network. We are going to use groovy (which is a scripting language running on top of java), since it is so easy to create a client/server using it. Also, since it runs on top of java, it has access to all the java libraries and runtimes.
Implementation
- Client/Server setup
- svn branches for development
- maxdb_com4j_server
- maxdb_com4j_client
- groovy MaxDbRemote server to run on database machine
- makes calls to MaximizerDatabase class, which in turn calls com4j objects
- groovy MaxDbClient running anywhere
- Any client app can remotely access Maximizer database by calling MaxDbClient.groovy
- svn branches for development
- Client apps setup/refactor to make calls to MaxDbClient
- Presently one app (renewalSoft) that needs slight refactoring. (implement client on server1, accessing prod max db on sym01)
- svn branches for development
- maxdb-groovy-client-server
- Steps to get renewalSoft to call the MaxDbClient.groovy
- delete MaximizerDatabase from renewalSoft version control (it will now be part of maxdb_com4j_server)
- modify renewalDatabase.py to call the groovy client script 'MaxDbClient'
- call groovy script engine from renewalDatabase.py passing the script 'MaxDbClient' (jython script -- should be easy as jython speaks java
- move theData class (which is in MaximizerDatabase -- can't return user-defined types via XML-RPC) to renewalDatabase.py
- implement code in renewalDatabase to take a map<String,String> and load theData objects from that Map (returned by groovy client script)
- svn branches for development
- Presently one app (renewalSoft) that needs slight refactoring. (implement client on server1, accessing prod max db on sym01)
