Search in sources :

Example 1 with DebugReconciliationTaskResultListener

use of com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener in project midpoint by Evolveum.

the class TestUniversity method initSystem.

@Override
public void initSystem(Task initTask, OperationResult initResult) throws Exception {
    super.initSystem(initTask, initResult);
    reconciliationTaskResultListener = new DebugReconciliationTaskResultListener();
    reconciliationTaskHandler.setReconciliationTaskResultListener(reconciliationTaskResultListener);
    // Resources
    dummyResourceCtlHr = DummyResourceContoller.create(RESOURCE_DUMMY_HR_ID, resourceDummyHr);
    DummyObjectClass privilegeObjectClass = dummyResourceCtlHr.getDummyResource().getPrivilegeObjectClass();
    dummyResourceCtlHr.addAttrDef(privilegeObjectClass, DUMMY_PRIVILEGE_ATTRIBUTE_HR_ORGPATH, String.class, false, false);
    dummyResourceHr = dummyResourceCtlHr.getDummyResource();
    resourceDummyHr = importAndGetObjectFromFile(ResourceType.class, RESOURCE_DUMMY_HR_FILE, RESOURCE_DUMMY_HR_OID, initTask, initResult);
    resourceDummyHrType = resourceDummyHr.asObjectable();
    dummyResourceCtlHr.setResource(resourceDummyHr);
    dummyResourceHr.setSyncStyle(DummySyncStyle.SMART);
    resourceOpenDj = importAndGetObjectFromFile(ResourceType.class, RESOURCE_OPENDJ_FILE, RESOURCE_OPENDJ_OID, initTask, initResult);
    resourceOpenDjType = resourceOpenDj.asObjectable();
    openDJController.setResource(resourceOpenDj);
    //		// LDAP content
    //		openDJController.addEntryFromLdifFile(SCABB_OU_LDIF_FILE);
    //		openDJController.addEntryFromLdifFile(BOOTY_OU_LDIF_FILE);
    //		openDJController.addEntryFromLdifFile(BOOTY_LOOKOUT_OU_LDIF_FILE);
    //
    // Object Templates
    importObjectFromFile(OBJECT_TEMPLATE_ORG_FILE, initResult);
    setDefaultObjectTemplate(OrgType.COMPLEX_TYPE, OBJECT_TEMPLATE_ORG_OID);
    // Org
    importObjectFromFile(ORG_TOP_FILE, initResult);
    // Role
    importObjectFromFile(ROLE_META_ORG_FILE, initResult);
    // Tasks
    importObjectFromFile(TASK_LIVE_SYNC_DUMMY_HR_FILE, initResult);
}
Also used : DummyObjectClass(com.evolveum.icf.dummy.resource.DummyObjectClass) DebugReconciliationTaskResultListener(com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener) ResourceType(com.evolveum.midpoint.xml.ns._public.common.common_3.ResourceType)

Example 2 with DebugReconciliationTaskResultListener

use of com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener in project midpoint by Evolveum.

the class TestUuid method initSystem.

@Override
public void initSystem(Task initTask, OperationResult initResult) throws Exception {
    super.initSystem(initTask, initResult);
    reconciliationTaskResultListener = new DebugReconciliationTaskResultListener();
    reconciliationTaskHandler.setReconciliationTaskResultListener(reconciliationTaskResultListener);
    dummyResourceCtlUuid = DummyResourceContoller.create(RESOURCE_DUMMY_UUID_NAME, resourceDummyUuid);
    dummyResourceCtlUuid.extendSchemaPirate();
    dummyResourceUuid = dummyResourceCtlUuid.getDummyResource();
    resourceDummyUuid = importAndGetObjectFromFile(ResourceType.class, RESOURCE_DUMMY_UUID_FILE, RESOURCE_DUMMY_UUID_OID, initTask, initResult);
    resourceDummyUuidType = resourceDummyUuid.asObjectable();
    dummyResourceCtlUuid.setResource(resourceDummyUuid);
    InternalMonitor.reset();
    InternalMonitor.setTraceShadowFetchOperation(true);
//		DebugUtil.setDetailedDebugDump(true);
}
Also used : DebugReconciliationTaskResultListener(com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener) ResourceType(com.evolveum.midpoint.xml.ns._public.common.common_3.ResourceType)

Example 3 with DebugReconciliationTaskResultListener

use of com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener in project midpoint by Evolveum.

the class TestImportRecon method initSystem.

@Override
public void initSystem(Task initTask, OperationResult initResult) throws Exception {
    super.initSystem(initTask, initResult);
    reconciliationTaskResultListener = new DebugReconciliationTaskResultListener();
    reconciliationTaskHandler.setReconciliationTaskResultListener(reconciliationTaskResultListener);
    dummyResourceCtlAzure = DummyResourceContoller.create(RESOURCE_DUMMY_AZURE_NAME, resourceDummyAzure);
    dummyResourceCtlAzure.extendSchemaPirate();
    dummyResourceCtlAzure.addOrgTop();
    dummyResourceAzure = dummyResourceCtlAzure.getDummyResource();
    resourceDummyAzure = importAndGetObjectFromFile(ResourceType.class, getDummyResourceAzureFile(), RESOURCE_DUMMY_AZURE_OID, initTask, initResult);
    resourceDummyAzureType = resourceDummyAzure.asObjectable();
    dummyResourceCtlAzure.setResource(resourceDummyAzure);
    dummyResourceCtlLime = DummyResourceContoller.create(RESOURCE_DUMMY_LIME_NAME, resourceDummyLime);
    dummyResourceCtlLime.extendSchemaPirate();
    dummyResourceLime = dummyResourceCtlLime.getDummyResource();
    resourceDummyLime = importAndGetObjectFromFile(ResourceType.class, getDummyResourceLimeFile(), RESOURCE_DUMMY_LIME_OID, initTask, initResult);
    resourceDummyLimeType = resourceDummyLime.asObjectable();
    dummyResourceCtlLime.setResource(resourceDummyLime);
    // Create an account that midPoint does not know about yet
    getDummyResourceController().addAccount(USER_RAPP_USERNAME, USER_RAPP_FULLNAME, "Scabb Island");
    getDummyResource().getAccountByUsername(USER_RAPP_USERNAME).replaceAttributeValue(DummyResourceContoller.DUMMY_ACCOUNT_ATTRIBUTE_SHIP_NAME, "The Elaine");
    dummyResourceCtlLime.addAccount(USER_RAPP_USERNAME, USER_RAPP_FULLNAME, "Scabb Island");
    dummyResourceLime.getAccountByUsername(USER_RAPP_USERNAME).replaceAttributeValue(DummyResourceContoller.DUMMY_ACCOUNT_ATTRIBUTE_SHIP_NAME, "The Elaine");
    dummyResourceCtlLime.addAccount(ACCOUNT_RUM_NAME, "Rum Rogers");
    dummyResourceCtlLime.addAccount(ACCOUNT_MURRAY_NAME, "Murray");
    // Groups
    dummyResourceCtlAzure.addGroup(GROUP_CORPSES_NAME);
    // Roles
    repoAddObjectFromFile(ROLE_CORPSE_FILE, initResult);
    // Password policy
    repoAddObjectFromFile(PASSWORD_POLICY_LOWER_CASE_ALPHA_AZURE_FILE, initResult);
    // Object templates
    repoAddObjectFromFile(USER_TEMPLATE_LIME_FILE, initResult);
    // And a user that will be correlated to that account
    repoAddObjectFromFile(USER_RAPP_FILE, initResult);
    PrismObject<ShadowType> accountStan = PrismTestUtil.parseObject(ACCOUNT_STAN_FILE);
    provisioningService.addObject(accountStan, null, null, initTask, initResult);
    addObject(SHADOW_GROUP_DUMMY_TESTERS_FILE, initTask, initResult);
    InternalMonitor.reset();
    InternalMonitor.setTraceShadowFetchOperation(true);
//		DebugUtil.setDetailedDebugDump(true);
}
Also used : ShadowType(com.evolveum.midpoint.xml.ns._public.common.common_3.ShadowType) DebugReconciliationTaskResultListener(com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener) ResourceType(com.evolveum.midpoint.xml.ns._public.common.common_3.ResourceType)

Example 4 with DebugReconciliationTaskResultListener

use of com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener in project midpoint by Evolveum.

the class TestUnix method initSystem.

@Override
public void initSystem(Task initTask, OperationResult initResult) throws Exception {
    super.initSystem(initTask, initResult);
    reconciliationTaskResultListener = new DebugReconciliationTaskResultListener();
    reconciliationTaskHandler.setReconciliationTaskResultListener(reconciliationTaskResultListener);
    // Resources
    resourceOpenDj = importAndGetObjectFromFile(ResourceType.class, RESOURCE_OPENDJ_FILE, RESOURCE_OPENDJ_OID, initTask, initResult);
    resourceOpenDjType = resourceOpenDj.asObjectable();
    openDJController.setResource(resourceOpenDj);
    // LDAP content
    openDJController.addEntriesFromLdifFile(STRUCT_LDIF_FILE.getPath());
    // Object Templates
    importObjectFromFile(OBJECT_TEMPLATE_USER_FILE, initResult);
    setDefaultUserTemplate(OBJECT_TEMPLATE_USER_OID);
    // Role
    importObjectFromFile(ROLE_BASIC_FILE, initResult);
    importObjectFromFile(ROLE_UNIX_FILE, initResult);
    importObjectFromFile(ROLE_META_LDAPGROUP_FILE, initResult);
    importObjectFromFile(ROLE_META_UNIXGROUP_FILE, initResult);
    importObjectFromFile(ROLE_META_UNIXGROUP2_FILE, initResult);
    // Sequence
    importObjectFromFile(SEQUENCE_UIDNUMBER_FILE, initResult);
    importObjectFromFile(SEQUENCE_GIDNUMBER_FILE, initResult);
//		DebugUtil.setDetailedDebugDump(true);
}
Also used : DebugReconciliationTaskResultListener(com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener)

Example 5 with DebugReconciliationTaskResultListener

use of com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener in project midpoint by Evolveum.

the class TestOrgSync method initSystem.

@Override
public void initSystem(Task initTask, OperationResult initResult) throws Exception {
    super.initSystem(initTask, initResult);
    reconciliationTaskResultListener = new DebugReconciliationTaskResultListener();
    reconciliationTaskHandler.setReconciliationTaskResultListener(reconciliationTaskResultListener);
    // Resources
    dummyResourceCtlHr = DummyResourceContoller.create(RESOURCE_DUMMY_HR_ID, resourceDummyHr);
    DummyObjectClass dummyAdAccountObjectClass = dummyResourceCtlHr.getDummyResource().getAccountObjectClass();
    dummyResourceCtlHr.addAttrDef(dummyAdAccountObjectClass, DUMMY_ACCOUNT_ATTRIBUTE_HR_FIRST_NAME, String.class, false, false);
    dummyResourceCtlHr.addAttrDef(dummyAdAccountObjectClass, DUMMY_ACCOUNT_ATTRIBUTE_HR_LAST_NAME, String.class, false, false);
    dummyResourceCtlHr.addAttrDef(dummyAdAccountObjectClass, DUMMY_ACCOUNT_ATTRIBUTE_HR_ORGPATH, String.class, false, false);
    dummyResourceCtlHr.addAttrDef(dummyAdAccountObjectClass, DUMMY_ACCOUNT_ATTRIBUTE_HR_RESPONSIBILITIES, String.class, false, true);
    dummyResourceHr = dummyResourceCtlHr.getDummyResource();
    resourceDummyHr = importAndGetObjectFromFile(ResourceType.class, RESOURCE_DUMMY_HR_FILE, RESOURCE_DUMMY_HR_OID, initTask, initResult);
    resourceDummyHrType = resourceDummyHr.asObjectable();
    dummyResourceCtlHr.setResource(resourceDummyHr);
    dummyResourceHr.setSyncStyle(DummySyncStyle.SMART);
    resourceOpenDj = importAndGetObjectFromFile(ResourceType.class, RESOURCE_OPENDJ_FILE, RESOURCE_OPENDJ_OID, initTask, initResult);
    resourceOpenDjType = resourceOpenDj.asObjectable();
    openDJController.setResource(resourceOpenDj);
    // LDAP content
    openDJController.addEntryFromLdifFile(SCABB_OU_LDIF_FILE);
    openDJController.addEntryFromLdifFile(BOOTY_OU_LDIF_FILE);
    openDJController.addEntryFromLdifFile(BOOTY_LOOKOUT_OU_LDIF_FILE);
    // Object Templates
    importObjectFromFile(OBJECT_TEMPLATE_USER_FILE, initResult);
    setDefaultUserTemplate(OBJECT_TEMPLATE_USER_OID);
    importObjectFromFile(OBJECT_TEMPLATE_ORG_FILE, initResult);
    setDefaultObjectTemplate(OrgType.COMPLEX_TYPE, OBJECT_TEMPLATE_ORG_OID);
    importObjectFromFile(OBJECT_TEMPLATE_ROLE_FILE, initResult);
    setDefaultObjectTemplate(RoleType.COMPLEX_TYPE, OBJECT_TEMPLATE_ROLE_OID);
    // Org
    importObjectFromFile(ORG_TOP_FILE, initResult);
    // Role
    importObjectFromFile(ROLE_BASIC_FILE, initResult);
    importObjectFromFile(ROLE_META_REPLICATED_ORG_FILE, initResult);
    importObjectFromFile(ROLE_META_RESPONSIBILITY_FILE, initResult);
    // Tasks
    importObjectFromFile(TASK_LIVE_SYNC_DUMMY_HR_FILE, initResult);
}
Also used : DummyObjectClass(com.evolveum.icf.dummy.resource.DummyObjectClass) DebugReconciliationTaskResultListener(com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener) ResourceType(com.evolveum.midpoint.xml.ns._public.common.common_3.ResourceType)

Aggregations

DebugReconciliationTaskResultListener (com.evolveum.midpoint.model.impl.util.DebugReconciliationTaskResultListener)5 ResourceType (com.evolveum.midpoint.xml.ns._public.common.common_3.ResourceType)4 DummyObjectClass (com.evolveum.icf.dummy.resource.DummyObjectClass)2 ShadowType (com.evolveum.midpoint.xml.ns._public.common.common_3.ShadowType)1