Hi Udara, The usual case for processing CompleteTenantEvent is to use it at first to establish the Topology model and then ignore the consequent ones. The components will update the model based on the other topology events. So as far as I understood, you should have a flag to determine if CompleteTenantEvent was already processed or not.
Regards, Chamila de Alwis Software Engineer | WSO2 | +94772207163 Blog: code.chamiladealwis.com On Wed, Dec 10, 2014 at 3:43 PM, Udara Liyanage <[email protected]> wrote: > Hi, > > Yes it is the culprit. It periodically trigger the add Tenant. > > TenantMgtUtil.triggerAddTenant(tenantBean); > > On Wed, Dec 10, 2014 at 3:38 PM, Udara Liyanage <[email protected]> wrote: > >> Hi, >> >> Just noticed TenantCompletion event is an Stratos event. So this may not >> be the culprit for the constraint issue. >> >> On Wed, Dec 10, 2014 at 3:30 PM, Udara Liyanage <[email protected]> wrote: >> >>> Hi, >>> >>> TenantSynzhronizerTask periodically publishes CompleteTenantEvent event. >>> This results in issues when oAuth feature is added since there are tenant >>> listeners. >>> For instance TenantManagementListener fails with database constraint >>> violation. >>> >>> -- >>> >>> Udara Liyanage >>> Software Engineer >>> WSO2, Inc.: http://wso2.com >>> lean. enterprise. middleware >>> >>> web: http://udaraliyanage.wordpress.com >>> phone: +94 71 443 6897 >>> >> >> >> >> -- >> >> Udara Liyanage >> Software Engineer >> WSO2, Inc.: http://wso2.com >> lean. enterprise. middleware >> >> web: http://udaraliyanage.wordpress.com >> phone: +94 71 443 6897 >> > > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 >
