Hadoop Common
  1. Hadoop Common
  2. HADOOP-7412 Mavenization Umbrella
  3. HADOOP-7502

Use canonical (IDE friendly) generated-sources directory for generated sources

    Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.23.0
    • Component/s: None
    • Labels:
      None
    • Hadoop Flags:
      Reviewed
    1. HADOOP-7502v3.patch
      3 kB
      Alejandro Abdelnur
    2. HADOOP-7502v2.patch
      3 kB
      Alejandro Abdelnur
    3. hadoop-7502-v1.patch
      3 kB
      Luke Lu

      Activity

      Transition Time In Source Status Execution Times Last Executer Last Execution Date
      Open Open Patch Available Patch Available
      3m 52s 1 Luke Lu 03/Aug/11 03:04
      Patch Available Patch Available Resolved Resolved
      15h 11m 1 Luke Lu 03/Aug/11 18:15
      Resolved Resolved Closed Closed
      103d 7h 34m 1 Arun C Murthy 15/Nov/11 00:50
      Arun C Murthy made changes -
      Status Resolved [ 5 ] Closed [ 6 ]
      Alejandro Abdelnur made changes -
      Parent HADOOP-7412 [ 12511125 ]
      Issue Type Improvement [ 4 ] Sub-task [ 7 ]
      Luke Lu made changes -
      Status Patch Available [ 10002 ] Resolved [ 5 ]
      Hadoop Flags [Reviewed]
      Resolution Fixed [ 1 ]
      Hide
      Luke Lu added a comment -

      +1 for v3. Committed to trunk. Thanks Alejandro Abdelnur!

      Show
      Luke Lu added a comment - +1 for v3. Committed to trunk. Thanks Alejandro Abdelnur!
      Alejandro Abdelnur made changes -
      Attachment HADOOP-7502v3.patch [ 12489214 ]
      Hide
      Alejandro Abdelnur added a comment -

      Using (as Luke suggested) generated-test-sources/ dir.

      I've verified it work in IntelliJ and it the source dir is correctly added as a TEST source root.

      Show
      Alejandro Abdelnur added a comment - Using (as Luke suggested) generated-test-sources/ dir. I've verified it work in IntelliJ and it the source dir is correctly added as a TEST source root.
      Hide
      Luke Lu added a comment -

      v2 is better but could be improved to use generated-test-sources for test code.

      Show
      Luke Lu added a comment - v2 is better but could be improved to use generated-test-sources for test code.
      Hide
      Alejandro Abdelnur added a comment -

      Forgot to mention. The rationale for the modified patch is that in IntelliJ the first level under target/generated-sources/ is the mounting point, and from there one the directories are considered Java packages.

      Show
      Alejandro Abdelnur added a comment - Forgot to mention. The rationale for the modified patch is that in IntelliJ the first level under target/generated-sources/ is the mounting point, and from there one the directories are considered Java packages.
      Alejandro Abdelnur made changes -
      Attachment HADOOP-7502v2.patch [ 12489204 ]
      Hide
      Alejandro Abdelnur added a comment -

      Modified version of the patch that uses a single directory level under target/generated-sources/.

      Using one dir for main classes (java) and one dir for test classes (test-java).

      The changes in .gitignore should go in other patch (I'll open a JIRA for it)

      Show
      Alejandro Abdelnur added a comment - Modified version of the patch that uses a single directory level under target/generated-sources/. Using one dir for main classes (java) and one dir for test classes (test-java). The changes in .gitignore should go in other patch (I'll open a JIRA for it)
      Hide
      Tom White added a comment -

      I tried this with Eclipse (using mvn eclipse:eclipse) but unfortunately it still didn't pick up the generated test source tree. I didn't try with m2eclipse though (https://issues.sonatype.org/browse/MNGECLIPSE-2387 might be relevant here).

      Show
      Tom White added a comment - I tried this with Eclipse (using mvn eclipse:eclipse ) but unfortunately it still didn't pick up the generated test source tree. I didn't try with m2eclipse though ( https://issues.sonatype.org/browse/MNGECLIPSE-2387 might be relevant here).
      Luke Lu made changes -
      Status Open [ 1 ] Patch Available [ 10002 ]
      Luke Lu made changes -
      Field Original Value New Value
      Attachment hadoop-7502-v1.patch [ 12489150 ]
      Hide
      Luke Lu added a comment -

      v1 patch works great for NetBeans 7.

      Show
      Luke Lu added a comment - v1 patch works great for NetBeans 7.
      Luke Lu created issue -

        People

        • Assignee:
          Luke Lu
          Reporter:
          Luke Lu
        • Votes:
          0 Vote for this issue
          Watchers:
          0 Start watching this issue

          Dates

          • Created:
            Updated:
            Resolved:

            Development