hadoop-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ajay Kumar <ajay.ku...@hortonworks.com>
Subject Re: Help on test-patch
Date Wed, 06 Sep 2017 18:33:12 GMT
Hi Ping,

I don’t know what OS you are using but it’s easy to install most of those dependencies
using pip or brew.

Ajay

From: Ping Liu <pingpinganan@gmail.com>
Date: Wednesday, September 6, 2017 at 11:28 AM
To: Ajay Kumar <ajay.kumar@hortonworks.com>
Cc: "general@hadoop.apache.org" <general@hadoop.apache.org>
Subject: Re: Help on test-patch

Hi Ajay,
Thank you very much for your message.
Yes, you are right.  Using the same repo is most straight forward.  The advantage to use two
repos is to allow hard reset to the base repo while keeping the development repo as is.  The
patch is created from development repo (delta on top of trunk) and will be applied to base
repo (which need to be hard reset already).  I was able to try it.

Unfortunately, I am not able to run the full process successfully as my environment apparently
lacks some settings such as snappy.  The instruction and online resource are quite vague.
 I don't know what is the correct way to install and configure it.  But this is different
story, of course.
Thanks Ajay!
Ping



On Wed, Sep 6, 2017 at 10:51 AM, Ajay Kumar <ajay.kumar@hortonworks.com<mailto:ajay.kumar@hortonworks.com>>
wrote:
Hi Ping,
I think your assumptions are correct.
I usually test patch with same repo after hard resetting that repo to its latest state. (i.e
./dev-support/bin/test-patch /tmp/1.patch)

Ajay

On 9/2/17, 12:37 AM, "Ping Liu" <pingpinganan@gmail.com<mailto:pingpinganan@gmail.com>>
wrote:

    I have a patch for an Hadoop Jira issue.  I need test the patch.  I am
    following TestingPatchTips at https://wiki.apache.org/hadoop/TestPatchTips.

    I have difficulty in understanding the command option basedir and
    reset-repo.

    The best example is in Recommended Usage, the last part, where both basedir
    and reset-repo are used.

    *Recommended Usage*
    >
    > In general, the easiest way to use test-patch.sh is to use two repos. One
    > repo is used to build patches. The other repo is used to to test them.
    >
    > $ git diff --no-prefix trunk > /tmp/1.patch$ dev-support/bin/test-patch --resetrepo
--run-tests --basedir=/test/repo /tmp/1.patch
    >
    >
    > This will run the freshly built patch against the tests in a fresh repo.
    >

    In above example, my understand is

    1. current location $ is the working repo - it contains changes and is
    where the patch is created from.

    2. dev-support/bin/test-patch is under $, therefore we need get into $ in
    order to run test-patch.

    3. /test/repo is the clean repo from current trunk.

    4. when running test-patch command, patch will be applied to /test/repo.

    Please let me know if my understanding is correct.

    So
       --basedir means the repo where the patch will be applied to and test
    will be performed on?

      --resetrepo means

       1. basedir (/test/repo) but not the current dir $ is allowed to be
       modified?
       2. also modified what?  What kind of modification is it?
       3. BTW, is resetrepo a typo for --reset-repo (missing a hyphen)?

    Any idea is highly appreciated!

    Ping

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