You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Alejandro Abdelnur (JIRA)" <ji...@apache.org> on 2011/08/17 21:37:27 UTC

[jira] [Commented] (HADOOP-7549) Use JDK ServiceLoader mechanism to find FileSystem implementations

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

Alejandro Abdelnur commented on HADOOP-7549:
--------------------------------------------

The current loading mechanism (from Hadoop configuration files) would be preserved and have precedence (although it would be deprecated).

A new method {{getScheme()}} in the {{FileSystem}} class would publish the scheme handled by the implementation.

The base {{FileSystem}} class will implement this method throwing an {{UnsupportedOperationException}}.

All {{FileSystem}} implementations in Hadoop will be retrofitted to implement this method declaring their scheme and they will be registered as services.

Custom {{FileSystem}} implementations not part of Hadoop will not break if they don't implement the {{getScheme()}} method. The will continue to work as before, (they just won't support the service loading). In a future release they could be retrofitted to use the service mechanism (if their authors choose to).

Because implementations registered in the configuration have precedence over implementations registered as services, modified implementations of Hadoop provided implementations will still override the service definitions.




> Use JDK ServiceLoader mechanism to find FileSystem implementations
> ------------------------------------------------------------------
>
>                 Key: HADOOP-7549
>                 URL: https://issues.apache.org/jira/browse/HADOOP-7549
>             Project: Hadoop Common
>          Issue Type: Improvement
>          Components: fs
>    Affects Versions: 0.23.0
>            Reporter: Alejandro Abdelnur
>            Assignee: Alejandro Abdelnur
>             Fix For: 0.23.0
>
>
> Currently configuring FileSystem implementations must be done by declaring the FileSystem class in the Hadoop configuration files (core-default.xml, ...).
> Using JDK ServiceLoader mechanism this configuration step can be avoided. Adding the JAR file with the additional FileSystem implementation would suffice. 
> This is similar to what is being proposed for compression codecs (HADOOP-7350).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira