JsonMapperException: No JsonMapper class is found
You might have faced the below exception org.jobrunr.utils.mapper.JsonMapperException
: No JsonMapper class is found. Make sure you have either Jackson, Gson or a JsonB compliant library available on your classpath while integrating the JobRunr API into your application to handle background tasks in Java.
Exception in thread "main" org.jobrunr.utils.mapper.JsonMapperException: No JsonMapper class is found. Make sure you have either Jackson, Gson or a JsonB compliant library available on your classpath
at org.jobrunr.configuration.JobRunrConfiguration.determineJsonMapper(JobRunrConfiguration.java:347)
at org.jobrunr.configuration.JobRunrConfiguration.<init>(JobRunrConfiguration.java:49)
at org.jobrunr.configuration.JobRunr.configure(JobRunr.java:44)
at org.websparrow.Test.main(Test.java:16)
Process finished with exit code 1
To resolve this issue add the bellow dependency along with the JobRunr dependency to your project build file.
Maven βΒ pom.xml
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>2.10.1</version>
</dependency>
Gradle βΒ build.gradle
implementation 'com.google.code.gson:gson:2.10.1'
Hope this will solve your issue π