It seems like I needed to deploy the h2-1.3.158.jar
along with my bundle and add the make some edits in the pom.xml
as follows:
<build>
<defaultGoal>install</defaultGoal>
<plugins>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<instructions>
<Export-Package>
com.ct.service.userService.*,
<!--org.h2.* No need to export these dependency -->
</Export-Package>
<Import-Package>
*,
org.codehaus.jackson.jaxrs,
org.h2 <!-- Needed to import the dependencies. -->
</Import-Package>
<!--<Embed-Dependency>h2</Embed-Dependency> No need of embedding -->
</instructions>
</configuration>
</plugin>
</plugins>