You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Fallback to platform classes for Database Reader's isolated ClassLoader #338
Picking up from an older issue regarding some trouble with class loading from within isolated contexts such as Database Readers (see here).
Basically, in these contexts there is a separate ClassLoader built specifically based on the Resources assigned to those Channels/Connectors. This would allow different versions of different custom drivers to be used in parallel (ClassLoader instantiated here, more info in comments here).
Place it somewhere accessible to OIE but outside of server-lib or custom-lib
In OIE Settings, create a Resource containing only ojdbc17.jar
Create a Channel, assign the Resource to its Dependencies
Configure source as Database Reader with settings as follows:
Driver: Oracle
URL: jdbc:oracle:thin:@
Username: username
Password: password
SQL: select
Attempt to deploy the channel
There should be a DeployException caused by NoClassDefFoundError: java/sql/Driver
Note that attempting to deploy the channel without having the Resource assigned should result in a different error (StartException: Failed to start channel fallback_test), which shows that the default server-lib ojdbc class loads successfully.
With the official move to Java 9+, this could now be solved by having the isolated ClassLoader fall back to ClassLoader.getPlatformClassLoader() as its parent, effectively replicating the behavior previously seen with null parent on Java 8.
Activity
Fix isolated ClassLoader visibility by setting parent to Platform Cla…
Fix isolated ClassLoader visibility by setting parent to Platform Cla…
Fix isolated ClassLoader visibility by setting parent to Platform Cla…