[OPENIDM-13895] Backport OPENIDM-12208: Clustered reconciliation fails due to paging cookie from ldap AD Created: 04/Oct/19  Updated: 21/Apr/20  Resolved: 17/Apr/20

Status: Closed
Project: OpenIDM
Component/s: Module - Core mapping, synchronization, reconciliation
Affects Version/s: OpenIDM 5.5.0, 6.0.0.2
Fix Version/s: OpenIDM 5.5.1.3, 6.5.0.3, 6.0.0.6

Type: Bug Priority: Major
Reporter: Matthias Grabiak Assignee: Matthias Grabiak
Resolution: Fixed Votes: 0
Labels: CLARK
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backport
is a backport of OPENIDM-12208 Clustered reconciliation fails due to... Closed
Target Version/s:
Verified Version/s:
Story Points: 2

 Description   

To produce the issue:

1. Set up mapping from ldap AD account to IDM managed/user, and set clusteredSourceReconEnabled to true.

2. Reconcile.

The recon fails with:

java.lang.IllegalArgumentException: Resource path '/scheduler/jobs/scheduler-service-group_$x$x$_clustered_recon-e3378e05-c41a-4c17-bf3d-5fe4768fab83-15062-sourcePage-AQAAAKgDAAD/////G3d4DDfFh+70coAtsahCfUeLKOebGw0YCpsWMvk0+PwNDYaXwx6ZQaPUNgyIaiPKAAAAAAEAAAAAAAAAAAAAAAAAAADSFAAAAAAAAAUAAAAAAAAABQAAAAAAAAACAAAAAAAAAAAAAAAAAAAABAAAABcAAwABCAAA+gcAAPoHAAAAAAAA9+GWAC96LEG6MaSaaJUcMAAAAAACAAAAAAAAACcEAADoAwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA/////27+0oZvaeejl0tp/ug2DLrFYUpOTLlmJM8G0qMuhgNbJQAAAAAAAAB/gAoACQAAAH+AABTSAAAAAAAAAAAAAAD/////AAAAAAAAAAAOAAAABQAAAP8AAABJTkRFWF8wMDAwMDAwMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAH+ACgAJAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAH+ACgAJ/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////wAA:0' contains empty path elements
	at org.forgerock.json.resource.ResourcePath.valueOf(ResourcePath.java:167)
	at org.forgerock.json.resource.Requests$AbstractRequestImpl.setResourcePath(Requests.java:103)
	at org.forgerock.json.resource.Requests.newReadRequest(Requests.java:1180)
	at org.forgerock.openidm.quartz.impl.RepoJobStore.readFromRepo(RepoJobStore.java:1703)
	at org.forgerock.openidm.quartz.impl.RepoJobStore.getJobWrapper(RepoJobStore.java:1455)
	at org.forgerock.openidm.quartz.impl.RepoJobStore.retrieveJob(RepoJobStore.java:1429)
	at org.quartz.core.QuartzScheduler.getJobDetail(QuartzScheduler.java:1431)
	at org.quartz.impl.StdScheduler.getJobDetail(StdScheduler.java:539)
	at org.forgerock.openidm.scheduler.AbstractScheduler.getJobDetail(AbstractScheduler.java:123)
	at org.forgerock.openidm.scheduler.AbstractScheduler.jobExists(AbstractScheduler.java:109)
	at org.forgerock.openidm.scheduler.JobRequestHandler.jobExists(JobRequestHandler.java:471)
	at org.forgerock.openidm.scheduler.JobRequestHandler.handleCreate(JobRequestHandler.java:129)
	at org.forgerock.json.resource.Router.handleCreate(Router.java:264)
	at org.forgerock.openidm.scheduler.SchedulerService.handleCreate(SchedulerService.java:321)
...
	at org.forgerock.openidm.sync.impl.cluster.SchedulerClusteredReconJobDispatch.scheduleClusteredReconJob(SchedulerClusteredReconJobDispatch.java:131)
	at org.forgerock.openidm.sync.impl.cluster.SchedulerClusteredReconJobDispatch.dispatchSourcePageRecon(SchedulerClusteredReconJobDispatch.java:77)
	at org.forgerock.openidm.sync.impl.ClusteredRecon.optionallyScheduleNextSourcePage(ClusteredRecon.java:214)
	at org.forgerock.openidm.sync.impl.ClusteredRecon.reconSourcePageCommonActions(ClusteredRecon.java:185)
	at org.forgerock.openidm.sync.impl.ClusteredRecon.initiateClusteredRecon(ClusteredRecon.java:144)
	at org.forgerock.openidm.sync.impl.ClusteredRecon.dispatchClusteredRecon(ClusteredRecon.java:75)
	at org.forgerock.openidm.sync.impl.ObjectMapping.lambda$newReconDelegate$0(ObjectMapping.java:289)
	at org.forgerock.openidm.sync.impl.ObjectMapping.recon(ObjectMapping.java:836)
	at org.forgerock.openidm.sync.impl.ReconciliationService.reconcile(ReconciliationService.java:525)
	at org.forgerock.openidm.sync.impl.ReconciliationService.access$000(ReconciliationService.java:91)
	at org.forgerock.openidm.sync.impl.ReconciliationService$1.run(ReconciliationService.java:457)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:748)

The paging cookie looks like from curl output /openidm/system/ad/account?_queryFilter=true&_pageSize=1000

    "resultCount": 1000,
    "pagedResultsCookie": "AQAAAKgDAAD%2F%2F%2F%2F%2FG3d4DDfFh%2B70coAtsahCfUeLKOebGw0YCpsWMvk0%2BPwNDYaXwx6ZQaPUNgyIaiPKAAAAAAEAAAAAAAAAAAAAAAAAAADSFAAAAAAAAAUAAAAAAAAABQAAAAAAAAACAAAAAAAAAA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%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2F%2FwAA%3A0",
    "totalPagedResultsPolicy": "NONE",
    "totalPagedResults": -1,
    "remainingPagedResults": -1
}

This is the same as the Resource path after "sourcePage"



 Comments   
Comment by Michal Orlik [ 14/Jan/20 ]

5.5.1.3-8a98f77
6.5.0.3-3119e74

Comment by Michal Orlik [ 21/Apr/20 ]

Reproduced and verified OK 6.0.0.6-ef1ecc27fa4

Generated at Sat Sep 26 00:31:05 UTC 2020 using Jira 7.13.12#713012-sha1:6e07c38070d5191bbf7353952ed38f111754533a.