hate to give you a generic answer but a detailed one would take to long.
it depends on the type of tenant system you have.
also I am working on a setup scheme that this is dealt with in the setup (application/commonext) component based on the Business plan of the tenant.
https://issues.apache.org/jira/browse/OFBIZ-635
as pointed out in the
https://cwiki.apache.org/OFBIZ/multitenancy-support.html
you can't start and stop the instance just to add a new tenant.
so adding a new db to the TenantDataSouces then initializing it, is a pain.
currently I do this with a script that reads the tenant component and loads the data using the Webtools import file, then perform the db initialization then the dataload of the DB. I am still adding to it. the script is in the component for that tenant but depends on the setup component scripts mentioned above. the other part is defining what of the base (application) components seed data is loaded and what is load from the tenants component

on the ecommerce side they select if they want a fully automated (they use setup) or if they want a pre-defined, where they are talk to by the host staff and they do the configuring.

the only common data is the data for TenantDataSouces and the loginID and password. This login is setup for them having to give a new password.





Pierre Smits sent the following on 9/15/2010 5:38 AM:
Hi BJ,

I am also looking at multi tennant.

Could you provide an overview (or some example data) of the essential
elements of what you create in the component for each tennant?

Regards,

Pierre

2010/9/15 BJ Freeman<[email protected]>

personally I make  a component for each tenant
and put all there stuff in that.


=========================
BJ Freeman<http://bjfreeman.elance.com>
Strategic Power Office with Supplier Automation<
http://www.businessesnetwork.com/automation/viewforum.php?f=52>
Specialtymarket.com<http://www.specialtymarket.com/>
Systems Integrator-- Glad to Assist

Chat  Y! messenger: bjfr33man


BJ Freeman sent the following on 9/14/2010 7:22 PM:

  https://cwiki.apache.org/OFBIZ/multitenancy-support.html
look in the current framework/entity/config/entityengine.xml for data
bases.

if you have special data for each tenant then you would configure the
component-load.xml with :
<entity-resource type="data" reader-name="ext-tenantname" loader="main"
location="data/TenantnameProductData.xml"/>


$ java -Xmx512m -XX:MaxPermSize=128m -jar ofbiz.jar -install
-readers=ext-tenantname -delegator=default#(whatever the login is for
that tenant)
would load the special data for ext-tenantname into the db for that
tenant.

=========================
BJ Freeman<http://bjfreeman.elance.com>
Strategic Power Office with Supplier Automation
<http://www.businessesnetwork.com/automation/viewforum.php?f=52>
Specialtymarket.com<http://www.specialtymarket.com/>
Systems Integrator-- Glad to Assist

Chat Y! messenger: bjfr33man
Carsten Schinzer sent the following on 9/14/2010 2:23 PM:


  Another, related question to the Multi-Tenant experts, please:

What databases are required? - I currently assume, a core DB plus one
DB per
tenant.

Where does common seed data reside? Is sed data meant to be common at
all,
or would each database reflect a full-fletched OFBiz database and
could be
connected as a stand-alone DB as well?
* I assume, seed data us on the common core DB, while running data
reside in
the tenants DBs. *
Example:
- AccountingTypeData.xml -->  to be loaded once for all tenants; -->
core DB
- Running accounting data (transactions, finAccounts) -->  tenant DB


How to direct certain data to certain databases? - is there a built-in
way
by dedicated readers? Or do I need to take care that customer specific
data
files for upload are copied in/out before respective loads?
Example:
- I want to load a set of initial ProductData.xml per Tenant; I do
follow a
private naming convention like TenantnameProductData.xml
-->  How do I direct this initial data into the tenant's database and
how do
I avoid the it is loaded to the other tenant's?
Ideas are:
(i) edit ofbiz-component.xml before every load attempt;
(ii) copy related Tenant files in and let the loads fail for non-existing
files;
(iii) define dedicated readers (e.g. "ext-tenantname") and limit tenant
database to loads from that reader only.

Let me know your comments.
Regards


Carsten






Reply via email to