Java Code Examples for org.camunda.bpm.engine.AuthorizationService#deleteAuthorization()
The following examples show how to use
org.camunda.bpm.engine.AuthorizationService#deleteAuthorization() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: AuthorizationScenarioInstance.java From camunda-bpm-platform with Apache License 2.0 | 5 votes |
public void tearDown(AuthorizationService authorizationService) { Set<String> activeAuthorizations = new HashSet<String>(); for (Authorization activeAuthorization : authorizationService.createAuthorizationQuery().list()) { activeAuthorizations.add(activeAuthorization.getId()); } for (Authorization createdAuthorization : createdAuthorizations) { if (activeAuthorizations.contains(createdAuthorization.getId())) { authorizationService.deleteAuthorization(createdAuthorization.getId()); } } }
Example 2
Source File: HistoryAuthorizationQueryPerformanceTest.java From camunda-bpm-platform with Apache License 2.0 | 5 votes |
@Before public void createAuthorizations() { AuthorizationService authorizationService = engine.getAuthorizationService(); List<Authorization> auths = authorizationService.createAuthorizationQuery().list(); for (Authorization authorization : auths) { authorizationService.deleteAuthorization(authorization.getId()); } userGrant("test", resource, permissions); for (int i = 0; i < 5; i++) { grouptGrant("g"+i, resource, permissions); } engine.getProcessEngineConfiguration().setAuthorizationEnabled(true); }
Example 3
Source File: RepositoryAuthorizationQueryPerformanceTest.java From camunda-bpm-platform with Apache License 2.0 | 5 votes |
@Before public void createAuthorizations() { AuthorizationService authorizationService = engine.getAuthorizationService(); List<Authorization> auths = authorizationService.createAuthorizationQuery().list(); for (Authorization authorization : auths) { authorizationService.deleteAuthorization(authorization.getId()); } userGrant("test", resource, permissions); for (int i = 0; i < 5; i++) { grouptGrant("g"+i, resource, permissions); } engine.getProcessEngineConfiguration().setAuthorizationEnabled(true); }
Example 4
Source File: RuntimeAuthorizationQueryPerformanceTest.java From camunda-bpm-platform with Apache License 2.0 | 5 votes |
@Before public void createAuthorizations() { AuthorizationService authorizationService = engine.getAuthorizationService(); List<Authorization> auths = authorizationService.createAuthorizationQuery().list(); for (Authorization authorization : auths) { authorizationService.deleteAuthorization(authorization.getId()); } userGrant("test", resource, permissions); for (int i = 0; i < 5; i++) { grouptGrant("g"+i, resource, permissions); } engine.getProcessEngineConfiguration().setAuthorizationEnabled(true); }
Example 5
Source File: RedeployDeploymentAuthorizationTest.java From camunda-bpm-platform with Apache License 2.0 | 4 votes |
protected void deleteAuthorizations() { AuthorizationService authorizationService = engineRule.getAuthorizationService(); for (Authorization authorization : authorizationService.createAuthorizationQuery().list()) { authorizationService.deleteAuthorization(authorization.getId()); } }
Example 6
Source File: StandaloneTaskGetVariableAuthorizationTest.java From camunda-bpm-platform with Apache License 2.0 | 4 votes |
protected void deleteAuthorizations() { AuthorizationService authorizationService = engineRule.getAuthorizationService(); for (Authorization authorization : authorizationService.createAuthorizationQuery().list()) { authorizationService.deleteAuthorization(authorization.getId()); } }