Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

OSGI Bundle for MSSQL - error javax.net.SocketFactory classdefnotfound

Avatar

Avatar
Affirm 3
Level 2
crich2784
Level 2

Likes

4 likes

Total Posts

32 posts

Correct Reply

2 solutions
Top badges earned
Affirm 3
Boost 3
Give Back
Validate 1
Boost 1
View profile

Avatar
Affirm 3
Level 2
crich2784
Level 2

Likes

4 likes

Total Posts

32 posts

Correct Reply

2 solutions
Top badges earned
Affirm 3
Boost 3
Give Back
Validate 1
Boost 1
View profile
crich2784
Level 2

03-06-2021

I am trying to create an OSGI bundle for MSSQL driver.  I'll post my Manifest below.

Basically, I get an error javax.net.SocketFactory no class def found.

 

 

com.adobe.granite.workflow.WorkflowException: Process execution resulted in an error
	at com.adobe.granite.workflow.core.job.HandlerBase.executeProcess(HandlerBase.java:201) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0016]
	at com.adobe.granite.workflow.core.job.JobHandler.process(JobHandler.java:260) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0016]
	at org.apache.sling.event.impl.jobs.JobConsumerManager$JobConsumerWrapper.process(JobConsumerManager.java:502) [org.apache.sling.event:4.2.12]
	at org.apache.sling.event.impl.jobs.queues.JobQueueImpl.startJob(JobQueueImpl.java:293) [org.apache.sling.event:4.2.12]
	at org.apache.sling.event.impl.jobs.queues.JobQueueImpl.access$100(JobQueueImpl.java:60) [org.apache.sling.event:4.2.12]
	at org.apache.sling.event.impl.jobs.queues.JobQueueImpl$1.run(JobQueueImpl.java:229) [org.apache.sling.event:4.2.12]
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.NoClassDefFoundError: javax/net/SocketFactory
	at com.microsoft.sqlserver.jdbc.SocketFinder.getSocketFactory(IOBuffer.java:2636)
	at com.microsoft.sqlserver.jdbc.SocketFinder.getConnectedSocket(IOBuffer.java:2687)
	at com.microsoft.sqlserver.jdbc.SocketFinder.getDefaultSocket(IOBuffer.java:2674)
	at com.microsoft.sqlserver.jdbc.SocketFinder.findSocket(IOBuffer.java:2358)
	at com.microsoft.sqlserver.jdbc.TDSChannel.open(IOBuffer.java:672)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:2747)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:2418)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.connectInternal(SQLServerConnection.java:2265)
	at com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:1291)

 

Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Jdbc
Bundle-SymbolicName: com.s360g.mssql.jdbc
Bundle-Version: 1.0.0
Automatic-Module-Name: com.s360g.mssql.jdbc
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
Export-Package: com.microsoft.sqlserver.jdbc,
 microsoft.sql
Import-Package: javax.naming,
 javax.naming.spi,
 javax.net,
 javax.net.ssl,
 javax.security.auth,
 javax.security.auth.login,
 javax.security.auth.x500,
 javax.sql,
 javax.transaction.xa,
 javax.xml.parsers,
 javax.xml.stream,
 javax.xml.transform,
 javax.xml.transform.dom,
 javax.xml.transform.sax,
 javax.xml.transform.stax,
 javax.xml.transform.stream,
 org.ietf.jgss,
 org.w3c.dom,
 org.xml.sax,
 org.xml.sax.helpers

 

crich2784_0-1622724951606.png

 

Help would be appreciated.

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Coach
Employee
Jörg_Hoh
Employee

Likes

1,114 likes

Total Posts

3,148 posts

Correct Reply

1,072 solutions
Top badges earned
Coach
Give back 600
Ignite 5
Ignite 3
Ignite 1
View profile

Avatar
Coach
Employee
Jörg_Hoh
Employee

Likes

1,114 likes

Total Posts

3,148 posts

Correct Reply

1,072 solutions
Top badges earned
Coach
Give back 600
Ignite 5
Ignite 3
Ignite 1
View profile
Jörg_Hoh
Employee

03-06-2021

javax.net should be provided by the java runtime, and for that reason the Felix Framework makes the export of that package. Nevertheless I am not sure what happens if that package is provided by the Java runtime.

 

What version of Java are you using? Can you show the version as exposed in the MBean java.lang:Runtime of AEM (/system/console/jmx)

Answers (0)