Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KAA-1423: Add Endpoint Specific Configuration Support. #1382

Merged
merged 4 commits into from
Dec 15, 2016
Merged

KAA-1423: Add Endpoint Specific Configuration Support. #1382

merged 4 commits into from
Dec 15, 2016

Conversation

v-chyzhevskyi
Copy link
Contributor

Process of updating configuration fixed.

@@ -61,7 +60,7 @@ public void testFindByEndpointKeyHashAndConfigurationVersion() throws Exception
Assert.assertNull(found4);
}

@Test(expected = KaaOptimisticLockingFailureException.class)
@Test
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why KaaOptimisticLockingFailureException is not expected anymore in this test?

configuration.setConfiguration(dto.getConfiguration());
configuration.setConfigurationVersion(dto.getConfigurationSchemaVersion());
configuration.setEndpointKeyHash(getByteBuffer(dto.getEndpointKeyHash()));
save(configuration);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move a call of save method out of if block

configuration.setConfiguration(dto.getConfiguration());
configuration.setConfigurationVersion(dto.getConfigurationSchemaVersion());
configuration.setEndpointKeyHash(dto.getEndpointKeyHash());
save(configuration);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

move a call of save method out of if block

@@ -26,19 +26,19 @@
private byte[] endpointKeyHash;
private Integer configurationSchemaVersion;
private String configuration;
private Long version;
private Long specificConfigurationVersion;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need to rename version -> specificConfigurationVersion in DTO?

@@ -72,7 +71,7 @@ public void testFindByEndpointKeyHashAndConfigurationVersion() throws Exception
Assert.assertNull(found4);
}

@Test(expected = KaaOptimisticLockingFailureException.class)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why KaaOptimisticLockingFailureException is not expected anymore in this test?

@vtkhir vtkhir merged commit 5ad3179 into kaaproject:master Dec 15, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants