[ 
https://issues.apache.org/jira/browse/HDDS-1910?focusedWorklogId=292485&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-292485
 ]

ASF GitHub Bot logged work on HDDS-1910:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 10/Aug/19 08:16
            Start Date: 10/Aug/19 08:16
    Worklog Time Spent: 10m 
      Work Description: adoroszlai commented on pull request #1268: HDDS-1910. 
Cannot build hadoop-hdds-config from scratch in IDEA
URL: https://github.com/apache/hadoop/pull/1268
 
 
   ## What changes were proposed in this pull request?
   
   `ConfigFileGenerator` is both defined (`.java` source) and configured to be 
used (by reference in `META-INF`) in `hadoop-hdds-config` module's `main` 
source.  Maven build is configured to work around this by explicit `-proc:none` 
compiler arg, applied only to `main` compilation, but not to `test` 
compilation.  Since the annotation processor is only used in tests in this 
module, this works fine.
   
   It seems IDEA does not respect this compiler configuration (and cannot even 
be configured differently for `main` and `test` compilation).
   
   This change configures the processor for use in `config/test` and 
`common/main`.  Thus dependent modules still inherit it for main source 
processing, while the `config` module can be properly compiled without the hack.
   
   https://issues.apache.org/jira/browse/HDDS-1910
   
   ## How was this patch tested?
   
   1. Verified that `hadoop-hdds/config` can be compiled from scratch in IDEA.  
To confirm, try to run eg. `TestConfigFileAppender` unit test.
   2. Verified that full Maven build still generates the same Ozone config 
based on existing annotations:
   ```
    1762 hadoop-hdds/common/target/test-classes/ozone-default-generated.xml
    2030 hadoop-hdds/config/target/test-classes/ozone-default-generated.xml
    2294 hadoop-hdds/server-scm/target/classes/ozone-default-generated.xml
     918 hadoop-ozone/common/target/classes/ozone-default-generated.xml
    2298 hadoop-ozone/csi/target/classes/ozone-default-generated.xml
     504 
hadoop-ozone/ozonefs-lib-current/target/classes/ozone-default-generated.xml
     504 
hadoop-ozone/ozonefs-lib-legacy/target/classes/libs/ozone-default-generated.xml
     504 
hadoop-ozone/ozonefs-lib-legacy/target/classes/ozone-default-generated.xml
   ```
 
----------------------------------------------------------------
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:
us...@infra.apache.org


Issue Time Tracking
-------------------

            Worklog Id:     (was: 292485)
            Time Spent: 10m
    Remaining Estimate: 0h

> Cannot build hadoop-hdds-config from scratch in IDEA
> ----------------------------------------------------
>
>                 Key: HDDS-1910
>                 URL: https://issues.apache.org/jira/browse/HDDS-1910
>             Project: Hadoop Distributed Data Store
>          Issue Type: Bug
>          Components: build
>            Reporter: Doroszlai, Attila
>            Assignee: Doroszlai, Attila
>            Priority: Minor
>              Labels: pull-request-available
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Building {{hadoop-hdds-config}} from scratch (eg. right after checkout or 
> after {{mvn clean}}) in IDEA fails with the following error:
> {code}
> Error:java: Bad service configuration file, or exception thrown while 
> constructing Processor object: javax.annotation.processing.Processor: 
> Provider org.apache.hadoop.hdds.conf.ConfigFileGenerator not found
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org

Reply via email to