You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brooklyn.apache.org by neykov <gi...@git.apache.org> on 2014/11/15 17:31:40 UTC
[GitHub] incubator-brooklyn pull request: Persistence fix for removing and ...
GitHub user neykov opened a pull request:
https://github.com/apache/incubator-brooklyn/pull/334
Persistence fix for removing and adding same ID catalog item
If a catalog item with the same ID is removed and then added back the delta persister will first update the stored item and then delete it, regardless of the initial order of removal-addition. This may result in the catalog items disappearing from store even though they were just added.
Explicitly remove catalog item with same ID from the removed set if new object is added.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/neykov/incubator-brooklyn fix/catalog-rebind
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/incubator-brooklyn/pull/334.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #334
----
commit 1adc562d77c86abe765ab15dfad412fd2074a8e2
Author: Svetoslav Neykov <sv...@cloudsoftcorp.com>
Date: 2014-11-15T16:08:14Z
Persistence fix for removing and adding same ID catalog item
If a catalog item with the same ID is removed and then added back the delta persister will first update the stored item and then delete it, regardless of the initial order of removal-addition. This may result in the catalog items disappearing from store even though they were just added.
Explicitly remove catalog item with same ID from the removed set if new object is added.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-brooklyn pull request: Persistence fix for removing and ...
Posted by ahgittin <gi...@git.apache.org>.
Github user ahgittin commented on a diff in the pull request:
https://github.com/apache/incubator-brooklyn/pull/334#discussion_r20403516
--- Diff: core/src/test/java/brooklyn/entity/rebind/RebindCatalogItemTest.java ---
@@ -171,6 +174,24 @@ public void testCanTagCatalogItemAfterRebind() {
toTag.tags().removeTag(tag);
}
+ @Test
+ public void testSameCatalogItemIdRemovalAndAdditionRebinds() throws Exception {
--- End diff --
nice to have a new test for this
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-brooklyn pull request: Persistence fix for removing and ...
Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:
https://github.com/apache/incubator-brooklyn/pull/334
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] incubator-brooklyn pull request: Persistence fix for removing and ...
Posted by ahgittin <gi...@git.apache.org>.
Github user ahgittin commented on the pull request:
https://github.com/apache/incubator-brooklyn/pull/334#issuecomment-63179508
LGTM, merging
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---