Mailing List Archive

A couple backport questions
Hey folks-

I have a couple (hopefully quick) questions about backporting best
practices (from the lucene/main branch to lucene-solr/branch_8x).
Really appreciate the help!

1. A lot of code reformatting has happened on lucene/main (e.g.,
spotlessApply). When pulling over changes into branch_8x for a given
file, is it preferable to pull in the formatting changes as well, or
are we trying to leave the formatting of branch_8x alone as much as
possible? It generally seems easier to pull the formatting changes
over as well, but it can make a PR look more involved than it really
is.

2. In a case where multiple small changes were made to the same area
of code (e.g., a fast-follow update or a bug fix), is it acceptable to
combine those changes into one PR against branch_8x? Or do we want to
maintain a more strict 1:1 relationship between a change on main and
branch_8x? Seems like it would be OK to combine a couple small changes
into a single backport PR, but curious if people feel differently.

Thanks everyone!

Cheers,
-Greg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
Re: A couple backport questions [ In reply to ]
Great questions!

On Fri, Jun 4, 2021 at 1:37 PM Greg Miller <gsmiller@gmail.com> wrote:

> Hey folks-
>
> I have a couple (hopefully quick) questions about backporting best
> practices (from the lucene/main branch to lucene-solr/branch_8x).
> Really appreciate the help!
>
> 1. A lot of code reformatting has happened on lucene/main (e.g.,
> spotlessApply). When pulling over changes into branch_8x for a given
> file, is it preferable to pull in the formatting changes as well, or
> are we trying to leave the formatting of branch_8x alone as much as
> possible? It generally seems easier to pull the formatting changes
> over as well, but it can make a PR look more involved than it really
> is.


I think it is best to match 8.x styling if it is not too much trouble? The
"when in Rome ..." argument. But if that is too much hassle, it's OK to
carry over main's styling?

I love that we have moved to fixed styling for 9.0 onwards (thanks Dawid!).

2. In a case where multiple small changes were made to the same area
> of code (e.g., a fast-follow update or a bug fix), is it acceptable to
> combine those changes into one PR against branch_8x? Or do we want to
> maintain a more strict 1:1 relationship between a change on main and
> branch_8x? Seems like it would be OK to combine a couple small changes
> into a single backport PR, but curious if people feel differently.


I think it's fine to combine small changes into single backport, but try to
reference all of the original issues in the resulting commit message?

Mike
--
Mike McCandless

http://blog.mikemccandless.com
Re: A couple backport questions [ In reply to ]
Thanks Mike!

Matching the original styling seems reasonable to me. Shouldn't be too
difficult (at least for the backports I had in mind). I also really
appreciate the consistent styling enforced (and made easy!) with 9.0!

As for combining a couple small changes, I'll go ahead with this
approach. I think it makes sense in the case I have in mind, but I'll
put the PR out there and see if folks agree/disagree. Will definitely
reference the original issues in the commit message.

If anyone else has feedback (or tips/tricks on their current approach
to backporting), I'm happy to hear them. Thanks!

Cheers,
-Greg

On Sun, Jun 6, 2021 at 7:14 AM Michael McCandless
<lucene@mikemccandless.com> wrote:
>
> Great questions!
>
> On Fri, Jun 4, 2021 at 1:37 PM Greg Miller <gsmiller@gmail.com> wrote:
>>
>> Hey folks-
>>
>> I have a couple (hopefully quick) questions about backporting best
>> practices (from the lucene/main branch to lucene-solr/branch_8x).
>> Really appreciate the help!
>>
>> 1. A lot of code reformatting has happened on lucene/main (e.g.,
>> spotlessApply). When pulling over changes into branch_8x for a given
>> file, is it preferable to pull in the formatting changes as well, or
>> are we trying to leave the formatting of branch_8x alone as much as
>> possible? It generally seems easier to pull the formatting changes
>> over as well, but it can make a PR look more involved than it really
>> is.
>
>
> I think it is best to match 8.x styling if it is not too much trouble? The "when in Rome ..." argument. But if that is too much hassle, it's OK to carry over main's styling?
>
> I love that we have moved to fixed styling for 9.0 onwards (thanks Dawid!).
>
>> 2. In a case where multiple small changes were made to the same area
>> of code (e.g., a fast-follow update or a bug fix), is it acceptable to
>> combine those changes into one PR against branch_8x? Or do we want to
>> maintain a more strict 1:1 relationship between a change on main and
>> branch_8x? Seems like it would be OK to combine a couple small changes
>> into a single backport PR, but curious if people feel differently.
>
>
> I think it's fine to combine small changes into single backport, but try to reference all of the original issues in the resulting commit message?
>
> Mike
> --
> Mike McCandless
>
> http://blog.mikemccandless.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org