[ 
https://issues.apache.org/jira/browse/HDFS-7075?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14136489#comment-14136489
 ] 

Colin Patrick McCabe commented on HDFS-7075:
--------------------------------------------

I think this should be ok since for Hadoop, the classloader we use for 
{{KeyProviderFactory}} is also the classloader we want to use for loading the 
{{KeyProvider}} objects.  If we ever decide to use multiple classloaders, we 
can revisit this.

By the way, I found that when using the JNI invocation API, our thread context 
classloader is null, and our system classloader appears to have the exploded 
classpaths we set in the {{CLASSPATH}} environment variable when launching the 
program.  I found some references indicating that the system classloader is 
normally used when JNI calls {{ServiceLoader}}, but for some reason, that 
doesn't seem to be the case here.

> hadoop-fuse-dfs fails because it cannot find JavaKeyStoreProvider$Factory
> -------------------------------------------------------------------------
>
>                 Key: HDFS-7075
>                 URL: https://issues.apache.org/jira/browse/HDFS-7075
>             Project: Hadoop HDFS
>          Issue Type: Bug
>    Affects Versions: 2.6.0
>            Reporter: Colin Patrick McCabe
>            Assignee: Colin Patrick McCabe
>         Attachments: HDFS-7075.001.patch
>
>
> hadoop-fuse-dfs fails complaining with:
> {code}
> java.util.ServiceConfigurationError: 
> org.apache.hadoop.crypto.key.KeyProviderFactory: Provider 
> org.apache.hadoop.crypto.key.JavaKeyStoreProvider$Factory not found
> {code}
> Here is an example of the hadoop-fuse-dfs debug output.
> {code}
> 14/09/04 13:49:04 WARN crypto.CryptoCodec: Crypto codec 
> org.apache.hadoop.crypto.OpensslAesCtrCryptoCodec is not available.
> hdfsBuilderConnect(forceNewInstance=1, 
> nn=hdfs://hdfs-cdh5-secure-1.vpc.cloudera.com:8020, port=0, 
> kerbTicketCachePath=/tmp/krb5cc_0, userName=root) error:
> java.util.ServiceConfigurationError: 
> org.apache.hadoop.crypto.key.KeyProviderFactory: Provider 
> org.apache.hadoop.crypto.key.JavaKeyStoreProvider$Factory not found
>       at java.util.ServiceLoader.fail(ServiceLoader.java:231)
>       at java.util.ServiceLoader.access$300(ServiceLoader.java:181)
>       at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:365)
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to