@Test public void testCreateCacheWithCommitInfo() throws RepositoryException { for (Authorizable a : authorizables) { try { Tree node = getAuthorizableTree(a); Tree cache = TreeUtil.addChild(node, CacheConstants.REP_CACHE, CacheConstants.NT_REP_CACHE); cache.setProperty(CacheConstants.REP_EXPIRATION, 1L, Type.LONG); root.commit(CacheValidatorProvider.asCommitAttributes()); fail("Creating rep:cache node below a user or group must fail."); } catch (CommitFailedException e) { assertTrue(e.isConstraintViolation()); assertEquals(34, e.getCode()); } } }
static Map<String, Object> asCommitAttributes() { return Collections.singletonMap(CommitMarker.KEY, CommitMarker.INSTANCE); }
CacheValidatorProvider extends ValidatorProvider implements CacheConstants { static Map<String, Object> asCommitAttributes() { return Collections.singletonMap(CommitMarker.KEY, CommitMarker.INSTANCE); } }
CacheValidatorProvider extends ValidatorProvider implements CacheConstants { static Map<String, Object> asCommitAttributes() { return Collections.singletonMap(CommitMarker.KEY, CommitMarker.INSTANCE); } CacheValidatorProvider(@NotNull Set<Principal> principals, @NotNull TreeProvider treeProvider); }
CacheValidatorProvider extends ValidatorProvider implements CacheConstants { static Map<String, Object> asCommitAttributes() { return Collections.singletonMap(CommitMarker.KEY, CommitMarker.INSTANCE); } CacheValidatorProvider(@NotNull Set<Principal> principals, @NotNull TreeProvider treeProvider);  }
CacheValidatorProvider extends ValidatorProvider implements CacheConstants { static Map<String, Object> asCommitAttributes() { return Collections.singletonMap(CommitMarker.KEY, CommitMarker.INSTANCE); } CacheValidatorProvider(@NotNull Set<Principal> principals, @NotNull TreeProvider treeProvider);   }