Author: jleroux
Date: Sat Jan 29 23:35:01 2011 New Revision: 1065144 URL: http://svn.apache.org/viewvc?rev=1065144&view=rev Log: A slightly modified patch from Pierre Smits "Some misc issues in ebayStore component." (https://issues.apache.org/jira/browse/OFBIZ-3971) - OFBIZ-3971 This patch enables users to create new tenants via the ANT process. Users can enter: * Tenant ID * Tenant Name * Data to load on creation of the tenant db (e.g.seed, seed-ext, demo) * Database Platform (Derby, MySQL, Oracle, PostgreSQL) remark: You can NOT mix platforms) * IP address of the database (you can add a port if needed) * User-ID for the database * Password for the database Based on the data provided the process will: * Create a new row in the Tenant table * Create a new row in the TenantDataSource table * Create new tables in the new tenant database and fill with initial data (seed, seed-ext, demo) * Create a new admin id for the tenant (based on Tenant ID followed by '-admin') * Set the initial password for the tenant admin id (initial 'ofbiz', must be changed on first login) This patch has been tested against: Derby, MySQL, PostgreSQL. This has not been tested against other db platforms. Prior to running the ANT task the user * has to modify 'general.properties' in framework/common/config to reflect multi tenancy (multitenant=Y) * has to have appropriate db driver(s) in place * has to create the databases first in function of the entityengine.xml datasource-names (not for Derby, applicable for MySQL and PostgreSQL.) Added: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml (with props) ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml (with props) ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml (with props) ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml (with props) Modified: ofbiz/trunk/build.xml ofbiz/trunk/framework/entity/config/entityengine.xml Modified: ofbiz/trunk/build.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/build.xml?rev=1065144&r1=1065143&r2=1065144&view=diff ============================================================================== --- ofbiz/trunk/build.xml (original) +++ ofbiz/trunk/build.xml Sat Jan 29 23:35:01 2011 @@ -419,6 +419,193 @@ under the License. <arg value="file=${data-file}"/> </java> </target> + + <!-- ================================= + target: run-create-tenant + ================================= --> + <target name="run-create-tenant" + depends="create-tenant-on-Derby,create-tenant-on-MySQL,create-tenant-on-Oracle,create-tenant-on-PostgreSQL" + description="This build script creates a new tenant in your environment, creates the delegator, and loads initial data (needs multitenant=Y in general.properties)"> + <tstamp/> + </target> + + <target name="get-tenant-data" + description="This creates entity Tenant and TenantDataSource in default, installs data in the delegator and creates the admin-user and password for the tenant"> + <input addproperty="tenantId" message="Enter Id for the tenant: "/> + <input addproperty="tenantName" message="Enter name for tenant: "/> + <input addproperty="data-readers" message="Enter data to install. + Choices are e.g. seed,seed-initial,ext,demo. + Multipe datasets must be separated with a comma: "/> + <input addproperty="db-Platform" message="Select your default database platform, D = Derby,M = MySQL, O = Oracle, P = PostgreSQL" + validargs="D,M,O,P"/> + <echo message="Please make sure that the driver of the platform is installed and that the databases have been created (in function of the entityengine.xml datasource-names)"/> + <input addproperty="db-IP" message="Enter IP address of the database server (you may add a port number)"/> + <input addproperty="db-User" message="Enter userID of database user: "/> + <input addproperty="db-Password" message="Enter password of database user: "/> + <condition property="isDerby"> + <equals arg1="${db-Platform}" arg2="D"/> + </condition> + <condition property="isMySQL"> + <equals arg1="${db-Platform}" arg2="M"/> + </condition> + <condition property="isOracle"> + <equals arg1="${db-Platform}" arg2="O"/> + </condition> + <condition property="isPostgreSQL"> + <equals arg1="${db-Platform}" arg2="P"/> + </condition> + <antcall target="tenant-data-entry"/> + </target> + <target name="create-tenant-on-Derby" depends="get-tenant-data" + description="Creates tenant data and instance" if="isDerby"> + <echo message="Installing on Derby"/> + <copy file="${basedir}/framework/resources/templates/AdminNewTenantData-Derby.xml" tofile="runtime/tmp/tmpTenantData.xml"> + <filterset> + <filter token="tenantId" value="${tenantId}"/> + <filter token="tenantName" value="${tenantName}"/> + </filterset> + </copy> + <antcall target="run-install-file"> + <param name="data-file" value="runtime/tmp/tmpTenantData.xml"/> + </antcall> + <delete file="runtime/tmp/tmpTenantData.xml"/> + <antcall target="load-tenant-data-readers"/> + <antcall target="load-tenant-admin-user-login"> + <param name="userLoginId" value="${tenantId}-admin"/> + <param name="delegatorId" value="default#${tenantId}"/> + </antcall> + </target> + <target name="create-tenant-on-MySQL" depends="get-tenant-data" + description="Creates tenant data and instance. Don't forget db driver(s) and already created DBs in function of the entityengine.xml datasource-names" if="isMySQL"> + <echo message="Installing on MySQL"/> + <copy file="${basedir}/framework/resources/templates/AdminNewTenantData-MySQL.xml" tofile="runtime/tmp/tmpTenantData.xml"> + <filterset> + <filter token="tenantId" value="${tenantId}"/> + <filter token="tenantName" value="${tenantName}"/> + <filter token="db-IP" value="${db-IP}"/> + <filter token="db-User" value="${db-User}"/> + <filter token="db-Password" value="${db-Password}"/> + </filterset> + </copy> + <antcall target="run-install-file"> + <param name="data-file" value="runtime/tmp/tmpTenantData.xml"/> + </antcall> + <delete file="runtime/tmp/tmpTenantData.xml"/> + <antcall target="load-tenant-data-readers"/> + <antcall target="load-tenant-admin-user-login"> + <param name="userLoginId" value="${tenantId}-admin"/> + <param name="delegatorId" value="default#${tenantId}"/> + </antcall> + </target> + <target name="create-tenant-on-Oracle" depends="get-tenant-data" + description="Creates tenant data and instance. Don't forget db driver(s) and already created DBs in function of the entityengine.xml datasource-names" if="isOracle"> + <echo message="Installing on Oracle"/> + <copy file="${basedir}/framework/resources/templates/AdminNewTenantData-Oracle.xml" tofile="runtime/tmp/tmpTenantData.xml"> + <filterset> + <filter token="tenantId" value="${tenantId}"/> + <filter token="tenantName" value="${tenantName}"/> + <filter token="db-IP" value="${db-IP}"/> + <filter token="db-User" value="${db-User}"/> + <filter token="db-Password" value="${db-Password}"/> + </filterset> + </copy> + <antcall target="run-install-file"> + <param name="data-file" value="runtime/tmp/tmpTenantData.xml"/> + </antcall> + <delete file="runtime/tmp/tmpTenantData.xml"/> + <antcall target="load-tenant-data-readers"/> + <antcall target="load-tenant-admin-user-login"> + <param name="userLoginId" value="${tenantId}-admin"/> + <param name="delegatorId" value="default#${tenantId}"/> + </antcall> + </target> + <target name="create-tenant-on-PostgreSQL" depends="get-tenant-data" + description="Creates tenant data and instance. Don't forget db driver(s) and already created DBs in function of the entityengine.xml datasource-names" if="isPostgreSQL"> + <echo message="Installing on PostgreSQL"/> + <copy file="${basedir}/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml" tofile="runtime/tmp/tmpTenantData.xml"> + <filterset> + <filter token="tenantId" value="${tenantId}"/> + <filter token="tenantName" value="${tenantName}"/> + <filter token="db-IP" value="${db-IP}"/> + <filter token="db-User" value="${db-User}"/> + <filter token="db-Password" value="${db-Password}"/> + </filterset> + </copy> + <antcall target="run-install-file"> + <param name="data-file" value="runtime/tmp/tmpTenantData.xml"/> + </antcall> + <delete file="runtime/tmp/tmpTenantData.xml"/> + <antcall target="load-tenant-data-readers"/> + <antcall target="load-tenant-admin-user-login"> + <param name="userLoginId" value="${tenantId}-admin"/> + <param name="delegatorId" value="default#${tenantId}"/> + </antcall> + </target> + <target name="tenant-data-entry" + description="displays tenant data"> + <echo>------------------------------------</echo> + <echo message="tenantId = ${tenantId}"/> + <echo>tenantName = ${tenantName}</echo> + <echo>db-Platform = ${db-Platform}</echo> + <echo>db-IP = ${db-IP}</echo> + <echo>db-User = ${db-User}</echo> + <echo>db-Password = ${db-Password}</echo> + <echo>------------------------------------</echo> + <echo>database for tenant data will be 'ofbiz_${tenantId}'</echo> + <echo>database for tenant olap data will be 'ofbizolap_${tenantId}</echo> + <echo message="Please make sure that the driver of the platform is installed and that the databases have been created (Check names just above)"/> + <echo>------------------------------------</echo> + <input addproperty="continueYN" message="Continue Y or N" validargs="N,n,Y,y"/> + + </target> + <target name="load-tenant-admin-user-login" + description="Creates the admin login for the tenant with admin privileges, and a temporay password equal to 'ofbiz'. Password must be changed on first login"> + <echo>------------------------------------</echo> + <echo message="Installing the admin for the tenant"/> + <echo message="Delegator = ${delegatorId}"/> + <echo message="Tenant admin = '${userLoginId}'"/> + <echo message="Password for tenant admin is 'ofbiz' must change on first login"/> + <echo>------------------------------------</echo> + <input addproperty="continueYN" message="Continue Y or N" validargs="N,n,Y,y"/> + <copy file="${basedir}/framework/resources/templates/AdminUserLoginData.xml" tofile="runtime/tmp/tmpUserLogin.xml"> + <filterset> + <filter token="userLoginId" value="${userLoginId}"/> + </filterset> + </copy> + <antcall target="run-tenant-install-file"> + <param name="data-file" value="runtime/tmp/tmpUserLogin.xml"/> + <param name="delegatorId" value="${delegatorId}"/> + </antcall> + <delete file="runtime/tmp/tmpUserLogin.xml"/> + </target> + <target name="load-tenant-data-readers" + description="Loads data of given data-readers in the tenant database"> + <echo>------------------------------------</echo> + <echo message="Loading selected data-readers in tenant databaset"/> + <echo message="Delegator = default#${tenantId}"/> + <echo message="Data-readers = ${data-readers}"/> + <echo>------------------------------------</echo> + <input addproperty="continueYN" message="Continue Y or N" validargs="N,n,Y,y"/> + <java jar="ofbiz.jar" fork="true"> + <jvmarg value="${memory.initial.param}"/> + <jvmarg value="${memory.max.param}"/> + <jvmarg value="${memory.maxpermsize.param}"/> + <arg value="install"/> + <arg value="readers=${data-readers}"/> + <arg value="delegator=default#${tenantId}"/> + </java> + </target> + <target name="run-tenant-install-file" + description="Loads the data of the tenant using the command line argument 'file' to load data from a given file"> + <java jar="ofbiz.jar" fork="true"> + <jvmarg value="${memory.initial.param}"/> + <jvmarg value="${memory.max.param}"/> + <jvmarg value="${memory.maxpermsize.param}"/> + <arg value="install"/> + <arg value="file=${data-file}"/> + <arg value="delegator=${delegatorId}"/> + </java> + </target> <target name="load-admin-user-login" description="Creates a user login with admin privileges and a temporary password equal to 'ofbiz'; after a succesful login the user will be prompted for a new password. Example command for the userLogin 'admin': ./ant load-admin-user-login -DuserLoginId=admin"> <fail message="userLoginId parameter is required. To add the parameter to the command for user admin: -DuserLoginId=admin"> Modified: ofbiz/trunk/framework/entity/config/entityengine.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entity/config/entityengine.xml?rev=1065144&r1=1065143&r2=1065144&view=diff ============================================================================== --- ofbiz/trunk/framework/entity/config/entityengine.xml (original) +++ ofbiz/trunk/framework/entity/config/entityengine.xml Sat Jan 29 23:35:01 2011 @@ -53,11 +53,23 @@ access. For a detailed description see t <group-map group-name="org.ofbiz" datasource-name="localderby"/> <group-map group-name="org.ofbiz.olap" datasource-name="localderbyolap"/> <group-map group-name="org.ofbiz.tenant" datasource-name="localderbytenant"/> + <!-- <group-map group-name="org.ofbiz" datasource-name="localmysql"/> + <group-map group-name="org.ofbiz.olap" datasource-name="localmysqlolap"/> + <group-map group-name="org.ofbiz.tenant" datasource-name="localmysqltenant"/> --> + <!-- <group-map group-name="org.ofbiz" datasource-name="localpostnew"/> + <group-map group-name="org.ofbiz.olap" datasource-name="localpostolap"/> + <group-map group-name="org.ofbiz.tenant" datasource-name="localposttenant"/> --> </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="localderby"/> <group-map group-name="org.ofbiz.olap" datasource-name="localderbyolap"/> <group-map group-name="org.ofbiz.tenant" datasource-name="localderbytenant"/> + <!-- <group-map group-name="org.ofbiz" datasource-name="localmysql"/> + <group-map group-name="org.ofbiz.olap" datasource-name="localmysqlolap"/> + <group-map group-name="org.ofbiz.tenant" datasource-name="localmysqltenant"/> --> + <!-- <group-map group-name="org.ofbiz" datasource-name="localpostnew"/> + <group-map group-name="org.ofbiz.olap" datasource-name="localpostolap"/> + <group-map group-name="org.ofbiz.tenant" datasource-name="localposttenant"/> --> </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" --> @@ -65,6 +77,12 @@ access. For a detailed description see t <group-map group-name="org.ofbiz" datasource-name="localderby"/> <group-map group-name="org.ofbiz.olap" datasource-name="localderbyolap"/> <group-map group-name="org.ofbiz.tenant" datasource-name="localderbytenant"/> + <!-- <group-map group-name="org.ofbiz" datasource-name="localmysql"/> + <group-map group-name="org.ofbiz.olap" datasource-name="localmysqlolap"/> + <group-map group-name="org.ofbiz.tenant" datasource-name="localmysqltenant"/> --> + <!-- <group-map group-name="org.ofbiz" datasource-name="localpostnew"/> + <group-map group-name="org.ofbiz.olap" datasource-name="localpostolap"/> + <group-map group-name="org.ofbiz.tenant" datasource-name="localposttenant"/> --> </delegator> <!-- need to at least define a name for each component to use --> @@ -320,6 +338,66 @@ access. For a detailed description see t For more look at http://markmail.org/thread/5sivpykv7xkl66px and http://commons.apache.org/dbcp/configuration.html--> <!-- <jndi-jdbc jndi-server-name="localjndi" jndi-name="java:/MySqlDataSource" isolation-level="Serializable"/> --> </datasource> + <datasource name="localmysqlolap" + 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-style="ansi-no-parenthesis" + alias-view-columns="false" + drop-fk-use-foreign-key-keyword="true" + table-type="InnoDB" + character-set="latin1" + collate="latin1_general_cs"> + <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://127.0.0.1/ofbizolap?autoReconnect=true" + jdbc-username="ofbiz" + jdbc-password="ofbiz" + isolation-level="ReadCommitted" + pool-minsize="2" + pool-maxsize="250" + time-between-eviction-runs-millis="600000"/><!-- Please note that at least one person has experienced a problem with this value with MySQL + and had to set it to -1 in order to avoid this issue. + For more look at http://markmail.org/thread/5sivpykv7xkl66px and http://commons.apache.org/dbcp/configuration.html--> + <!-- <jndi-jdbc jndi-server-name="localjndi" jndi-name="java:/MySqlDataSource" isolation-level="Serializable"/> --> + </datasource> + <datasource name="localmysqltenant" + 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-style="ansi-no-parenthesis" + alias-view-columns="false" + drop-fk-use-foreign-key-keyword="true" + table-type="InnoDB" + character-set="latin1" + collate="latin1_general_cs"> + <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://127.0.0.1/ofbiztenant?autoReconnect=true" + jdbc-username="ofbiz" + jdbc-password="ofbiz" + isolation-level="ReadCommitted" + pool-minsize="2" + pool-maxsize="250" + time-between-eviction-runs-millis="600000"/><!-- Please note that at least one person has experienced a problem with this value with MySQL + and had to set it to -1 in order to avoid this issue. + For more look at http://markmail.org/thread/5sivpykv7xkl66px and http://commons.apache.org/dbcp/configuration.html--> + <!-- <jndi-jdbc jndi-server-name="localjndi" jndi-name="java:/MySqlDataSource" isolation-level="Serializable"/> --> + </datasource> <datasource name="odbcmysql" helper-class="org.ofbiz.entity.datasource.GenericHelperDAO" field-type-name="mysql" @@ -386,6 +464,39 @@ access. For a detailed description see t at or above 8.1 (for more information see the comment in the fieldtype file "fieldtypepostnew") --> <datasource name="localpostnew" + helper-class="org.ofbiz.entity.datasource.GenericHelperDAO" + schema-name="public" + field-type-name="postnew" + check-on-start="true" + add-missing-on-start="true" + use-fk-initially-deferred="false" + alias-view-columns="false" + join-style="ansi" + result-fetch-size="50" + use-binary-type-for-blob="true" + use-order-by-nulls="true"> + <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="org.postgresql.Driver" + jdbc-uri="jdbc:postgresql://127.0.0.1/ofbiz" + jdbc-username="ofbiz" + jdbc-password="ofbiz" + isolation-level="ReadCommitted" + pool-minsize="2" + pool-maxsize="250" + time-between-eviction-runs-millis="600000"/><!-- Be warned that at this date (2009-09-20) the max_connections parameters in postgresql.conf + is set by default to 100 by the initdb process see http://www.postgresql.org/docs/8.4/static/runtime-config-connection.html#GUC-MAX-CONNECTIONS--> + + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="java:comp/env/jdbc/localpostgres" isolation-level="ReadCommitted"/>--> + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="comp/env/jdbc/xa/localpostgres" isolation-level="ReadCommitted"/> --> <!-- Orion Style JNDI name --> + <!-- <jndi-jdbc jndi-server-name="localweblogic" jndi-name="PostgresDataSource"/> --> <!-- Weblogic Style JNDI name --> + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="jdbc/localpostgres" isolation-level="ReadCommitted"/> --> <!-- JRun4 Style JNDI name --> + <!-- <tyrex-dataSource dataSource-name="localpostgres" isolation-level="ReadCommitted"/> --> + </datasource> + <datasource name="localpostolap" helper-class="org.ofbiz.entity.datasource.GenericHelperDAO" schema-name="public" field-type-name="postnew" @@ -403,13 +514,53 @@ access. For a detailed description see t <read-data reader-name="ext"/> <inline-jdbc jdbc-driver="org.postgresql.Driver" - jdbc-uri="jdbc:postgresql://127.0.0.1/ofbiz" + jdbc-uri="jdbc:postgresql://127.0.0.1/ofbizolap" jdbc-username="ofbiz" jdbc-password="ofbiz" isolation-level="ReadCommitted" pool-minsize="2" pool-maxsize="250" - time-between-eviction-runs-millis="600000"/> + time-between-eviction-runs-millis="600000"/><!-- Be warned that at this date (2009-09-20) the max_connections parameters in postgresql.conf + is set by default to 100 by the initdb process see http://www.postgresql.org/docs/8.4/static/runtime-config-connection.html#GUC-MAX-CONNECTIONS--> + + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="java:comp/env/jdbc/localpostgres" isolation-level="ReadCommitted"/>--> + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="comp/env/jdbc/xa/localpostgres" isolation-level="ReadCommitted"/> --> <!-- Orion Style JNDI name --> + <!-- <jndi-jdbc jndi-server-name="localweblogic" jndi-name="PostgresDataSource"/> --> <!-- Weblogic Style JNDI name --> + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="jdbc/localpostgres" isolation-level="ReadCommitted"/> --> <!-- JRun4 Style JNDI name --> + <!-- <tyrex-dataSource dataSource-name="localpostgres" isolation-level="ReadCommitted"/> --> + </datasource> + <datasource name="localposttenant" + helper-class="org.ofbiz.entity.datasource.GenericHelperDAO" + schema-name="public" + field-type-name="postnew" + check-on-start="true" + add-missing-on-start="true" + use-fk-initially-deferred="false" + alias-view-columns="false" + join-style="ansi" + result-fetch-size="50" + use-binary-type-for-blob="true" + use-order-by-nulls="true"> + <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="org.postgresql.Driver" + jdbc-uri="jdbc:postgresql://127.0.0.1/ofbiztenant" + jdbc-username="ofbiz" + jdbc-password="ofbiz" + isolation-level="ReadCommitted" + pool-minsize="2" + pool-maxsize="250" + time-between-eviction-runs-millis="600000"/><!-- Be warned that at this date (2009-09-20) the max_connections parameters in postgresql.conf + is set by default to 100 by the initdb process see http://www.postgresql.org/docs/8.4/static/runtime-config-connection.html#GUC-MAX-CONNECTIONS--> + + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="java:comp/env/jdbc/localpostgres" isolation-level="ReadCommitted"/>--> + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="comp/env/jdbc/xa/localpostgres" isolation-level="ReadCommitted"/> --> <!-- Orion Style JNDI name --> + <!-- <jndi-jdbc jndi-server-name="localweblogic" jndi-name="PostgresDataSource"/> --> <!-- Weblogic Style JNDI name --> + <!-- <jndi-jdbc jndi-server-name="default" jndi-name="jdbc/localpostgres" isolation-level="ReadCommitted"/> --> <!-- JRun4 Style JNDI name --> + <!-- <tyrex-dataSource dataSource-name="localpostgres" isolation-level="ReadCommitted"/> --> </datasource> <datasource name="localoracle" Added: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml?rev=1065144&view=auto ============================================================================== --- ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml (added) +++ ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml Sat Jan 29 23:35:01 2011 @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<entity-engine-xml> + <Tenant tenantId="@tenantId@" tenantName="@tenantName@" /> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz" + jdbcUri="jdbc:derby:ofbiz_@tenantId@;create=true" jdbcUsername="ofbiz" jdbcPassword="ofbiz"/> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz.olap" + jdbcUri="jdbc:derby:ofbizolap_@tenantId@;create=true" jdbcUsername="ofbiz" jdbcPassword="ofbiz"/> +</entity-engine-xml> \ No newline at end of file Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml ------------------------------------------------------------------------------ svn:eol-style = native Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml ------------------------------------------------------------------------------ svn:keywords = Date Rev Author URL Id Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Derby.xml ------------------------------------------------------------------------------ svn:mime-type = text/xml Added: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml?rev=1065144&view=auto ============================================================================== --- ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml (added) +++ ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml Sat Jan 29 23:35:01 2011 @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<entity-engine-xml> + <Tenant tenantId="@tenantId@" tenantName="@tenantName@"/> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz" + jdbcUri="jdbc:mysql://@db-IP@/ofbiz_@tenantId@" jdbcUsername="@db-User@" jdbcPassword="@db-Password@"/> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz.olap" + jdbcUri="jdbc:mysql://@db-IP@/ofbizolap_@tenantId@" jdbcUsername="@db-User@" jdbcPassword="@db-Password@"/> +</entity-engine-xml> \ No newline at end of file Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml ------------------------------------------------------------------------------ svn:eol-style = native Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml ------------------------------------------------------------------------------ svn:keywords = Date Rev Author URL Id Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-MySQL.xml ------------------------------------------------------------------------------ svn:mime-type = text/xml Added: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml?rev=1065144&view=auto ============================================================================== --- ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml (added) +++ ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml Sat Jan 29 23:35:01 2011 @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<entity-engine-xml> + <Tenant tenantId="@tenantId@" tenantName="@tenantName@"/> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz" + jdbcUri="jdbc:oracle:thin:@@db-IP@:ofbiz_@tenantId@" jdbcUsername="@db-User@" jdbcPassword="@db-Password@"/> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz.olap" + jdbcUri="jdbc:oracle:thin:@@db-IP@:ofbizolap_@tenantId@" jdbcUsername="@db-User@" jdbcPassword="@db-Password@"/> +</entity-engine-xml> \ No newline at end of file Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml ------------------------------------------------------------------------------ svn:eol-style = native Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml ------------------------------------------------------------------------------ svn:keywords = Date Rev Author URL Id Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-Oracle.xml ------------------------------------------------------------------------------ svn:mime-type = text/xml Added: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml?rev=1065144&view=auto ============================================================================== --- ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml (added) +++ ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml Sat Jan 29 23:35:01 2011 @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<entity-engine-xml> + <Tenant tenantId="@tenantId@" tenantName="@tenantName@"/> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz" + jdbcUri="jdbc:postgresql://@db-IP@/ofbiz_@tenantId@" jdbcUsername="@db-User@" jdbcPassword="@db-Password@"/> + <TenantDataSource tenantId="@tenantId@" entityGroupName="org.ofbiz.olap" + jdbcUri="jdbc:postgresql://@db-IP@/ofbizolap_@tenantId@" jdbcUsername="@db-User@" jdbcPassword="@db-Password@"/> +</entity-engine-xml> \ No newline at end of file Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml ------------------------------------------------------------------------------ svn:eol-style = native Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml ------------------------------------------------------------------------------ svn:keywords = Date Rev Author URL Id Propchange: ofbiz/trunk/framework/resources/templates/AdminNewTenantData-PostgreSQL.xml ------------------------------------------------------------------------------ svn:mime-type = text/xml |
Free forum by Nabble | Edit this page |