TargetPollEvent optional (#580)

* TargetPollEvent can be disabled.

Signed-off-by: kaizimmerm <kai.zimmermann@bosch-si.com>

* Fixed test.

Signed-off-by: kaizimmerm <kai.zimmermann@bosch-si.com>

* Central filter introduced.

Signed-off-by: kaizimmerm <kai.zimmermann@bosch-si.com>

* Fix sonar issue.

Signed-off-by: kaizimmerm <kai.zimmermann@bosch-si.com>

* Add property to standard runtime.

Signed-off-by: kaizimmerm <kai.zimmermann@bosch-si.com>

* Add property to standard runtime.

Signed-off-by: kaizimmerm <kai.zimmermann@bosch-si.com>
This commit is contained in:
Kai Zimmermann
2017-09-26 14:29:55 +02:00
committed by GitHub
parent 879c85fd63
commit 3d32d1d1c3
9 changed files with 132 additions and 25 deletions

View File

@@ -432,6 +432,16 @@ public class ControllerManagementTest extends AbstractJpaIntegrationTest {
.as("register target with empty controllerId should fail");
}
@Test
@Description("Verify that controller registration does not result in a TargetPollEvent if feature is disabled")
@ExpectEvents({ @Expect(type = TargetCreatedEvent.class, count = 1),
@Expect(type = TargetPollEvent.class, count = 0) })
public void targetPollEventNotSendIfDisabled() {
repositoryProperties.setPublishTargetPollEvent(false);
controllerManagement.findOrRegisterTargetIfItDoesNotexist("AA", LOCALHOST);
repositoryProperties.setPublishTargetPollEvent(true);
}
@Test
@Description("Controller trys to finish an update process after it has been finished by an error action status.")
@ExpectEvents({ @Expect(type = TargetCreatedEvent.class, count = 1),