You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by NicoK <gi...@git.apache.org> on 2017/02/15 14:15:53 UTC

[GitHub] flink pull request #3322: [FLINK-4813][flink-test-utils] make the hadoop-min...

GitHub user NicoK opened a pull request:

    https://github.com/apache/flink/pull/3322

    [FLINK-4813][flink-test-utils] make the hadoop-minikdc dependency optional

    This removes the need to add the `maven-bundle-plugin`plugin for most projects using `flink-test-utils`.
    
    Instead, any project using `flink-test-utils` that also requires
    `SecureTestEnvironment` must add a dependency to `hadoop-minikdc` itself, e.g. in
    `pom.xml`:
    
    ```xml
       ...
       <dependencies>
         <dependency>
           <groupId>org.apache.hadoop</groupId>
           <artifactId>hadoop-minikdc</artifactId>
           <version>${minikdc.version}</version>
           <scope>compile</scope>
         </dependency>
       ...
       </dependencies>
       ...
    
       <build>
         <plugins>
           <!--
             https://issues.apache.org/jira/browse/DIRSHARED-134
             Required to pull the Mini-KDC transitive dependency
           -->
           <plugin>
           <groupId>org.apache.felix</groupId>
           <artifactId>maven-bundle-plugin</artifactId>
           <version>3.0.1</version>
           <inherited>true</inherited>
           <extensions>true</extensions>
         </plugin>
       ...
    ```

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/NicoK/flink flink-4813

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/3322.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #3322
    
----
commit db3da8bbdcee1b1a72bd7638864b7d052c7f1c83
Author: Nico Kruber <ni...@data-artisans.com>
Date:   2017-02-15T13:24:32Z

    [FLINK-4813][flink-test-utils] make the hadoop-minikdc dependency optional
    
    With this change, any project using flink-test-utils which also requires
    SecureTestEnvironment must add a dependency to hadoop-minikdc itself, e.g. in
    pom.xml:
    
       ...
       <dependencies>
         <dependency>
           <groupId>org.apache.hadoop</groupId>
           <artifactId>hadoop-minikdc</artifactId>
           <version>${minikdc.version}</version>
           <scope>compile</scope>
         </dependency>
       ...
       </dependencies>
       ...
    
       <build>
         <plugins>
           <!--
             https://issues.apache.org/jira/browse/DIRSHARED-134
             Required to pull the Mini-KDC transitive dependency
           -->
           <plugin>
           <groupId>org.apache.felix</groupId>
           <artifactId>maven-bundle-plugin</artifactId>
           <version>3.0.1</version>
           <inherited>true</inherited>
           <extensions>true</extensions>
         </plugin>
       ...

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request #3322: [FLINK-4813][flink-test-utils] make the hadoop-min...

Posted by StephanEwen <gi...@git.apache.org>.
Github user StephanEwen commented on a diff in the pull request:

    https://github.com/apache/flink/pull/3322#discussion_r101565321
  
    --- Diff: flink-test-utils-parent/flink-test-utils/src/main/java/org/apache/flink/test/util/SecureTestEnvironment.java ---
    @@ -37,9 +37,39 @@
     /**
      * Helper {@link SecureTestEnvironment} to handle MiniKDC lifecycle.
      * This class can be used to start/stop MiniKDC and create secure configurations for MiniDFSCluster
    - * and MiniYarn
    + * and MiniYarn.
    + *
    + * If you use this class in your project, please make sure to add a dependency to
    + * <tt>hadoop-minikdc</tt>, e.g. in your <tt>pom.xml</tt>:
    + * <pre>
    + * ...
    + * &lt;dependencies>
    --- End diff --
    
    If you do the example code as follows, you can use the `<` and make the sample more readable.
    ```
    <pre>{@code
    
    <dependency>
        <groupId>org.apache.hadoop</groupId>
        ...
    </dependency>
    
    }</pre>
    ```


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #3322: [FLINK-4813][flink-test-utils] make the hadoop-minikdc de...

Posted by StephanEwen <gi...@git.apache.org>.
Github user StephanEwen commented on the issue:

    https://github.com/apache/flink/pull/3322
  
    Very good, I had stumbled over that problem as well.
    
    Could you also remove the bundle plugin from the root pom (this should speed up dependency resolutions in IDEs by a lot) and instead add the above described dependency to the test projects that use the `SecureTestEnvironment`?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request #3322: [FLINK-4813][flink-test-utils] make the hadoop-min...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/flink/pull/3322


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #3322: [FLINK-4813][flink-test-utils] make the hadoop-minikdc de...

Posted by NicoK <gi...@git.apache.org>.
Github user NicoK commented on the issue:

    https://github.com/apache/flink/pull/3322
  
    sure, that makes sense
    actually, I only had to add it to the flink-test-utils sub-project since all the others already included the bundler :)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #3322: [FLINK-4813][flink-test-utils] make the hadoop-minikdc de...

Posted by StephanEwen <gi...@git.apache.org>.
Github user StephanEwen commented on the issue:

    https://github.com/apache/flink/pull/3322
  
    The change looks good, thank you!
    Merging this...


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---