[
https://issues.apache.org/jira/browse/OFBIZ-5729?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14124689#comment-14124689 ]
Pierre Smits commented on OFBIZ-5729:
-------------------------------------
Wai,
While deploying a copy of ofbiz-trunk (without your patch) on AWS I ran into a similar issue like yours. Creating a new tenant with ./ant create-tenant succeeded, but loading the tenantId-admin failed.
Could you fill out the 'environment' field of the issue to describe the environment you're experiencing the issue?
After I applied your patch I was able to load the tenantID-admin and its initial password into the db of the tenant. I was also able to use
{code}
./ant load-tenant-data-readers -Ddata-readers=seed,seed-initial -DtenantId=demo
{code}
to load seed data into the db of the tenant.
> ofbiz hangs on installing tenant database
> ------------------------------------------
>
> Key: OFBIZ-5729
> URL:
https://issues.apache.org/jira/browse/OFBIZ-5729> Project: OFBiz
> Issue Type: Bug
> Components: framework
> Affects Versions: Trunk
> Reporter: Wai
> Assignee: Adrian Crum
> Attachments: ofbiz console output-with bug.log, ofbiz console output-with fix.log, ofbiz-5729.patch, ofbiz-5729.patch
>
>
> When installing data into a tenant database, ofbiz hangs.
> Using the following command line.
> $ ant load-tenant-data-readers -Ddata-readers=seed -DtenantId=DEMO1
> The problem is that ofbiz uses DelegatorFactory.getDelegator() to find/create the tenant delegator, asynchronously, for the target tenant database using a single daemon thread. As part of the tenant delegator creation, it needs to find/create a base delegator. When the base delegator is intially absent, ofbiz will block trying to create one by using the same daemon thread--which is already being used. Hence, ofbiz is deadlocked.
> The solution is to make sure that a base delegator is always created first before a find/create tenant delegator is attempted.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)