You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@drill.apache.org by Nicolas A Perez <an...@gmail.com> on 2019/05/29 21:38:53 UTC

testing maprdb pluging

I am trying mvn install -Dtests=cluster -Pmapr but the tests does not run.
Any ideas?

At the same time, I am implementing the writing part of the plugin, I have
figured most of the components I need to implement out already. The only
thing that is still a bit obscure is around BatchCreator.

I have created the following class hoping it is loaded automatically
somehow, but I need explanations on how that works in order to effectively
attach this problem.

class TableWriterBatchCreator implements BatchCreator<TableWriter>


On the test side, I need guidance on how to create and run the
corresponding tests for this module.

Best Regards,

Nicolas A Perez
-- 
--------------------------------------------------------------------------------------------
Sent by Nicolas A Perez from my GMAIL account.
--------------------------------------------------------------------------------------------

Re: testing maprdb pluging

Posted by Aman Sinha <am...@gmail.com>.
Regarding the unit tests, for some reason maven requires full package name
for the plugin test suite.
You can do this: (assuming you are running on Linux)
   1. do the clean build
   2. cd contrib/format-maprdb
   3. mvn test -Dtest=com.mapr.drill.maprdb.tests.MaprDBTestsSuite -Pmapr
-DfailIfNoTests=false

On Thu, May 30, 2019 at 2:34 AM Nicolas A Perez <an...@gmail.com>
wrote:

> The other problem I have is that in order to support writing on the
>
> contrib/format-maprdb
>
>
> I need access to
>
> RecordWrite
>
> and it seems I don't have a way to get it inside this project. What should
> I do? Should I structure the code differently?
>
>
> Best Regards,
>
>
> Nicolas A Perez
>
> On Thu, May 30, 2019 at 11:25 AM Nicolas A Perez <an...@gmail.com>
> wrote:
>
> > The tests are located in the
> >
> > drill/contrib/format-maprdb
> >
> >
> > I ran
> >
> >
> > mvn test -Dtest=MaprDBTestsSuite -Pmapr
> >
> >
> > And I got this.
> >
> >
> > -------------------------------------------------------
> >
> > [*INFO*]  T E S T S
> >
> > [*INFO*] -------------------------------------------------------
> >
> > [*INFO*] Running com.mapr.drill.maprdb.tests.*MaprDBTestsSuite*
> >
> > [*ERROR*] *Tests **run: 1*, Failures: 0, *Errors: 1*, Skipped: 0, Time
> > elapsed: 0.003 s* <<< FAILURE!* - in com.mapr.drill.maprdb.tests.
> > *MaprDBTestsSuite*
> >
> > [*ERROR*] com.mapr.drill.maprdb.tests.MaprDBTestsSuite  Time elapsed:
> > 0.002 s  <<< ERROR!
> >
> > java.lang.NoClassDefFoundError:
> org/apache/drill/exec/util/ProtobufPatcher
> >
> > at
> >
> com.mapr.drill.maprdb.tests.MaprDBTestsSuite.setupTests(MaprDBTestsSuite.java:64)
> >
> > Caused by: java.lang.ClassNotFoundException:
> > org.apache.drill.exec.util.ProtobufPatcher
> >
> > at
> >
> com.mapr.drill.maprdb.tests.MaprDBTestsSuite.setupTests(MaprDBTestsSuite.java:64)
> >
> >
> > [*INFO*]
> >
> > [*INFO*] Results:
> >
> > [*INFO*]
> >
> > [*ERROR*] *Errors: *
> >
> > [*ERROR*] *  MaprDBTestsSuite.setupTests:64 » NoClassDefFound
> > org/apache/drill/exec/util/Pr...*
> >
> > [*INFO*]
> >
> > [*ERROR*] *Tests run: 1, Failures: 0, Errors: 1, Skipped: 0*
> >
> >
> > This is the default code, no modifications from Github.
> >
> >
> > Any ideas?
> >
> >
> > Best Regards,
> >
> > On Thu, May 30, 2019 at 2:06 AM Kunal Khatua <ku...@apache.org> wrote:
> >
> >> Hi Nicolas
> >>
> >> Your maven command seems incomplete.
> >>
> >> You need to navigate to the module containing the specific set of tests
> >> (typically, for unit tests in Drill souce, it is the java-exec dir).
> >>
> >> I dont think you need the 'install' phase of the lifecycle, and the
> >> 'test' phase should be sufficient.
> >>
> >> mvn test [-Dtest=<testSuiteName>] -Pmapr
> >>
> >>
> >> There are a number of tests in meach of the modules, so you could take a
> >> look at that to get an idea.
> >> On 5/29/2019 4:28:57 PM, Nicolas A Perez <an...@gmail.com> wrote:
> >> I am trying mvn install -Dtests=cluster -Pmapr but the tests does not
> run.
> >> Any ideas?
> >>
> >> At the same time, I am implementing the writing part of the plugin, I
> have
> >> figured most of the components I need to implement out already. The only
> >> thing that is still a bit obscure is around BatchCreator.
> >>
> >> I have created the following class hoping it is loaded automatically
> >> somehow, but I need explanations on how that works in order to
> effectively
> >> attach this problem.
> >>
> >> class TableWriterBatchCreator implements BatchCreator
> >>
> >>
> >> On the test side, I need guidance on how to create and run the
> >> corresponding tests for this module.
> >>
> >> Best Regards,
> >>
> >> Nicolas A Perez
> >> --
> >>
> >>
> --------------------------------------------------------------------------------------------
> >> Sent by Nicolas A Perez from my GMAIL account.
> >>
> >>
> --------------------------------------------------------------------------------------------
> >>
> >
> >
> > --
> >
> >
> --------------------------------------------------------------------------------------------
> > Sent by Nicolas A Perez from my GMAIL account.
> >
> >
> --------------------------------------------------------------------------------------------
> >
>
>
> --
>
> --------------------------------------------------------------------------------------------
> Sent by Nicolas A Perez from my GMAIL account.
>
> --------------------------------------------------------------------------------------------
>

Re: testing maprdb pluging

Posted by Nicolas A Perez <an...@gmail.com>.
The other problem I have is that in order to support writing on the

contrib/format-maprdb


I need access to

RecordWrite

and it seems I don't have a way to get it inside this project. What should
I do? Should I structure the code differently?


Best Regards,


Nicolas A Perez

On Thu, May 30, 2019 at 11:25 AM Nicolas A Perez <an...@gmail.com>
wrote:

> The tests are located in the
>
> drill/contrib/format-maprdb
>
>
> I ran
>
>
> mvn test -Dtest=MaprDBTestsSuite -Pmapr
>
>
> And I got this.
>
>
> -------------------------------------------------------
>
> [*INFO*]  T E S T S
>
> [*INFO*] -------------------------------------------------------
>
> [*INFO*] Running com.mapr.drill.maprdb.tests.*MaprDBTestsSuite*
>
> [*ERROR*] *Tests **run: 1*, Failures: 0, *Errors: 1*, Skipped: 0, Time
> elapsed: 0.003 s* <<< FAILURE!* - in com.mapr.drill.maprdb.tests.
> *MaprDBTestsSuite*
>
> [*ERROR*] com.mapr.drill.maprdb.tests.MaprDBTestsSuite  Time elapsed:
> 0.002 s  <<< ERROR!
>
> java.lang.NoClassDefFoundError: org/apache/drill/exec/util/ProtobufPatcher
>
> at
> com.mapr.drill.maprdb.tests.MaprDBTestsSuite.setupTests(MaprDBTestsSuite.java:64)
>
> Caused by: java.lang.ClassNotFoundException:
> org.apache.drill.exec.util.ProtobufPatcher
>
> at
> com.mapr.drill.maprdb.tests.MaprDBTestsSuite.setupTests(MaprDBTestsSuite.java:64)
>
>
> [*INFO*]
>
> [*INFO*] Results:
>
> [*INFO*]
>
> [*ERROR*] *Errors: *
>
> [*ERROR*] *  MaprDBTestsSuite.setupTests:64 » NoClassDefFound
> org/apache/drill/exec/util/Pr...*
>
> [*INFO*]
>
> [*ERROR*] *Tests run: 1, Failures: 0, Errors: 1, Skipped: 0*
>
>
> This is the default code, no modifications from Github.
>
>
> Any ideas?
>
>
> Best Regards,
>
> On Thu, May 30, 2019 at 2:06 AM Kunal Khatua <ku...@apache.org> wrote:
>
>> Hi Nicolas
>>
>> Your maven command seems incomplete.
>>
>> You need to navigate to the module containing the specific set of tests
>> (typically, for unit tests in Drill souce, it is the java-exec dir).
>>
>> I dont think you need the 'install' phase of the lifecycle, and the
>> 'test' phase should be sufficient.
>>
>> mvn test [-Dtest=<testSuiteName>] -Pmapr
>>
>>
>> There are a number of tests in meach of the modules, so you could take a
>> look at that to get an idea.
>> On 5/29/2019 4:28:57 PM, Nicolas A Perez <an...@gmail.com> wrote:
>> I am trying mvn install -Dtests=cluster -Pmapr but the tests does not run.
>> Any ideas?
>>
>> At the same time, I am implementing the writing part of the plugin, I have
>> figured most of the components I need to implement out already. The only
>> thing that is still a bit obscure is around BatchCreator.
>>
>> I have created the following class hoping it is loaded automatically
>> somehow, but I need explanations on how that works in order to effectively
>> attach this problem.
>>
>> class TableWriterBatchCreator implements BatchCreator
>>
>>
>> On the test side, I need guidance on how to create and run the
>> corresponding tests for this module.
>>
>> Best Regards,
>>
>> Nicolas A Perez
>> --
>>
>> --------------------------------------------------------------------------------------------
>> Sent by Nicolas A Perez from my GMAIL account.
>>
>> --------------------------------------------------------------------------------------------
>>
>
>
> --
>
> --------------------------------------------------------------------------------------------
> Sent by Nicolas A Perez from my GMAIL account.
>
> --------------------------------------------------------------------------------------------
>


-- 
--------------------------------------------------------------------------------------------
Sent by Nicolas A Perez from my GMAIL account.
--------------------------------------------------------------------------------------------

Re: testing maprdb pluging

Posted by Nicolas A Perez <an...@gmail.com>.
The tests are located in the

drill/contrib/format-maprdb


I ran


mvn test -Dtest=MaprDBTestsSuite -Pmapr


And I got this.


-------------------------------------------------------

[*INFO*]  T E S T S

[*INFO*] -------------------------------------------------------

[*INFO*] Running com.mapr.drill.maprdb.tests.*MaprDBTestsSuite*

[*ERROR*] *Tests **run: 1*, Failures: 0, *Errors: 1*, Skipped: 0, Time
elapsed: 0.003 s* <<< FAILURE!* - in com.mapr.drill.maprdb.tests.
*MaprDBTestsSuite*

[*ERROR*] com.mapr.drill.maprdb.tests.MaprDBTestsSuite  Time elapsed: 0.002
s  <<< ERROR!

java.lang.NoClassDefFoundError: org/apache/drill/exec/util/ProtobufPatcher

at
com.mapr.drill.maprdb.tests.MaprDBTestsSuite.setupTests(MaprDBTestsSuite.java:64)

Caused by: java.lang.ClassNotFoundException:
org.apache.drill.exec.util.ProtobufPatcher

at
com.mapr.drill.maprdb.tests.MaprDBTestsSuite.setupTests(MaprDBTestsSuite.java:64)


[*INFO*]

[*INFO*] Results:

[*INFO*]

[*ERROR*] *Errors: *

[*ERROR*] *  MaprDBTestsSuite.setupTests:64 » NoClassDefFound
org/apache/drill/exec/util/Pr...*

[*INFO*]

[*ERROR*] *Tests run: 1, Failures: 0, Errors: 1, Skipped: 0*


This is the default code, no modifications from Github.


Any ideas?


Best Regards,

On Thu, May 30, 2019 at 2:06 AM Kunal Khatua <ku...@apache.org> wrote:

> Hi Nicolas
>
> Your maven command seems incomplete.
>
> You need to navigate to the module containing the specific set of tests
> (typically, for unit tests in Drill souce, it is the java-exec dir).
>
> I dont think you need the 'install' phase of the lifecycle, and the 'test'
> phase should be sufficient.
>
> mvn test [-Dtest=<testSuiteName>] -Pmapr
>
>
> There are a number of tests in meach of the modules, so you could take a
> look at that to get an idea.
> On 5/29/2019 4:28:57 PM, Nicolas A Perez <an...@gmail.com> wrote:
> I am trying mvn install -Dtests=cluster -Pmapr but the tests does not run.
> Any ideas?
>
> At the same time, I am implementing the writing part of the plugin, I have
> figured most of the components I need to implement out already. The only
> thing that is still a bit obscure is around BatchCreator.
>
> I have created the following class hoping it is loaded automatically
> somehow, but I need explanations on how that works in order to effectively
> attach this problem.
>
> class TableWriterBatchCreator implements BatchCreator
>
>
> On the test side, I need guidance on how to create and run the
> corresponding tests for this module.
>
> Best Regards,
>
> Nicolas A Perez
> --
>
> --------------------------------------------------------------------------------------------
> Sent by Nicolas A Perez from my GMAIL account.
>
> --------------------------------------------------------------------------------------------
>


-- 
--------------------------------------------------------------------------------------------
Sent by Nicolas A Perez from my GMAIL account.
--------------------------------------------------------------------------------------------

Re: testing maprdb pluging

Posted by Kunal Khatua <ku...@apache.org>.
Hi Nicolas

Your maven command seems incomplete. 

You need to navigate to the module containing the specific set of tests (typically, for unit tests in Drill souce, it is the java-exec dir).

I dont think you need the 'install' phase of the lifecycle, and the 'test' phase should be sufficient.

mvn test [-Dtest=<testSuiteName>] -Pmapr 


There are a number of tests in meach of the modules, so you could take a look at that to get an idea. 
On 5/29/2019 4:28:57 PM, Nicolas A Perez <an...@gmail.com> wrote:
I am trying mvn install -Dtests=cluster -Pmapr but the tests does not run.
Any ideas?

At the same time, I am implementing the writing part of the plugin, I have
figured most of the components I need to implement out already. The only
thing that is still a bit obscure is around BatchCreator.

I have created the following class hoping it is loaded automatically
somehow, but I need explanations on how that works in order to effectively
attach this problem.

class TableWriterBatchCreator implements BatchCreator


On the test side, I need guidance on how to create and run the
corresponding tests for this module.

Best Regards,

Nicolas A Perez
--
--------------------------------------------------------------------------------------------
Sent by Nicolas A Perez from my GMAIL account.
--------------------------------------------------------------------------------------------