Search in sources :

Example 1 with DefaultEventResult

use of eu.bcvsolutions.idm.core.api.event.DefaultEventResult in project CzechIdMng by bcvsolutions.

the class SynchronizationCancelProcessor method process.

@Override
public EventResult<AbstractSysSyncConfigDto> process(EntityEvent<AbstractSysSyncConfigDto> event) {
    LOG.info("Synchronization event cancel");
    AbstractSysSyncConfigDto config = event.getContent();
    synchronizationService.stopSynchronization(config);
    return new DefaultEventResult<>(event, this);
}
Also used : AbstractSysSyncConfigDto(eu.bcvsolutions.idm.acc.dto.AbstractSysSyncConfigDto) DefaultEventResult(eu.bcvsolutions.idm.core.api.event.DefaultEventResult)

Example 2 with DefaultEventResult

use of eu.bcvsolutions.idm.core.api.event.DefaultEventResult in project CzechIdMng by bcvsolutions.

the class SynchronizationStartProcessor method process.

@Override
public EventResult<AbstractSysSyncConfigDto> process(EntityEvent<AbstractSysSyncConfigDto> event) {
    LOG.info("Synchronization event start");
    AbstractSysSyncConfigDto config = event.getContent();
    synchronizationService.startSynchronization(config);
    return new DefaultEventResult<>(event, this);
}
Also used : AbstractSysSyncConfigDto(eu.bcvsolutions.idm.acc.dto.AbstractSysSyncConfigDto) DefaultEventResult(eu.bcvsolutions.idm.core.api.event.DefaultEventResult)

Example 3 with DefaultEventResult

use of eu.bcvsolutions.idm.core.api.event.DefaultEventResult in project CzechIdMng by bcvsolutions.

the class LogIdentityDeleteProcessor method process.

@Override
public EventResult<IdmIdentityDto> process(EntityEvent<IdmIdentityDto> event) {
    // event content - identity
    IdmIdentityDto deletedIdentity = event.getContent();
    // log
    LOG.info("Identity [{},{}] was deleted.", deletedIdentity.getUsername(), deletedIdentity.getId());
    // result
    return new DefaultEventResult<>(event, this);
}
Also used : DefaultEventResult(eu.bcvsolutions.idm.core.api.event.DefaultEventResult) IdmIdentityDto(eu.bcvsolutions.idm.core.api.dto.IdmIdentityDto)

Example 4 with DefaultEventResult

use of eu.bcvsolutions.idm.core.api.event.DefaultEventResult in project CzechIdMng by bcvsolutions.

the class LogIdentityUpdateAsyncProcessor method process.

@Override
public EventResult<IdmIdentityDto> process(EntityEvent<IdmIdentityDto> event) {
    // event content - identity
    IdmIdentityDto updateddIdentity = event.getContent();
    // log
    LOG.info("Identity [{},{}] was updated.", updateddIdentity.getUsername(), updateddIdentity.getId());
    // result
    return new DefaultEventResult<>(event, this);
}
Also used : DefaultEventResult(eu.bcvsolutions.idm.core.api.event.DefaultEventResult) IdmIdentityDto(eu.bcvsolutions.idm.core.api.dto.IdmIdentityDto)

Example 5 with DefaultEventResult

use of eu.bcvsolutions.idm.core.api.event.DefaultEventResult in project CzechIdMng by bcvsolutions.

the class ReportGenerateEndProcessor method process.

@Override
public EventResult<RptReportDto> process(EntityEvent<RptReportDto> event) {
    RptReportDto report = event.getContent();
    report = reportService.saveInternal(report);
    event.setContent(report);
    // 
    return new DefaultEventResult<>(event, this);
}
Also used : DefaultEventResult(eu.bcvsolutions.idm.core.api.event.DefaultEventResult) RptReportDto(eu.bcvsolutions.idm.rpt.api.dto.RptReportDto)

Aggregations

DefaultEventResult (eu.bcvsolutions.idm.core.api.event.DefaultEventResult)242 UUID (java.util.UUID)64 IdmIdentityDto (eu.bcvsolutions.idm.core.api.dto.IdmIdentityDto)39 ResultCodeException (eu.bcvsolutions.idm.core.api.exception.ResultCodeException)28 IdmIdentityContractDto (eu.bcvsolutions.idm.core.api.dto.IdmIdentityContractDto)23 IdmRoleDto (eu.bcvsolutions.idm.core.api.dto.IdmRoleDto)23 DefaultResultModel (eu.bcvsolutions.idm.core.api.dto.DefaultResultModel)17 IdmRoleRequestDto (eu.bcvsolutions.idm.core.api.dto.IdmRoleRequestDto)17 SysSystemDto (eu.bcvsolutions.idm.acc.dto.SysSystemDto)16 IdmIdentityRoleDto (eu.bcvsolutions.idm.core.api.dto.IdmIdentityRoleDto)16 EventResult (eu.bcvsolutions.idm.core.api.event.EventResult)16 EntityEvent (eu.bcvsolutions.idm.core.api.event.EntityEvent)15 Autowired (org.springframework.beans.factory.annotation.Autowired)15 OperationResultDto (eu.bcvsolutions.idm.core.api.dto.OperationResultDto)14 GuardedString (eu.bcvsolutions.idm.core.security.api.domain.GuardedString)14 List (java.util.List)14 Description (org.springframework.context.annotation.Description)14 Component (org.springframework.stereotype.Component)14 IdmAuthorizationPolicyDto (eu.bcvsolutions.idm.core.api.dto.IdmAuthorizationPolicyDto)12 IdmEntityStateDto (eu.bcvsolutions.idm.core.api.dto.IdmEntityStateDto)12