use of io.joynr.accesscontrol.broadcastlistener.LdacDomainRoleEntryChangedBroadcastListener in project joynr by bmwcarit.
the class LocalDomainAccessControllerImpl method subscribeForDreChange.
private void subscribeForDreChange(String userId) {
long wsbExpiryDate = System.currentTimeMillis() + QOS_DURATION_MS;
MulticastSubscriptionQos broadcastSubscriptionQos = new MulticastSubscriptionQos();
broadcastSubscriptionQos.setExpiryDateMs(wsbExpiryDate);
globalDomainAccessControllerClient.subscribeToDomainRoleEntryChangedBroadcast(new LdacDomainRoleEntryChangedBroadcastListener(localDomainAccessStore), broadcastSubscriptionQos, sanitiseForPartition(userId));
}
use of io.joynr.accesscontrol.broadcastlistener.LdacDomainRoleEntryChangedBroadcastListener in project joynr by bmwcarit.
the class GdacBroadcastListenerTest method testDreChangedListenerForRemoveDre.
@Test
public void testDreChangedListenerForRemoveDre() {
LdacDomainRoleEntryChangedBroadcastListener dreChangedListener = new LdacDomainRoleEntryChangedBroadcastListener(domainAccessControlStore);
dreChangedListener.onReceive(ChangeType.REMOVE, userDre);
verify(domainAccessControlStore).removeDomainRole(eq(userDre.getUid()), eq(userDre.getRole()));
}
use of io.joynr.accesscontrol.broadcastlistener.LdacDomainRoleEntryChangedBroadcastListener in project joynr by bmwcarit.
the class GdacBroadcastListenerTest method testDreChangedListenerForUpdateDre.
@Test
public void testDreChangedListenerForUpdateDre() {
LdacDomainRoleEntryChangedBroadcastListener dreChangedListener = new LdacDomainRoleEntryChangedBroadcastListener(domainAccessControlStore);
dreChangedListener.onReceive(ChangeType.UPDATE, userDre);
verify(domainAccessControlStore).updateDomainRole(eq(userDre));
}
Aggregations