drill-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Rogers <par0...@yahoo.com.INVALID>
Subject Re: Import drill sources in eclipse
Date Sun, 24 Feb 2019 03:22:18 GMT
Hi Angelo,

Ted's trick is by far the simplest way to get started. The only drawback is the time it takes
to do the build, stop drill, copy the jar, and restart Drill, attach a remote debugger, start
sqlline, and fire off a query.

If you modify code, you may want to shorten your edit/compile/debug cycle by doing your testing
within Eclipse. Turns out this is pretty easy.

As others have said, the first step is to do a full build in Drill outside of Eclipse. This
gets all your generated files built. No need to run tests: mvn install -DskipTests

Now, go into Eclipse, select drill-root in the package explorer and choose Refresh. Eclipse
will notice the generated files and rebuild the project. (I find it handy to put all Drill
projects into a "drill" working set.)

Now, find the unit test you want to run. Drill is quite good about having unit tests for every
feature and module. These are not only great for verifying changes, they are invaluable tools
for debugging those changes.

In the past, it was hard to add unit tests to the "contrib" project. However, thanks to hard
work by a number of people, you should be able to run and debug from contrib also.

Use Debug-->Run as JUnit Test to run it. Voila! you are running Drill and can step through
your changes. If you decide to change something, you are just seconds away from another run.

The above is a quick overview; let us know if you need help on the specifics.

Thanks,
- Paul


 

    On Saturday, February 23, 2019, 3:36:00 AM PST, Angelo Mantellini <amantellini@gmail.com>
wrote:  
 
 Hi, thanks for your help.
I want to know if it is possible to have a fast compilation of the project.
I want to modify only the pcap part and the compiling phase is too long.
Do you have any trick?
Thank you
Angelo

On 21/02/2019, 20:23, "Vitalii Diravka" <vitalii@apache.org> wrote:

    Hi Angelo,
    
    Welcome to Drill community.
    
    Most of Drill devs use Intellij Idea. When I used eclipse for Drill
    project, I haven't this issue.
    But looks like there are several ways how to solve it:
    * You can compile the project externally and the import it into Eclipse.
    * You can fix it in Drill root pom file *org.eclipse.m2e:lifecycle-mapping *[1]
    and to make the first contribution :)
    * You can edit your *Lifecycle Mappings *Eclipse configs [2].
    All above approaches are described in [2].
    
    Thanks
    
    [1] https://github.com/apache/drill/blob/master/pom.xml#L810
    [2]
    https://stackoverflow.com/questions/30642630/artifact-has-not-been-packaged-yet
    
    Kind regards
    Vitalii
    
    
    On Thu, Feb 21, 2019 at 5:40 PM Angelo Mantellini <amantellini@gmail.com>
    wrote:
    
    > Hi,
    > I want to try to partecipate to the development of drill.
    > My problem is that when I try to import the maven project (I select all
    > pom.xml in the drill root dir), I have a list of 440 errors.
    > For example
    > Description    Resource        Path    Location        Type
    > Class<HiveDefaultReader> cannot be resolved to a type
    >  ReadersInitializer.java
    > /drill-storage-hive-core/src/main/java/org/apache/drill/exec/store/hive/readers/initilializers
    > line 80 Java Problem
    >
    > Description    Resource        Path    Location        Type
    > Artifact has not been packaged yet. When used on reactor artifact, unpack
    > should be executed after packaging: see MDEP-98.
    > (org.apache.maven.plugins:maven-dependency-plugin:3.1.1:unpack:unpack-vector-types:initialize)
    >
    > org.apache.maven.plugin.MojoExecutionException: Artifact has not been
    > packaged yet. When used on reactor artifact, unpack should be executed
    > after packaging: see MDEP-98.
    >        at
    > org.apache.maven.plugins.dependency.AbstractDependencyMojo.unpack(AbstractDependencyMojo.java:250)
    >        at
    > org.apache.maven.plugins.dependency.fromConfiguration.UnpackMojo.unpackArtifact(UnpackMojo.java:128)
    >        at
    > org.apache.maven.plugins.dependency.fromConfiguration.UnpackMojo.doExecute(UnpackMojo.java:107)
    >        at
    > org.apache.maven.plugins.dependency.AbstractDependencyMojo.execute(AbstractDependencyMojo.java:143)
    >        at
    > org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:137)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenImpl.execute(MavenImpl.java:331)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenImpl.lambda$7(MavenImpl.java:1342)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:177)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:112)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenImpl.execute(MavenImpl.java:1341)
    >        at
    > org.eclipse.m2e.core.project.configurator.MojoExecutionBuildParticipant.build(MojoExecutionBuildParticipant.java:52)
    >        at
    > com.ianbrandt.tools.m2e.mdp.core.MdpBuildParticipant.executeMojo(MdpBuildParticipant.java:133)
    >        at
    > com.ianbrandt.tools.m2e.mdp.core.MdpBuildParticipant.build(MdpBuildParticipant.java:67)
    >        at
    > org.eclipse.m2e.core.internal.builder.MavenBuilderImpl.build(MavenBuilderImpl.java:137)
    >        at
    > org.eclipse.m2e.core.internal.builder.MavenBuilder$1.method(MavenBuilder.java:173)
    >        at
    > org.eclipse.m2e.core.internal.builder.MavenBuilder$1.method(MavenBuilder.java:1)
    >        at
    > org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod$1$1.call(MavenBuilder.java:116)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:177)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:112)
    >        at
    > org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod$1.call(MavenBuilder.java:106)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:177)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:151)
    >        at
    > org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:99)
    >        at
    > org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.execute(MavenBuilder.java:87)
    >        at
    > org.eclipse.m2e.core.internal.builder.MavenBuilder.build(MavenBuilder.java:201)
    >        at
    > org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:798)
    >        at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
    >        at
    > org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:219)
    >        at
    > org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:262)
    >        at
    > org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:315)
    >        at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
    >        at
    > org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:318)
    >        at
    > org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:370)
    >        at
    > org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:391)
    >        at
    > org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:145)
    >        at
    > org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:235)
    >        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
    >        pom.xml /drill-java-exec        line 691        Maven Build
Problem
    >
    > Could you tell me how I can import this project correctly?
    > Thank you very much
    >
    > Angelo
    >
    >
    >
    >
    >
    

  
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message