I am getting below error… in Jira 10. Can anyone please help me with this. I am using Java 17.
java.lang.NoSuchMethodError: 'java.util.Collection com.atlassian.jira.util.collect.CollectionUtil.filter(java.util.Collection, com.atlassian.jira.util.Predicate)'
at com.thed.zephyr.je.attachment.ZTemporaryAttachmentsMonitor.getByEntityId(ZTemporaryAttachmentsMonitor.java:58) [?:?]
Below is the code where the error is coming…
public Collection<TemporaryAttachment> getByEntityId(final Long entityId)
{
final ArrayList<TemporaryAttachment> ret = new ArrayList<TemporaryAttachment>();
Iterable<TemporaryAttachment> values = CollectionUtil.filter(temporaryAttachments.values(), new Predicate<TemporaryAttachment>()
{
@Override
public boolean evaluate(final TemporaryAttachment input)
{
return entityId == null && input.getEntityId() == null || (entityId != null && entityId.equals(input.getEntityId()));
}
});
for(TemporaryAttachment item: values) {
ret.add(item);
}
Collections.sort(ret);
return ret;
}