I am using jira rest java client and when I try to instantiate a JiraRestClient :
JiraRestClient client = factory.createWithBasicHttpAuthentication(uri, JIRA_ADMIN_USERNAME, JIRA_ADMIN_PASSWORD);
I get the following error:
java.langClassCastException: Cannot cast com.sun.jersey.core.impl.provider.header.LocaleProvider to com.sun.jersey.spi.HeaderDelegateProvider at java.lang.Class.cast(Class.java:3369)
And I don't understand why because both classes to which the error refers to are from jersey-core which is a compiled dependency of jira-rest-java-client-core that I am using -https://mvnrepository.com/artifact/com.atlassian.jira/jira-rest-java-client-core/5.2.1
Does anyone know why this error occurs and how can I fix it? Thank you.