Can you any one help me to get rid of for follow error -
Error Detail Message:
Project key is not set. You need to set a project key in the Sync Rules for {0} connection.
Error Stack Trace:
com.exalate.api.exception.script.CreateProcessorException: Project key is not set. You need to set a project key in the Sync Rules for {0} connection. at jcloudnode.services.jcloud.IssueService.$anonfun$getBasicHubIssueTypeAndProjectKey$8(IssueService.scala:249) at scala.Option.getOrElse(Option.scala:201) at jcloudnode.services.jcloud.IssueService.getBasicHubIssueTypeAndProjectKey(IssueService.scala:244) at jcloudnode.services.jcloud.IssueService.$anonfun$prepareHubIssueForCreate$13(IssueService.scala:1710) at scala.Option.getOrElse(Option.scala:201) at jcloudnode.services.jcloud.IssueService.prepareHubIssueForCreate(IssueService.scala:1710) at jcloudnode.services.jcloud.IssueService.createIssue(IssueService.scala:108) at jcloudnode.services.jcloud.hubobjects.JCloudHubObjectService.createEntity(JCloudHubObjectService.scala:237) at com.exalate.replication.services.processor.ApplyScriptResultService.createEntity(ApplyScriptResultService.scala:81) at com.exalate.replication.services.processor.CreateIssueProcessor.$anonfun$executeScriptRules$4(CreateIssueProcessor.scala:325) at scala.concurrent.impl.Promise$Transformation.run(Promise.scala:470) at akka.dispatch.BatchingExecutor$AbstractBatch.processBatch(BatchingExecutor.scala:63) at akka.dispatch.BatchingExecutor$BlockableBatch.$anonfun$run$1(BatchingExecutor.scala:100) at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.scala:18) at scala.concurrent.BlockContext$.withBlockContext(BlockContext.scala:94) at akka.dispatch.BatchingExecutor$BlockableBatch.run(BatchingExecutor.scala:100) at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:49) at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(ForkJoinExecutorConfigurator.scala:48) at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373) at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182) at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655) at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622) at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
I have checked and it seems that the project key is missing in the part, when syncing the sub task (between line 100 - 109):
if(firstSync && replica.parentId && replica.type.name == "Sub-task"){
issue.typeName = "Sub-task" //Make sure to use the right subtask type here.
def localParent = nodeHelper.getLocalIssueFromRemoteId(replica.parentId.toLong())
if(localParent){
issue.parentId = localParent.id
} else {
throw new com.exalate.api.exception.IssueTrackerException("Subtask cannot be created: parent issue with remote id " + replica.parentId + " was not found. Please make sure the parent issue is synchronized before resolving this error" )
}
}
Add the project key here and then check, if the issue remains, share the local and remote replica.
I have updated issue key on the between line 100 - 109. please check below. Unfortunately the error still exits.
//}
if(firstSync && replica.parentId && replica.type.name == “Sub-task”){
issue.projectKey = “DIGITALAKS”
issue.typeName = “Sub-task” //Make sure to use the right subtask type here.
def localParent = nodeHelper.getLocalIssueFromRemoteId(replica.parentId.toLong())
if(localParent){
issue.parentId = localParent.id
} else {
throw new com.exalate.api.exception.IssueTrackerException(“Subtask cannot be created: parent issue with remote id " + replica.parentId + " was not found. Please make sure the parent issue is synchronized before resolving this error” )
}
}
About replica:
Local replica does not exist - This message is showing.
Remote replica: Attched Remote Replica.docx (19.2 KB)
Whereas the error message is indicating that the issue is with the first sync, and as per the incoming sync (first sync), the project key defined there is as “DIGITALAKS”:
It seems that there is something missing in regards to Project Key, as it is picking up a different project key.
May I know if you are using triggers to initiate the Exalate operation? If yes, then try exalating the work-item manually for the project key “DIGITALAKS” and then check.