{"action":"created","comment":{"url":"https://api.github.com/repos/ehcache/ehcache3/pulls/comments/57237173","id":57237173,"diff_hunk":"@@ -74,10 +68,25 @@ public ResourceUnit getUnit() {\n \n   /**\n    * {@inheritDoc}\n+   *\n+   * @throws IllegalArgumentException {@inheritDoc}\n    */\n   @Override\n-  public boolean isPersistent() {\n-    return persistent;\n+  public void validateUpdate(final ResourcePool newPool) {\n+    super.validateUpdate(newPool);\n+\n+    SizedResourcePool sizedPool = (SizedResourcePool)newPool;\n+    // Ensure unit type has not changed\n+    if (!this.getUnit().getClass().equals(sizedPool.getUnit().getClass())) {","path":"core/src/main/java/org/ehcache/core/config/SizedResourcePoolImpl.java","position":64,"original_position":64,"commit_id":"89a1a89a9e36362514cc353bc7aa21549c4e6b88","original_commit_id":"89a1a89a9e36362514cc353bc7aa21549c4e6b88","user":{"login":"cljohnso","id":8737388,"avatar_url":"https://avatars.githubusercontent.com/u/8737388?v=3","gravatar_id":"","url":"https://api.github.com/users/cljohnso","html_url":"https://github.com/cljohnso","followers_url":"https://api.github.com/users/cljohnso/followers","following_url":"https://api.github.com/users/cljohnso/following{/other_user}","gists_url":"https://api.github.com/users/cljohnso/gists{/gist_id}","starred_url":"https://api.github.com/users/cljohnso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cljohnso/subscriptions","organizations_url":"https://api.github.com/users/cljohnso/orgs","repos_url":"https://api.github.com/users/cljohnso/repos","events_url":"https://api.github.com/users/cljohnso/events{/privacy}","received_events_url":"https://api.github.com/users/cljohnso/received_events","type":"User","site_admin":false},"body":"The old code in `org.ehcache.core.config.ResourcePoolsImpl#validateAndMerge` prevented any unit change -- even among `MemoryUnit` constants.  After a brief discussion with @chrisdennis, I switched to this method to prevent switching between `MemoryUnit` and `EntryUnit`.","created_at":"2016-03-23T21:06:22Z","updated_at":"2016-03-23T21:06:22Z","html_url":"https://github.com/ehcache/ehcache3/pull/886#discussion_r57237173","pull_request_url":"https://api.github.com/repos/ehcache/ehcache3/pulls/886","_links":{"self":{"href":"https://api.github.com/repos/ehcache/ehcache3/pulls/comments/57237173"},"html":{"href":"https://github.com/ehcache/ehcache3/pull/886#discussion_r57237173"},"pull_request":{"href":"https://api.github.com/repos/ehcache/ehcache3/pulls/886"}}},"pull_request":{"url":"https://api.github.com/repos/ehcache/ehcache3/pulls/886","id":63936790,"html_url":"https://github.com/ehcache/ehcache3/pull/886","diff_url":"https://github.com/ehcache/ehcache3/pull/886.diff","patch_url":"https://github.com/ehcache/ehcache3/pull/886.patch","issue_url":"https://api.github.com/repos/ehcache/ehcache3/issues/886","number":886,"state":"open","locked":false,"title":"Issue #833 Create clustered store in support of clustered cache","user":{"login":"cljohnso","id":8737388,"avatar_url":"https://avatars.githubusercontent.com/u/8737388?v=3","gravatar_id":"","url":"https://api.github.com/users/cljohnso","html_url":"https://github.com/cljohnso","followers_url":"https://api.github.com/users/cljohnso/followers","following_url":"https://api.github.com/users/cljohnso/following{/other_user}","gists_url":"https://api.github.com/users/cljohnso/gists{/gist_id}","starred_url":"https://api.github.com/users/cljohnso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cljohnso/subscriptions","organizations_url":"https://api.github.com/users/cljohnso/orgs","repos_url":"https://api.github.com/users/cljohnso/repos","events_url":"https://api.github.com/users/cljohnso/events{/privacy}","received_events_url":"https://api.github.com/users/cljohnso/received_events","type":"User","site_admin":false},"body":"This commit addresses Issues #833 and #834 and partially addresses\r\nIssue #760.\r\n\r\nThis commit lays the foundation for a ClusteredStore along with many\r\nunderlying support constructs.\r\n\r\n* The byte-count 'memory-unit' and 'resource-unit' enumeration values\r\n  in ehcache-core.xsd are changed to upper-case (with the exception of\r\n  'kB').\r\n* ResourcePool is split into ResourcePool and SizedResourcePool along\r\n  with associated implementations.\r\n* The XAStore.provider 'rank' method is changed to use 1000 as its base\r\n  value.  This makes room for other 'grouping' providers.\r\n* MaintainableService and PersistableResourceService are marked as\r\n  plural services.\r\n* Use of org.terracotta.offheapstore.util.MemoryUnit in the clustering\r\n  code is changed to org.ehcache.config.units.MemoryUnit.\r\n* A 'with(ResourcePool)' method is added to ResourcePoolsBuilder to\r\n  accept non-core resources.\r\n* The behavior of the ResourcePoolsBuilder 'with', 'heap', 'offheap',\r\n  and 'disk' methods are changed to throw an IllegalArgumentException\r\n  when a resource pool of a type already existing in the pool collection\r\n  instead of silently replacing the existing pool.  The\r\n  'withReplacing(ResourcePool)' method is added for preserve the old\r\n  add/replace behavior.\r\n* Removes the private ConfigurationParser.ResourcePoolImpl class in\r\n  deference to the \"regular\" implementation.\r\n\r\nClusteredStore support specifics include:\r\n\r\n* Introduction of the CacheResourceConfigurationParser and\r\n  ClusteredResourceConfigurationParser to handle parsing of the\r\n  <cluster-fixed> and <cluster-shared> cache resource elements.\r\n  ConfigurationParser is updated to handle parsing resource extension\r\n  elements.\r\n* ClusteredResourceType, ClusteredResourcePool, and\r\n  ClusteredResourcePoolBuilder are introduced to represent clustered\r\n  cache resources.\r\n\r\n-----\r\n\r\nThe `ClusteredStore` implementation in this commit is a rudimentary shell -- it relies on having a heap (or other store) configured to be functional.  This commit also lacks code which links clustered resources to the `ClusteringService` configuration.","created_at":"2016-03-23T19:10:19Z","updated_at":"2016-03-23T21:06:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"dbcc8bc8894f85484c5747cfef85d0a78fa625a4","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ehcache/ehcache3/pulls/886/commits","review_comments_url":"https://api.github.com/repos/ehcache/ehcache3/pulls/886/comments","review_comment_url":"https://api.github.com/repos/ehcache/ehcache3/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ehcache/ehcache3/issues/886/comments","statuses_url":"https://api.github.com/repos/ehcache/ehcache3/statuses/89a1a89a9e36362514cc353bc7aa21549c4e6b88","head":{"label":"cljohnso:issue-833","ref":"issue-833","sha":"89a1a89a9e36362514cc353bc7aa21549c4e6b88","user":{"login":"cljohnso","id":8737388,"avatar_url":"https://avatars.githubusercontent.com/u/8737388?v=3","gravatar_id":"","url":"https://api.github.com/users/cljohnso","html_url":"https://github.com/cljohnso","followers_url":"https://api.github.com/users/cljohnso/followers","following_url":"https://api.github.com/users/cljohnso/following{/other_user}","gists_url":"https://api.github.com/users/cljohnso/gists{/gist_id}","starred_url":"https://api.github.com/users/cljohnso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cljohnso/subscriptions","organizations_url":"https://api.github.com/users/cljohnso/orgs","repos_url":"https://api.github.com/users/cljohnso/repos","events_url":"https://api.github.com/users/cljohnso/events{/privacy}","received_events_url":"https://api.github.com/users/cljohnso/received_events","type":"User","site_admin":false},"repo":{"id":26443141,"name":"ehcache3","full_name":"cljohnso/ehcache3","owner":{"login":"cljohnso","id":8737388,"avatar_url":"https://avatars.githubusercontent.com/u/8737388?v=3","gravatar_id":"","url":"https://api.github.com/users/cljohnso","html_url":"https://github.com/cljohnso","followers_url":"https://api.github.com/users/cljohnso/followers","following_url":"https://api.github.com/users/cljohnso/following{/other_user}","gists_url":"https://api.github.com/users/cljohnso/gists{/gist_id}","starred_url":"https://api.github.com/users/cljohnso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cljohnso/subscriptions","organizations_url":"https://api.github.com/users/cljohnso/orgs","repos_url":"https://api.github.com/users/cljohnso/repos","events_url":"https://api.github.com/users/cljohnso/events{/privacy}","received_events_url":"https://api.github.com/users/cljohnso/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/cljohnso/ehcache3","description":"Ehcache 3.x line ","fork":true,"url":"https://api.github.com/repos/cljohnso/ehcache3","forks_url":"https://api.github.com/repos/cljohnso/ehcache3/forks","keys_url":"https://api.github.com/repos/cljohnso/ehcache3/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cljohnso/ehcache3/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cljohnso/ehcache3/teams","hooks_url":"https://api.github.com/repos/cljohnso/ehcache3/hooks","issue_events_url":"https://api.github.com/repos/cljohnso/ehcache3/issues/events{/number}","events_url":"https://api.github.com/repos/cljohnso/ehcache3/events","assignees_url":"https://api.github.com/repos/cljohnso/ehcache3/assignees{/user}","branches_url":"https://api.github.com/repos/cljohnso/ehcache3/branches{/branch}","tags_url":"https://api.github.com/repos/cljohnso/ehcache3/tags","blobs_url":"https://api.github.com/repos/cljohnso/ehcache3/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cljohnso/ehcache3/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cljohnso/ehcache3/git/refs{/sha}","trees_url":"https://api.github.com/repos/cljohnso/ehcache3/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cljohnso/ehcache3/statuses/{sha}","languages_url":"https://api.github.com/repos/cljohnso/ehcache3/languages","stargazers_url":"https://api.github.com/repos/cljohnso/ehcache3/stargazers","contributors_url":"https://api.github.com/repos/cljohnso/ehcache3/contributors","subscribers_url":"https://api.github.com/repos/cljohnso/ehcache3/subscribers","subscription_url":"https://api.github.com/repos/cljohnso/ehcache3/subscription","commits_url":"https://api.github.com/repos/cljohnso/ehcache3/commits{/sha}","git_commits_url":"https://api.github.com/repos/cljohnso/ehcache3/git/commits{/sha}","comments_url":"https://api.github.com/repos/cljohnso/ehcache3/comments{/number}","issue_comment_url":"https://api.github.com/repos/cljohnso/ehcache3/issues/comments{/number}","contents_url":"https://api.github.com/repos/cljohnso/ehcache3/contents/{+path}","compare_url":"https://api.github.com/repos/cljohnso/ehcache3/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cljohnso/ehcache3/merges","archive_url":"https://api.github.com/repos/cljohnso/ehcache3/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cljohnso/ehcache3/downloads","issues_url":"https://api.github.com/repos/cljohnso/ehcache3/issues{/number}","pulls_url":"https://api.github.com/repos/cljohnso/ehcache3/pulls{/number}","milestones_url":"https://api.github.com/repos/cljohnso/ehcache3/milestones{/number}","notifications_url":"https://api.github.com/repos/cljohnso/ehcache3/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cljohnso/ehcache3/labels{/name}","releases_url":"https://api.github.com/repos/cljohnso/ehcache3/releases{/id}","deployments_url":"https://api.github.com/repos/cljohnso/ehcache3/deployments","created_at":"2014-11-10T15:48:52Z","updated_at":"2016-01-28T21:08:19Z","pushed_at":"2016-03-23T19:24:30Z","git_url":"git://github.com/cljohnso/ehcache3.git","ssh_url":"git@github.com:cljohnso/ehcache3.git","clone_url":"https://github.com/cljohnso/ehcache3.git","svn_url":"https://github.com/cljohnso/ehcache3","homepage":"ehcache.org","size":7729,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ehcache:master","ref":"master","sha":"77a8ba2d1b1384799a690cdc213b87c6132ae007","user":{"login":"ehcache","id":5504982,"avatar_url":"https://avatars.githubusercontent.com/u/5504982?v=3","gravatar_id":"","url":"https://api.github.com/users/ehcache","html_url":"https://github.com/ehcache","followers_url":"https://api.github.com/users/ehcache/followers","following_url":"https://api.github.com/users/ehcache/following{/other_user}","gists_url":"https://api.github.com/users/ehcache/gists{/gist_id}","starred_url":"https://api.github.com/users/ehcache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ehcache/subscriptions","organizations_url":"https://api.github.com/users/ehcache/orgs","repos_url":"https://api.github.com/users/ehcache/repos","events_url":"https://api.github.com/users/ehcache/events{/privacy}","received_events_url":"https://api.github.com/users/ehcache/received_events","type":"Organization","site_admin":false},"repo":{"id":17224514,"name":"ehcache3","full_name":"ehcache/ehcache3","owner":{"login":"ehcache","id":5504982,"avatar_url":"https://avatars.githubusercontent.com/u/5504982?v=3","gravatar_id":"","url":"https://api.github.com/users/ehcache","html_url":"https://github.com/ehcache","followers_url":"https://api.github.com/users/ehcache/followers","following_url":"https://api.github.com/users/ehcache/following{/other_user}","gists_url":"https://api.github.com/users/ehcache/gists{/gist_id}","starred_url":"https://api.github.com/users/ehcache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ehcache/subscriptions","organizations_url":"https://api.github.com/users/ehcache/orgs","repos_url":"https://api.github.com/users/ehcache/repos","events_url":"https://api.github.com/users/ehcache/events{/privacy}","received_events_url":"https://api.github.com/users/ehcache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ehcache/ehcache3","description":"Ehcache 3.x line ","fork":false,"url":"https://api.github.com/repos/ehcache/ehcache3","forks_url":"https://api.github.com/repos/ehcache/ehcache3/forks","keys_url":"https://api.github.com/repos/ehcache/ehcache3/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ehcache/ehcache3/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ehcache/ehcache3/teams","hooks_url":"https://api.github.com/repos/ehcache/ehcache3/hooks","issue_events_url":"https://api.github.com/repos/ehcache/ehcache3/issues/events{/number}","events_url":"https://api.github.com/repos/ehcache/ehcache3/events","assignees_url":"https://api.github.com/repos/ehcache/ehcache3/assignees{/user}","branches_url":"https://api.github.com/repos/ehcache/ehcache3/branches{/branch}","tags_url":"https://api.github.com/repos/ehcache/ehcache3/tags","blobs_url":"https://api.github.com/repos/ehcache/ehcache3/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ehcache/ehcache3/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ehcache/ehcache3/git/refs{/sha}","trees_url":"https://api.github.com/repos/ehcache/ehcache3/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ehcache/ehcache3/statuses/{sha}","languages_url":"https://api.github.com/repos/ehcache/ehcache3/languages","stargazers_url":"https://api.github.com/repos/ehcache/ehcache3/stargazers","contributors_url":"https://api.github.com/repos/ehcache/ehcache3/contributors","subscribers_url":"https://api.github.com/repos/ehcache/ehcache3/subscribers","subscription_url":"https://api.github.com/repos/ehcache/ehcache3/subscription","commits_url":"https://api.github.com/repos/ehcache/ehcache3/commits{/sha}","git_commits_url":"https://api.github.com/repos/ehcache/ehcache3/git/commits{/sha}","comments_url":"https://api.github.com/repos/ehcache/ehcache3/comments{/number}","issue_comment_url":"https://api.github.com/repos/ehcache/ehcache3/issues/comments{/number}","contents_url":"https://api.github.com/repos/ehcache/ehcache3/contents/{+path}","compare_url":"https://api.github.com/repos/ehcache/ehcache3/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ehcache/ehcache3/merges","archive_url":"https://api.github.com/repos/ehcache/ehcache3/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ehcache/ehcache3/downloads","issues_url":"https://api.github.com/repos/ehcache/ehcache3/issues{/number}","pulls_url":"https://api.github.com/repos/ehcache/ehcache3/pulls{/number}","milestones_url":"https://api.github.com/repos/ehcache/ehcache3/milestones{/number}","notifications_url":"https://api.github.com/repos/ehcache/ehcache3/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ehcache/ehcache3/labels{/name}","releases_url":"https://api.github.com/repos/ehcache/ehcache3/releases{/id}","deployments_url":"https://api.github.com/repos/ehcache/ehcache3/deployments","created_at":"2014-02-26T20:39:16Z","updated_at":"2016-03-22T11:10:09Z","pushed_at":"2016-03-23T19:24:31Z","git_url":"git://github.com/ehcache/ehcache3.git","ssh_url":"git@github.com:ehcache/ehcache3.git","clone_url":"https://github.com/ehcache/ehcache3.git","svn_url":"https://github.com/ehcache/ehcache3","homepage":"http://www.ehcache.org","size":9954,"stargazers_count":324,"watchers_count":324,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":179,"mirror_url":null,"open_issues_count":58,"forks":179,"open_issues":58,"watchers":324,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ehcache/ehcache3/pulls/886"},"html":{"href":"https://github.com/ehcache/ehcache3/pull/886"},"issue":{"href":"https://api.github.com/repos/ehcache/ehcache3/issues/886"},"comments":{"href":"https://api.github.com/repos/ehcache/ehcache3/issues/886/comments"},"review_comments":{"href":"https://api.github.com/repos/ehcache/ehcache3/pulls/886/comments"},"review_comment":{"href":"https://api.github.com/repos/ehcache/ehcache3/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ehcache/ehcache3/pulls/886/commits"},"statuses":{"href":"https://api.github.com/repos/ehcache/ehcache3/statuses/89a1a89a9e36362514cc353bc7aa21549c4e6b88"}}}}