 |
Blandware AtLeap Installation Instructions
Common preliminary steps
- Read SoftwareRequirements and install which you need.
Install Java applications into directories without spaces e.g. C:\Program files\
- Set a
JAVA_HOME environment variable which points at your Java Development Kit installation e.g. set JAVA_HOME=C:\java\jdk1.5.0_02
- Configure your JVM (Java Virtual Machine) see JavaConfiguration
- Set an
ANT_HOME environment variable which points at your Apache Ant installation e.g. set ANT_HOME=C:\java\apache-ant-1.6.5
- Download the latest version of Blandware AtLeap https://atleap.dev.java.net/servlets/ProjectDocumentList
- Unpack distributive using proper util e.g. WinZip under Windows or unzip under Unix.
- Run all below commands from directory into which you unpack AtLeap 1 Possibly under Unix you should run
chmod a+x bin/*.sh
- Check the correctness of each file using command
bin\build.bat check-md5 for Windows or bin/build.sh check-md5 for Unix AtLeap provides build.xml file for Apache Ant and you can use it directly to perform some Ant task e.g. ant check-md5. Additionally AtLeap provides OS dependent bin scripts BAT for Windows and Shell for Unix. It provides extra checks for Java and Ant. I recommend to use them ever if possible. For simplicity below we will write bin/build for both OS.
Blandware AtLeap Quick start of demo
AtLeap has embeded Hypersonic DBMS and Jetty servlet-container. They are for demonstration purposes. I do not recommend you to use them in production mode for performance and stability reasons.
- In order to run demo version of AtLeap merely type
bin/start-demo
- In order to shutdown server with AtLeap demo type
bin/stop-demo
Configuring for one of supported Application Servers
- Set a home enviroment variable of your application server e.g.
CATALINA_HOME, RESIN_HOME, JBOSS_HOME etc. which points at your servlet container e.g. C:\java\jakarta-tomcat-5.5.9
- If you plan to use Security Manager configure your application server policy file according SecurityConfiguration
- Confugure properties in
build.properties file according instructions in it. It is recommended to create atleap-build.properties file in the same directory which will override properties from build.properties file and keep build.properties untouched.
- Specify
appserver.host correctly.
- Comment out the properties of default application server Jetty in Jetty section.
- Uncomment properties from section of required application server. As minimum you need to uncomment:
-
appserver.type
-
appserver.http.port
-
appserver.https.port
- Other properties should be uncommented only in special circumstances
Please be sure that all paths configured in Directory Properties section have write permissions to user under which you run your container.
Database configuration
In order to enable some DBMS please uncomment all properties from the section of required DBMS and configure them correctly.
if you have the database created by previous version of AtLeap please drop it and create again.
MySQL configuration
- For MySQL 4.1 and above you should run mysql daemon with parameter
--default-character-set=utf8
- MySQL is the DBMS which provide facility to add database dynamically if you have admin rights. In this case you can run
bin/build setup and script make all work for you. Otherwise
- Ask your administrator to create DB for you
- Create DB tables, using command
bin/build db-prepare
- Load initial data, using command
bin/build db-load
- Cleans, undeploy and re-deploy application
bin/build refresh
PostgreSQL configuration
- Be sure that PostgreSQL is listening on TCP/IP
- Create unicode database manually or ask your administrator
- Create DB tables, load initial data, cleans, undeploy and re-deploy application
bin/build setup
Oracle configuration
- AtLeap distributive does not include Oracle JDBC driver, please download it from the site http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html
- Rename JAR accroding
lib/lib.properties file e.g. ojdbc14-10.1.0.jar (or change version number in lib/lib.properties file)
- Put JAR into appropriate dir according
lib/lib.properties file e.g. lib/ojdbc-10.1.0
- Create Oracle user and schema and give all required permissions to it
- Create DB tables, load initial data, cleans, undeploy and re-deploy application
bin/build setup
Derby (NetworkServer) configuration
- AtLeap distributive does not include Derby JDBC driver, please download Derby from the site http://db.apache.org/derby/derby_downloads.html and get
lib/derbyclient.jar
- Rename JAR accroding
lib/lib.properties file e.g. derbyclient-10.1.1.0.jar (or change version number in lib/lib.properties file)
- Put JAR into appropriate dir according
lib/lib.properties file e.g. lib/derbyclient-10.1.1.0
- Run Derby network server
- Create DB tables, load initial data, cleans, undeploy and re-deploy application
bin/build setup
Derby (Embedded) configuration
- AtLeap distributive does not include Derby JDBC driver, please download Derby from the site http://db.apache.org/derby/derby_downloads.html and get
lib/derby.jar
- Rename JAR accroding
lib/lib.properties file e.g. derby-10.1.1.0.jar (or change version number in lib/lib.properties file)
- Put JAR into appropriate dir according
lib/lib.properties file e.g. lib/derby-10.1.1.0
- Cleans, undeploy and re-deploy application
bin/build refresh (DB tables will be created and initial data will be loaded automatically during deployment)
MS SQL configuration
- AtLeap distributive does not include MS SQL JDBC driver, please download open source jTDS driver from the site http://jtds.sourceforge.net/
- Rename JAR accroding
lib/lib.properties file e.g. jtds-1.1.jar (or change version number in lib/lib.properties file)
- Put JAR into appropriate dir according
lib/lib.properties file e.g. lib/jtds-1.1
- Create MS SQL database and user for it
- Create DB tables, load initial data, cleans, undeploy and re-deploy application
bin/build setup
IBM DB2 configuration
- AtLeap distributive does not include DB2 JDBC driver, you can get it from your DB2 installation e.g.
IBM/SQLLIB/java e.g. db2jcc.jar, db2jcc_license_cisuz.jar and db2jcc_license_cu.jar
- Rename main JAR accroding
lib/lib.properties file e.g. db2jcc-8.2.jar (or change version number in lib/lib.properties file)
- Put all JARs into appropriate dir according
lib/lib.properties file e.g. lib/db2jcc-8.2
- Create DB2 database and user for it
- Create DB tables, load initial data, cleans, undeploy and re-deploy application
bin/build setup
Not all Servlet Containers support more than one JAR as JDBC driver. It can be helpful to pack contents of all 3 jars into one.
Other database configuration
- Download JDBC driver
- Create a record in the
lib/lib.properties file
- Put the driver into directory which you have just specified in
lib/lib.properties file
- Make a record in
build.properties file according driver documentation, Hibernate documentation and DBUnit documentation
- Create a database if it required
- Create DB tables, load initial data, cleans, undeploy and re-deploy application
bin/build setup
Start your AS if it is not started and open http://localhost:8080/atleap in your browser.
Troubleshooting
Errors during deployment
Tomcat has a bug with deployment of big WAR (Web archive) and AtLeap is big WAR. If you get one of the following errors during atleap deployment
-
Missing application web.xml
-
cannot create JDBC driver of class ' ' for connect URL 'null'
-
Error deploying application at context path null
- or something like
do the following steps:
- Stop tomcat
- Specify
deploy.force.unpack=true property in your build.properties file
-
bin/build refresh
- Start tomcat
Out of memory
If you see the "Out of memory" error during compiling AtLeap it means you should allow to JVM to allocate more memory. You can do it in ANT_OPTS environment variable.
If you see the "Out of memory" during work of your Application Server you should allow to Application Server's JVM to allocate more memory. Read details in JavaConfiguration.
Out of memory: PermGen space
If you see the "Out of memory: PermGen space" during work of your Application Server you should allow to Application Server's JVM to allocate more memory for classes and methods data. Read details in JavaConfiguration.
Could not reserve enough space for object heap
If you see the "Could not reserve enough space for object heap" error during compiling AtLeap it means you should decrease the memory size which is available to JVM. You can do it in ANT_OPTS environment variable.
If you see the "Could not reserve enough space for object heap" during work of your Application Server you should decrease the memory size which is available to Application Server's JVM. Read details in JavaConfiguration.
Please carefully read documentation and release notes of your servlet container to avoid extra problems. For example Tomcat under Linux recommends to define LD_ASSUME_KERNEL environment variable equal to the kernel version (e.g. 2.4.1).
-- AndreyGrebnev - 04 July 2006
|