Heads up! These docs are for Portofino 3, which is a legacy product. Check out Portofino 4!

To configure Portofino you must create a portofino-custom.properties file and save it in your application server's classpath.

Application server

 Typical portofino-custom.properties directory

 Tomcat 5.5

 CATALINA_HOME/common/classes/

 Tomcat 6

 CATALINA_HOME/lib/

 JBoss

 JBOSS_HOME/server/default/conf/

 Glassfish

 GLASSFISH_HOME/domains/domain1/lib/classes/

 OC4J

 ORACLE_HOME/j2ee/home/applib/

Alternatively, you can save portofino-custom.properties in the WEB-INF/classes directory of your deployed war file. This works on all application servers. However it requires that you already have a deployed application.


The following sections show the minimal content of portofino-custom.properties to start the application in various database environments.

Postgresql

database.jdbc.driverClass=org.postgresql.Driver
database.jdbc.connectionURL=jdbc:postgresql://localhost:5432/portofinodb
database.jdbc.username=username
database.jdbc.password=password


Oracle

database.jdbc.driverClass=oracle.jdbc.driver.OracleDriver
database.jdbc.connectionURL=jdbc:oracle:thin:@localhost:1521:portofinodb
database.jdbc.username=username
database.jdbc.password=password


SqlServer

database.jdbc.driverClass=com.microsoft.sqlserver.jdbc.SQLServerDriver
database.jdbc.connectionURL=jdbc:sqlserver://localhost:1433;databaseName=portofinodb;
database.jdbc.username=username
database.jdbc.password=password


Db2

database.jdbc.driverClass=com.ibm.db2.jcc.DB2Driver
database.jdbc.connectionURL=jdbc:db2://localhost:50000/portofinodb
database.jdbc.username=username
database.jdbc.password=password


Mysql

database.jdbc.driverClass=com.mysql.jdbc.Driver
database.jdbc.connectionURL=jdbc:mysql://localhost/portofinodb?characterEncoding=UTF-8&useUnicode=true&sessionVariables=sql_Mode=ANSI
database.jdbc.username=username
database.jdbc.password=password


Derby

With Derby, a database is just a directory containing a number of files. Derby can create the directory and files for you. All you need to do is to decide where the directory will be located (e.g., '/path/to/portofinodb') and provide the following configuration:

database.jdbc.driverClass=org.apache.derby.jdbc.EmbeddedDrive
database.jdbc.connectionURL=jdbc:derby:/path/to/portofinodb;create=true
database.jdbc.username=username
database.jdbc.password=password


Customize the values to your database and installation. Then save the file to a directory that is visible by the application server's classpath.




Previous: Installing the JDBC driver

Next: Deploying on Tomcat