Getting started and installing ofbiz

Source: Internet
Author: User

1. ofbiz Introduction: Ofbiz (http://ofbiz.apache.org) is apache e-commerce platform, make full use of apache Open Source project, such as Tomcat, Ant, BeanShell, Jboss, etc, building a powerful system platform, Ofbiz has completed all the functions required by the e-commerce platform, such as user authentication, workflow, transaction rule processing, etc. The core technology of Ofbiz lies in Entity Engine, other components are based on it. In short, Entity Engine provides powerful encapsulation of database table creation, object-to-data table ing, and object query, you can define the database table structure in a simple XML file. Ofbiz will automatically help you create tables in the database and dynamically generate ing objects. You can only process objects in the program, ofbiz is automatically updated to the database through the transaction logic. One of the advantages Ofbiz claims is that it uses a small amount of Code to complete complex processing.
2. Ofbiz download and installation first install J2SDK1.6, download to the http://java.sun.com, after installation set JAVA_HOME environment variable to J2SDK installation directory. Visit the website http://ofbiz.apache.org, there is a download connection, please select the corresponding to the latest stable version, download and unlock after you can run.

3. ofbiz configure mysql database
First, create the database ofbiz in MySQL.
Update the JDBC driver and copy the jdbc driver of mysql to the $ {ofbiz-install-dir}/framework/entity/lib/jdbc directory.
Set the default database of the Entity Engine to mysql. modify the configuration in the $ {ofbiz install dir}/framework/entity/config/entityengine. xml file:
Modify database connection parameters:
<Datasource

Helper-class = "org. ofbiz. entity. datasource.
GenericHelperDAO"
Field-type-name = "mysql"
Check-on-start = "true"
Add-missing-on-start = "true"
Check-pks-on-start = "false"
Use-foreign-keys = "true"
Join -"
Collate =
<Read-data reader-name = "seed"/>
<Read-data reader-name = "seed-initial"/>
<Read-data reader-name = "demo"/>
<Read-data reader-name = "ext"/>
<Inline-jdbc
Jdbc-driver = "com. mysql. jdbc. Driver"
Jdbc-uri = "jdbc: mysql ://? AutoReconnect = true "--
Jdbc-username =
Jdbc-password =
Isolation-level = "ReadCommitted"
Pool-minsize = "2"
Pool-maxsize = "250"
Time-between-eviction-runs-millis = "600000"/> <! -- #### -->
<! -- <Jndi-jdbc jndi-server-name = "localjndi" jndi-name = "java:/MySqlDataSource" isolation-level = "Serializable"/> -->
</Datasource>

Modify the default database configuration of the entity engine as follows: Set datasource-name to localmysql:
<! -- The connection factory class to use, one is needed for obtaining connections/pools for defined resources -->
<Connection-factory class = "org. ofbiz. entity. connection. DBCPConnectionFactory"/>

<Delegator name = "default"
Entity-model-reader = "main"
Entity-group-reader = "main"
Entity-eca-reader = "main"
Distributed-cache-clear-enabled = "false">
<Group-map group-name = "org. ofbiz"
Datasource-name = ""/>
<Group-map group-name = "org. ofbiz. olap"
Datasource-name = ""/>
</Delegator>

<Delegator name = "default-no-eca"
Entity-model-reader = "main"
Entity-group-reader = "main"
Entity-eca-reader = "main"
Entity-eca-enabled = "false"
Distributed-cache-clear-enabled = "false">
<Group-map group-name = "org. ofbiz"
Datasource-name = ""/>
<Group-map group-name = "org. ofbiz. olap"
Datasource-name = ""/>
</Delegator>

<! -- Be sure that your default delegator (or the one you use) uses the same datasource for test. You must run "ant run-install" before running "ant run-tests" -->
<Delegator name = "test"
Entity-model-reader = "main"
Entity-group-reader = "main"
Entity-eca-reader = "main">
<Group-map group-name = "org. ofbiz"
Datasource-name = ""/>
<Group-map group-name = "org. ofbiz. olap"
Datasource-name = ""/>
</Delegator>

<Delegator name = "other"
Entity-model-reader = "main"
Entity-group-reader = "main"
Entity-eca-reader = "main">
<Group-map group-name = "org. ofbiz"
Datasource-name = ""/>
</Delegator>

4. Compile and run ofbiz
Open dos and execute the command in the ofbiz9 directory:

Startofbiz. bat

After the startup is successful, you can open the following interface:
Http: // localhost: 8080/ecommerce;
Https: // localhost: 8443/webtools;

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.