You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2021/02/04 07:47:09 UTC

[GitHub] [pulsar] eolivelli commented on a change in pull request #9472: [Pulsar SQL] Fix injection factory cast error (fix master broken)

eolivelli commented on a change in pull request #9472:
URL: https://github.com/apache/pulsar/pull/9472#discussion_r570007562



##########
File path: pulsar-sql/presto-pulsar/src/main/java/org/apache/pulsar/sql/presto/PulsarSqlSchemaInfoProvider.java
##########
@@ -98,6 +99,7 @@ public String getTopicName() {
     }
 
     private SchemaInfo loadSchema(BytesSchemaVersion bytesSchemaVersion) throws PulsarAdminException {
+        Thread.currentThread().setContextClassLoader(InjectionManagerFactory.class.getClassLoader());

Review comment:
       if you set the Thread Context Classloader you have to restore it in a finally block




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org