[ https://issues.apache.org/jira/browse/SLING-12250?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17820728#comment-17820728 ]
Henry Kuijpers commented on SLING-12250: ---------------------------------------- I used: ``` await() .until(() -> context.resourceResolver().resolve("/my-vanity"), path("/content/something/my-page-with-vanity")); ``` Error: [ERROR] MyTest.apiThrowsException ยป RejectedExecution Task org.apache.jackrabbit.oak.commons.concurrent.NotifyingFutureTask@7e538a1[Not completed, task = org.apache.jackrabbit.oak.spi.commit.BackgroundObserver$1$1@21d876a6] rejected from java.util.concurrent.ThreadPoolExecutor@359f9c02[Shutting down, pool size = 1, active threads = 1, queued tasks = 0, completed tasks = 8] It looks like it is not able to resolve the vanity path in time (by default 10 seconds) - We're running our build with parallel test execution (JUnit). Maybe I can raise this limit, but I feel there should be a better solution. > Adding Resource with sling:vanityPath set causes mismatch when resolving > vanity URL (timing issue) > -------------------------------------------------------------------------------------------------- > > Key: SLING-12250 > URL: https://issues.apache.org/jira/browse/SLING-12250 > Project: Sling > Issue Type: Bug > Components: Testing > Affects Versions: Testing Sling Mock 3.4.18 > Reporter: Henry Kuijpers > Priority: Major > > It could happen that a Resource containing sling:vanityPath is added and then > resolved, but the Resource did not end up yet in the vanity logic. > Observed with JCR_OAK mock context. > Adding Thread.sleep(1000) fixes the issue, but it's of course not a very good > solution. -- This message was sent by Atlassian Jira (v8.20.10#820010)