ERP 2.50:Openbravo.properties
Contents |
Introduction
Several parameters should be configured for Openbravo to work correctly. These parameters can be configured through a graphical interface using the setup tool or by hand.
Contents
The content of this file include:
Date/time format
Define the date and time formats:
- dateFormat.js: date format used in Javascript controls.
- dateFormat.sql: date format used in the SQL controls.
- dateFormat.java: date format used by Java. For a list of possible values check the official documentation.
- dateTimeFormat.java: date and time format used by Java. For a list of possible values the URL above.
- dateTimeFormat.sql: date and time format used in the SQL controls.
![]() | After changing any of those properties above a complete re-compilation must be done, a smartbuild is not sufficient. This is needed as those values are incorporated in various generated files. |
General
- web.url: static content URL. Use the default value (@actual_url_context@/web) to make it dynamic. Don't change this unless you know what you are doing
- context.url: full URL of the context, only used by the Web Services installation
- attach.path: Absolute path to the attachments directory.
- source.path: root sources directory, used by modularity.
- application.version: Openbravo ERP version, shown in the about box.
- context.name:: context name, used in the final war file.
- deploy.mode: how the context will be deployed into the servlet container. Valid options: war, class, none.
In war mode a war file is created in lib/${context.name}.war. In class mode only the modified files are deployed into ${catalina.base}/webapps/${context.name}. In none mode everything the servlet container need is copied into the $OB_ROOT/WebContent directory, and no war is generated and no files are copied to the servlet container. This is useful for working with Eclipse.
Database
- bbdd.rdbms: name of the chosen database. Possible values:
- Oracle: ORACLE
- PostgreSQL: POSTGRE
- bbdd.driver: the JDBC driver, this depends on the chosen database. Possible values:
- Oracle: oracle.jdbc.driver.OracleDriver
- PostgreSQL: org.postgresql.Driver
- bbdd.url: the JDBC URL of the database. Possible values:
- Oracle: jdbc:oracle:thin:@ip_address:port:SID (e.g. jdbc:oracle:thin:@localhost:1521:XE)
- PostgreSQL: jdbc:postgresql://ip_address:port (e.g. jdbc:postgresql://localhost:5432)
- bbdd.sid: the SID in Oracle and the database name in PostgreSQL (in lowercase).
- bbdd.systemUser: the name of the database superuser. Usually it's system in Oracle and postgres in PostgreSQL.
- bbdd.systemPassword: the password of the database superuser.
- bbdd.user: the name of the user owner of the Openbravo ERP database.
- bbdd.password: the password of the bbdd.user.
- bbdd.sessionConfig: additional options passed to the session. Currently this is mandatory. Possible values:
- Oracle: ALTER SESSION SET NLS_DATE_FORMAT='DD-MM-YYYY' NLS_NUMERIC_CHARACTERS='.,'
- PostgreSQL: select update_dateFormat('DD-MM-YYYY')
- java.security.egd: As reported in issue #12683, Oracle DB in some Linux boxes can delay on getting connection to database. This affects to build process, making it much slower. In these cases this property can be set to file:///dev/urandom which solves the problem.
Tomcat Manager
- tomcat.manager.url: URL to the Tomcat Manager, in the form http://ip_address[:port]/manager
- tomcat.manager.username: Tomcat Manager user name.
- tomcat.manager.password: Tomcat Manager password.
Development parameters
Parameters specially useful for developers.
- bbdd.outputscript: path of the file generated by the update.database.script or create.database.script ant tasks.
- bbdd.verbosity: log info level displayed by the database ant tasks. Possible values: ERROR, INFO, WARN, DEBUG.
- generateSprites: option to generate CSS sprites. This means that instead of having many little images there is one one big image, and every image is selected specifying its coordinates in the CSS files. Do not use this unless you're using Firefox 3.1 or Internet Explorer 7. Possible values: yes, no.
- minimizeJSandCSS: option to compress the CSS files. They are smaller and therefore faster. But the files are almost unreadable, so they are not useful for the development. Use it in production systems only. Possible values: yes, no.
Authentication
authentication.class: property used configure the authentication manager. Possible values:
- Default Authentication Manager: This is the default authentication manager that provides the classic login page. Class name org.openbravo.authentication.basic.DefaultAuthenticationManager.
- LAM Authentication Manager: This is the authentication manager used for Single Sign-on. Class name org.openbravo.authentication.lam.LamAuthenticationManager.
- Autologon Authentication Manager: This is an authentication manager for demostration purposes. Class name org.openbravo.authentication.basic.AutologonAuthenticationManager.
This is an example using the default authentication manager.
authentication.class=org.openbravo.authentication.basic.DefaultAuthenticationManager #authentication.class=org.openbravo.authentication.lam.LamAuthenticationManager #authentication.class=org.openbravo.authentication.basic.AutologonAuthenticationManager #authentication.autologon.username=Openbravo
Add-ons
- pentahoServer: URL to an external Pentaho Server. This is optional.
Hibernate
- hibernate.hbm.file: if this property is set then the hibernate mapping will be written to the file defined by this property, note the value should be the complete path including the file name and extension.
Safe mode
- safe.mode: activates or deactivates the safe mode. When safe mode is activated, if the last build wasn't succesful, the user will receive a warning when he tries to log in (if he has System Administrator priviledges), or he will receive an error (if he doesn't).
Log in security
These properties are explained in detail in Log in security document.
- login.trial.delay.increment: Time delay increment before checking user/password after log in failed.
- login.trial.delay.max: Maximum delay before checking user/password after log in failed.
- login.trial.user.lock: Number of user/password failed before locking user.
Others
- allow.root: By default you are not allowed to run ant commands with the root user. Set this to true to override this. Available from 2.50MP21.
Edition
Openbravo.properties is a plain text file that you can edit manually by duplicating the Openbravo.properties.template file or using the graphical assistant (wizard).
To configure it using the wizard, first run the ant setup command to download the setup tool that matches your operating system and architecture:
cd openbravo-root ant setup
Then, go to the config/ directory and run the setup-properties tool. For example, in Linux:
cd openbravo-root/config ./setup-properties-linux.bin
Note: If there is no setup binary for your operating system and architecture, send a request to <staff.rm at openbravo dot com>.
Old configuration
This file is used for configuring the 2.40 and 2.50 versions. In the 2.3x version it only used for some ant database tasks.
The r2.3x version also requires configuring three additional files:
build.xml
- context.name:: Name of the Tomcat context.
- attach.path: absolute path where the attachments will be stored.
- web.url:: URL used to access the static content (i.e., images, css, javascripts) of the application. If not sure, write '@actual_url_context@/web'.
config/dbCon5.xml
This file stores the database connection data used during compilation. The URL parameter has the format: 'CONNECTOR:USER/PASSWORD@SERVER:PORT:SID'. This is an example: 'jdbc:oracle:thin:user/password@localhost:1521:xe'. Each of this parameters is explained below:
- CONNECTOR: The one used to connect to the database.
- USER/PASSWORD: Database user and password. This user does not need sysdba role.
- SERVER: The server where the database is. This could be an IP, the name of the machine or localhost if the database is in the same machine.
- PORT: Port to which the database server is listening.
- SID: Database SID.
config/XmlPool.xml
This file stores the database connection data used during execution. The parameters are the same as those of config/dbCon5.xml, but grouped in different order.