All of lore.kernel.org
 help / color / mirror / Atom feed
* Xen project CI systems and committer workflow
@ 2019-04-18 12:31 ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-18 12:31 UTC (permalink / raw)
  To: Xen-devel; +Cc: Juergen Gross, Committers, Wei Liu, Doug Goldstein, Lars Kurth

Hi all

We now have Gitlab CI as a complementary system to Osstest and have planned to
add bots. It's high time we think about how we integrate them and how it may
improve our workflow.

## Requirements

1. We want to have light weight build tests before a patch series is reviewed
or committed.

2. We don't want to push broken patches to central repository such that
everyone is blocked.

3. We don't want to significantly change committer workflow.

Requirement 2 means that our current branching model will need to be changed.
Details will follow.

## Overview of automation systems

- Gitlab CI

    It is capable of running build tests with relatively short turnaround time.

- Bots like Patchew and Patchwork

    They are able to slurp patches from xen-devel and maybe run customised
    scripts on those patches.

- Osstest

    Pushgate, integration test system. It runs more sophisticated tests
    compared to Gitlab CI. Turnaround time is long.
    
## New world

There will be an unified endpoint for committers and bots. Committers and bots
will have their git trees. Patches are committed to those trees. An automated
system will get patches from those trees and trigger CI runs.

The system will pick up commits from one of the trees, merge them with master
and send the merge to CI systems.

For bots, only Gitlab CI build tests will run. Results are sent back to
xen-devel.

For committers' trees, at first Gitlab CI build tests are run, if the result is
successful, the merge commit is submitted to osstest. If osstest deems the
merge is good, the merge is pushed (published) to xen.git, otherwise the merge
is discarded. Test results are sent back to xen-devel.

With this system, all published commits should have already passed Gitlab CI
and osstest tests.

## Gaps

The component / system which merges trees and drives CI systems is missing.

Patchew and Patchwork don't do all the things we care about yet.

## Concerns

For individual committers, turnaround time may become longer since you need to
wait for other trees to be processed.

Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
will be blocked.


Thoughts and comments?

Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 12:31 ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-18 12:31 UTC (permalink / raw)
  To: Xen-devel; +Cc: Juergen Gross, Committers, Wei Liu, Doug Goldstein, Lars Kurth

Hi all

We now have Gitlab CI as a complementary system to Osstest and have planned to
add bots. It's high time we think about how we integrate them and how it may
improve our workflow.

## Requirements

1. We want to have light weight build tests before a patch series is reviewed
or committed.

2. We don't want to push broken patches to central repository such that
everyone is blocked.

3. We don't want to significantly change committer workflow.

Requirement 2 means that our current branching model will need to be changed.
Details will follow.

## Overview of automation systems

- Gitlab CI

    It is capable of running build tests with relatively short turnaround time.

- Bots like Patchew and Patchwork

    They are able to slurp patches from xen-devel and maybe run customised
    scripts on those patches.

- Osstest

    Pushgate, integration test system. It runs more sophisticated tests
    compared to Gitlab CI. Turnaround time is long.
    
## New world

There will be an unified endpoint for committers and bots. Committers and bots
will have their git trees. Patches are committed to those trees. An automated
system will get patches from those trees and trigger CI runs.

The system will pick up commits from one of the trees, merge them with master
and send the merge to CI systems.

For bots, only Gitlab CI build tests will run. Results are sent back to
xen-devel.

For committers' trees, at first Gitlab CI build tests are run, if the result is
successful, the merge commit is submitted to osstest. If osstest deems the
merge is good, the merge is pushed (published) to xen.git, otherwise the merge
is discarded. Test results are sent back to xen-devel.

With this system, all published commits should have already passed Gitlab CI
and osstest tests.

## Gaps

The component / system which merges trees and drives CI systems is missing.

Patchew and Patchwork don't do all the things we care about yet.

## Concerns

For individual committers, turnaround time may become longer since you need to
wait for other trees to be processed.

Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
will be blocked.


Thoughts and comments?

Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 12:32   ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-18 12:32 UTC (permalink / raw)
  To: Xen-devel
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Anthony PERARD

Cc Anthony as well. Forgot to do that. Sorry.

On Thu, Apr 18, 2019 at 01:31:59PM +0100, Wei Liu wrote:
> Hi all
> 
> We now have Gitlab CI as a complementary system to Osstest and have planned to
> add bots. It's high time we think about how we integrate them and how it may
> improve our workflow.
> 
> ## Requirements
> 
> 1. We want to have light weight build tests before a patch series is reviewed
> or committed.
> 
> 2. We don't want to push broken patches to central repository such that
> everyone is blocked.
> 
> 3. We don't want to significantly change committer workflow.
> 
> Requirement 2 means that our current branching model will need to be changed.
> Details will follow.
> 
> ## Overview of automation systems
> 
> - Gitlab CI
> 
>     It is capable of running build tests with relatively short turnaround time.
> 
> - Bots like Patchew and Patchwork
> 
>     They are able to slurp patches from xen-devel and maybe run customised
>     scripts on those patches.
> 
> - Osstest
> 
>     Pushgate, integration test system. It runs more sophisticated tests
>     compared to Gitlab CI. Turnaround time is long.
>     
> ## New world
> 
> There will be an unified endpoint for committers and bots. Committers and bots
> will have their git trees. Patches are committed to those trees. An automated
> system will get patches from those trees and trigger CI runs.
> 
> The system will pick up commits from one of the trees, merge them with master
> and send the merge to CI systems.
> 
> For bots, only Gitlab CI build tests will run. Results are sent back to
> xen-devel.
> 
> For committers' trees, at first Gitlab CI build tests are run, if the result is
> successful, the merge commit is submitted to osstest. If osstest deems the
> merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> is discarded. Test results are sent back to xen-devel.
> 
> With this system, all published commits should have already passed Gitlab CI
> and osstest tests.
> 
> ## Gaps
> 
> The component / system which merges trees and drives CI systems is missing.
> 
> Patchew and Patchwork don't do all the things we care about yet.
> 
> ## Concerns
> 
> For individual committers, turnaround time may become longer since you need to
> wait for other trees to be processed.
> 
> Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
> will be blocked.
> 
> 
> Thoughts and comments?
> 
> Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 12:32   ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-18 12:32 UTC (permalink / raw)
  To: Xen-devel
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Anthony PERARD

Cc Anthony as well. Forgot to do that. Sorry.

On Thu, Apr 18, 2019 at 01:31:59PM +0100, Wei Liu wrote:
> Hi all
> 
> We now have Gitlab CI as a complementary system to Osstest and have planned to
> add bots. It's high time we think about how we integrate them and how it may
> improve our workflow.
> 
> ## Requirements
> 
> 1. We want to have light weight build tests before a patch series is reviewed
> or committed.
> 
> 2. We don't want to push broken patches to central repository such that
> everyone is blocked.
> 
> 3. We don't want to significantly change committer workflow.
> 
> Requirement 2 means that our current branching model will need to be changed.
> Details will follow.
> 
> ## Overview of automation systems
> 
> - Gitlab CI
> 
>     It is capable of running build tests with relatively short turnaround time.
> 
> - Bots like Patchew and Patchwork
> 
>     They are able to slurp patches from xen-devel and maybe run customised
>     scripts on those patches.
> 
> - Osstest
> 
>     Pushgate, integration test system. It runs more sophisticated tests
>     compared to Gitlab CI. Turnaround time is long.
>     
> ## New world
> 
> There will be an unified endpoint for committers and bots. Committers and bots
> will have their git trees. Patches are committed to those trees. An automated
> system will get patches from those trees and trigger CI runs.
> 
> The system will pick up commits from one of the trees, merge them with master
> and send the merge to CI systems.
> 
> For bots, only Gitlab CI build tests will run. Results are sent back to
> xen-devel.
> 
> For committers' trees, at first Gitlab CI build tests are run, if the result is
> successful, the merge commit is submitted to osstest. If osstest deems the
> merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> is discarded. Test results are sent back to xen-devel.
> 
> With this system, all published commits should have already passed Gitlab CI
> and osstest tests.
> 
> ## Gaps
> 
> The component / system which merges trees and drives CI systems is missing.
> 
> Patchew and Patchwork don't do all the things we care about yet.
> 
> ## Concerns
> 
> For individual committers, turnaround time may become longer since you need to
> wait for other trees to be processed.
> 
> Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
> will be blocked.
> 
> 
> Thoughts and comments?
> 
> Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 13:21   ` Ian Jackson
  0 siblings, 0 replies; 32+ messages in thread
From: Ian Jackson @ 2019-04-18 13:21 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Xen-devel, Committers, Doug Goldstein, Lars Kurth

This all sounds good.

Wei Liu writes ("Xen project CI systems and committer workflow"):
> ## Gaps
> 
> The component / system which merges trees and drives CI systems is missing.
> 
> Patchew and Patchwork don't do all the things we care about yet.

We need to decide how the plumbing should be arranged.

> ## Concerns
> 
> For individual committers, turnaround time may become longer since
> you need to wait for other trees to be processed.

This will probably be worth it.

A problem we identified in IRL discussion is that currently we rely
rather too much on osstest retesting the same tree, because of
heisenbugs.  With the new scheme it would spend more of its time
testing things which would never be retested.  So I think in your
`gaps' we need this:

  osstest facility to automatically retry failing tests

(This feels like admitting defeat but I have occasionally had a
campaign of trying to squash heisenbugs and it is *really hard work*.
I doubt we can get rid of them completely.)

> Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
> will be blocked.

Could we plan some kind of procedural or robotic workaround ?

Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 13:21   ` Ian Jackson
  0 siblings, 0 replies; 32+ messages in thread
From: Ian Jackson @ 2019-04-18 13:21 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Xen-devel, Committers, Doug Goldstein, Lars Kurth

This all sounds good.

Wei Liu writes ("Xen project CI systems and committer workflow"):
> ## Gaps
> 
> The component / system which merges trees and drives CI systems is missing.
> 
> Patchew and Patchwork don't do all the things we care about yet.

We need to decide how the plumbing should be arranged.

> ## Concerns
> 
> For individual committers, turnaround time may become longer since
> you need to wait for other trees to be processed.

This will probably be worth it.

A problem we identified in IRL discussion is that currently we rely
rather too much on osstest retesting the same tree, because of
heisenbugs.  With the new scheme it would spend more of its time
testing things which would never be retested.  So I think in your
`gaps' we need this:

  osstest facility to automatically retry failing tests

(This feels like admitting defeat but I have occasionally had a
campaign of trying to squash heisenbugs and it is *really hard work*.
I doubt we can get rid of them completely.)

> Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
> will be blocked.

Could we plan some kind of procedural or robotic workaround ?

Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 13:30     ` Doug Goldstein
  0 siblings, 0 replies; 32+ messages in thread
From: Doug Goldstein @ 2019-04-18 13:30 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Xen-devel, Anthony PERARD, Committers, Lars Kurth

On Thu, Apr 18, 2019 at 01:32:52PM +0100, Wei Liu wrote:
> Cc Anthony as well. Forgot to do that. Sorry.
> 
> On Thu, Apr 18, 2019 at 01:31:59PM +0100, Wei Liu wrote:
> > Hi all
> > 
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.

FWIW, I planned on submitting on a talk on this. I plan on giving an
overview to everyone at the summit and allowing for discussion.
Potentially even hosting a BoF if there is interest in discussing this
further.

--
Doug

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 13:30     ` Doug Goldstein
  0 siblings, 0 replies; 32+ messages in thread
From: Doug Goldstein @ 2019-04-18 13:30 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Xen-devel, Anthony PERARD, Committers, Lars Kurth

On Thu, Apr 18, 2019 at 01:32:52PM +0100, Wei Liu wrote:
> Cc Anthony as well. Forgot to do that. Sorry.
> 
> On Thu, Apr 18, 2019 at 01:31:59PM +0100, Wei Liu wrote:
> > Hi all
> > 
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.

FWIW, I planned on submitting on a talk on this. I plan on giving an
overview to everyone at the summit and allowing for discussion.
Potentially even hosting a BoF if there is interest in discussing this
further.

--
Doug

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 13:36     ` Doug Goldstein
  0 siblings, 0 replies; 32+ messages in thread
From: Doug Goldstein @ 2019-04-18 13:36 UTC (permalink / raw)
  To: Ian Jackson; +Cc: Juergen Gross, Xen-devel, Lars Kurth, Wei Liu, Committers

On Thu, Apr 18, 2019 at 02:21:44PM +0100, Ian Jackson wrote:
> 
> > Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
> > will be blocked.
> 
> Could we plan some kind of procedural or robotic workaround ?

So my thoughts around this are on priority values. Admittedly it could
use some refinement but roughly speaking if someone pushed a series that
broke osstest we could have a fix-up series/patch where it was acked and
it was given a priority weight higher than any other series. This would
cause the GitLab CI loop to test that series and get that pushed above
all others.

Similarly to avoid bogging down testing for small changes like
docs/comments/etc having a "rollup" tag which would have GitLab CI
create a series from all things currently labeled "rollup" as push them
as a whole.

--
Doug

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 13:36     ` Doug Goldstein
  0 siblings, 0 replies; 32+ messages in thread
From: Doug Goldstein @ 2019-04-18 13:36 UTC (permalink / raw)
  To: Ian Jackson; +Cc: Juergen Gross, Xen-devel, Lars Kurth, Wei Liu, Committers

On Thu, Apr 18, 2019 at 02:21:44PM +0100, Ian Jackson wrote:
> 
> > Gitlab CI doesn't have a self pushgate. If it is broken by accident Osstest
> > will be blocked.
> 
> Could we plan some kind of procedural or robotic workaround ?

So my thoughts around this are on priority values. Admittedly it could
use some refinement but roughly speaking if someone pushed a series that
broke osstest we could have a fix-up series/patch where it was acked and
it was given a priority weight higher than any other series. This would
cause the GitLab CI loop to test that series and get that pushed above
all others.

Similarly to avoid bogging down testing for small changes like
docs/comments/etc having a "rollup" tag which would have GitLab CI
create a series from all things currently labeled "rollup" as push them
as a whole.

--
Doug

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 13:59   ` Andrew Cooper
  0 siblings, 0 replies; 32+ messages in thread
From: Andrew Cooper @ 2019-04-18 13:59 UTC (permalink / raw)
  To: Wei Liu, Xen-devel; +Cc: Juergen Gross, Doug Goldstein, Committers, Lars Kurth

On 18/04/2019 13:31, Wei Liu wrote:
> Hi all
>
> We now have Gitlab CI as a complementary system to Osstest and have planned to
> add bots. It's high time we think about how we integrate them and how it may
> improve our workflow.
>
> ## Requirements
>
> 1. We want to have light weight build tests before a patch series is reviewed
> or committed.
>
> 2. We don't want to push broken patches to central repository such that
> everyone is blocked.
>
> 3. We don't want to significantly change committer workflow.
>
> Requirement 2 means that our current branching model will need to be changed.
> Details will follow.

While everything presented here is fine to do as a matter of policy, the
committers still need to retain the ability to actually push directly to
the staging branches on xen.git

The security team needs to be able to make embargoed content appear at
the point of public disclosure.  The security team already takes
responsibility for all testing of this content before the public embargo
point, and this policy will need to continue.

~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 13:59   ` Andrew Cooper
  0 siblings, 0 replies; 32+ messages in thread
From: Andrew Cooper @ 2019-04-18 13:59 UTC (permalink / raw)
  To: Wei Liu, Xen-devel; +Cc: Juergen Gross, Doug Goldstein, Committers, Lars Kurth

On 18/04/2019 13:31, Wei Liu wrote:
> Hi all
>
> We now have Gitlab CI as a complementary system to Osstest and have planned to
> add bots. It's high time we think about how we integrate them and how it may
> improve our workflow.
>
> ## Requirements
>
> 1. We want to have light weight build tests before a patch series is reviewed
> or committed.
>
> 2. We don't want to push broken patches to central repository such that
> everyone is blocked.
>
> 3. We don't want to significantly change committer workflow.
>
> Requirement 2 means that our current branching model will need to be changed.
> Details will follow.

While everything presented here is fine to do as a matter of policy, the
committers still need to retain the ability to actually push directly to
the staging branches on xen.git

The security team needs to be able to make embargoed content appear at
the point of public disclosure.  The security team already takes
responsibility for all testing of this content before the public embargo
point, and this policy will need to continue.

~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 14:02     ` Ian Jackson
  0 siblings, 0 replies; 32+ messages in thread
From: Ian Jackson @ 2019-04-18 14:02 UTC (permalink / raw)
  To: Andrew Cooper
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Xen-devel

Andrew Cooper writes ("Re: Xen project CI systems and committer workflow"):
> While everything presented here is fine to do as a matter of policy, the
> committers still need to retain the ability to actually push directly to
> the staging branches on xen.git

Why ?

In particular, this seems to presuppose that these "staging" branches
continue to exist.

One of our strange practices is that we push things to a non-rewinding
branch before they have been tested.  Now, OK, we have been doing that
for over a decade - since before people really invented the modern
concept of "CI" - but that doesn't make it sensible.

Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 14:02     ` Ian Jackson
  0 siblings, 0 replies; 32+ messages in thread
From: Ian Jackson @ 2019-04-18 14:02 UTC (permalink / raw)
  To: Andrew Cooper
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Xen-devel

Andrew Cooper writes ("Re: Xen project CI systems and committer workflow"):
> While everything presented here is fine to do as a matter of policy, the
> committers still need to retain the ability to actually push directly to
> the staging branches on xen.git

Why ?

In particular, this seems to presuppose that these "staging" branches
continue to exist.

One of our strange practices is that we push things to a non-rewinding
branch before they have been tested.  Now, OK, we have been doing that
for over a decade - since before people really invented the modern
concept of "CI" - but that doesn't make it sensible.

Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 17:54   ` Stefano Stabellini
  0 siblings, 0 replies; 32+ messages in thread
From: Stefano Stabellini @ 2019-04-18 17:54 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Xen-devel, Committers, Doug Goldstein, Lars Kurth

On Thu, 18 Apr 2019, Wei Liu wrote:
> Hi all
> 
> We now have Gitlab CI as a complementary system to Osstest and have planned to
> add bots. It's high time we think about how we integrate them and how it may
> improve our workflow.
> 
> ## Requirements
> 
> 1. We want to have light weight build tests before a patch series is reviewed
> or committed.
> 
> 2. We don't want to push broken patches to central repository such that
> everyone is blocked.
> 
> 3. We don't want to significantly change committer workflow.
> 
> Requirement 2 means that our current branching model will need to be changed.
> Details will follow.
> 
> ## Overview of automation systems
> 
> - Gitlab CI
> 
>     It is capable of running build tests with relatively short turnaround time.
> 
> - Bots like Patchew and Patchwork
> 
>     They are able to slurp patches from xen-devel and maybe run customised
>     scripts on those patches.
> 
> - Osstest
> 
>     Pushgate, integration test system. It runs more sophisticated tests
>     compared to Gitlab CI. Turnaround time is long.
>     
> ## New world
> 
> There will be an unified endpoint for committers and bots. Committers and bots
> will have their git trees. Patches are committed to those trees. An automated
> system will get patches from those trees and trigger CI runs.
> 
> The system will pick up commits from one of the trees, merge them with master
> and send the merge to CI systems.
> 
> For bots, only Gitlab CI build tests will run. Results are sent back to
> xen-devel.
> 
> For committers' trees, at first Gitlab CI build tests are run, if the result is
> successful, the merge commit is submitted to osstest. If osstest deems the
> merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> is discarded. Test results are sent back to xen-devel.
> 
> With this system, all published commits should have already passed Gitlab CI
> and osstest tests.
> 
> ## Gaps
> 
> The component / system which merges trees and drives CI systems is missing.
> 
> Patchew and Patchwork don't do all the things we care about yet.

I understand the general principle and I am on board. But I missing some
details.

Is the idea that each committer would have his own git tree and branch
with a specific name which would be picked up automatically by the
CI-loop daily? In the style of linux-next? If it passed, it is given to
OSSTest automatically and eventually committed?

Or is it the idea that each committer would have a way to manually
submit a branch to the CI-loop for testing when he wished to do so?  In
the style of github pull-requests-based CI-loops? If this is the case,
then we just need a way to trigger the CI-loops on a given branch?

In any case, my only feedback would be to also allow CI-loops on
branches that are *not* meant to be committed automatically if tests
pass. So that we can apply a complex series to a branch and see if tests
pass before doing reviews or running experiments.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 17:54   ` Stefano Stabellini
  0 siblings, 0 replies; 32+ messages in thread
From: Stefano Stabellini @ 2019-04-18 17:54 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Xen-devel, Committers, Doug Goldstein, Lars Kurth

On Thu, 18 Apr 2019, Wei Liu wrote:
> Hi all
> 
> We now have Gitlab CI as a complementary system to Osstest and have planned to
> add bots. It's high time we think about how we integrate them and how it may
> improve our workflow.
> 
> ## Requirements
> 
> 1. We want to have light weight build tests before a patch series is reviewed
> or committed.
> 
> 2. We don't want to push broken patches to central repository such that
> everyone is blocked.
> 
> 3. We don't want to significantly change committer workflow.
> 
> Requirement 2 means that our current branching model will need to be changed.
> Details will follow.
> 
> ## Overview of automation systems
> 
> - Gitlab CI
> 
>     It is capable of running build tests with relatively short turnaround time.
> 
> - Bots like Patchew and Patchwork
> 
>     They are able to slurp patches from xen-devel and maybe run customised
>     scripts on those patches.
> 
> - Osstest
> 
>     Pushgate, integration test system. It runs more sophisticated tests
>     compared to Gitlab CI. Turnaround time is long.
>     
> ## New world
> 
> There will be an unified endpoint for committers and bots. Committers and bots
> will have their git trees. Patches are committed to those trees. An automated
> system will get patches from those trees and trigger CI runs.
> 
> The system will pick up commits from one of the trees, merge them with master
> and send the merge to CI systems.
> 
> For bots, only Gitlab CI build tests will run. Results are sent back to
> xen-devel.
> 
> For committers' trees, at first Gitlab CI build tests are run, if the result is
> successful, the merge commit is submitted to osstest. If osstest deems the
> merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> is discarded. Test results are sent back to xen-devel.
> 
> With this system, all published commits should have already passed Gitlab CI
> and osstest tests.
> 
> ## Gaps
> 
> The component / system which merges trees and drives CI systems is missing.
> 
> Patchew and Patchwork don't do all the things we care about yet.

I understand the general principle and I am on board. But I missing some
details.

Is the idea that each committer would have his own git tree and branch
with a specific name which would be picked up automatically by the
CI-loop daily? In the style of linux-next? If it passed, it is given to
OSSTest automatically and eventually committed?

Or is it the idea that each committer would have a way to manually
submit a branch to the CI-loop for testing when he wished to do so?  In
the style of github pull-requests-based CI-loops? If this is the case,
then we just need a way to trigger the CI-loops on a given branch?

In any case, my only feedback would be to also allow CI-loops on
branches that are *not* meant to be committed automatically if tests
pass. So that we can apply a complex series to a branch and see if tests
pass before doing reviews or running experiments.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-18 21:33     ` Doug Goldstein
  0 siblings, 0 replies; 32+ messages in thread
From: Doug Goldstein @ 2019-04-18 21:33 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Juergen Gross, Xen-devel, Lars Kurth, Wei Liu, Committers

On Thu, Apr 18, 2019 at 02:59:17PM +0100, Andrew Cooper wrote:
> On 18/04/2019 13:31, Wei Liu wrote:
> > Hi all
> >
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.
> >
> > ## Requirements
> >
> > 1. We want to have light weight build tests before a patch series is reviewed
> > or committed.
> >
> > 2. We don't want to push broken patches to central repository such that
> > everyone is blocked.
> >
> > 3. We don't want to significantly change committer workflow.
> >
> > Requirement 2 means that our current branching model will need to be changed.
> > Details will follow.
> 
> While everything presented here is fine to do as a matter of policy, the
> committers still need to retain the ability to actually push directly to
> the staging branches on xen.git
> 
> The security team needs to be able to make embargoed content appear at
> the point of public disclosure.  The security team already takes
> responsibility for all testing of this content before the public embargo
> point, and this policy will need to continue.
> 
> ~Andrew

What about the ability to push a branch to the CI loop with the highest
priority so that its picked up immediately? There has been more than one
XSA where the patches provided in the emails don't apply cleanly or
don't build so it does seem valuable to still run the CI loop.

--
Doug

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-18 21:33     ` Doug Goldstein
  0 siblings, 0 replies; 32+ messages in thread
From: Doug Goldstein @ 2019-04-18 21:33 UTC (permalink / raw)
  To: Andrew Cooper; +Cc: Juergen Gross, Xen-devel, Lars Kurth, Wei Liu, Committers

On Thu, Apr 18, 2019 at 02:59:17PM +0100, Andrew Cooper wrote:
> On 18/04/2019 13:31, Wei Liu wrote:
> > Hi all
> >
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.
> >
> > ## Requirements
> >
> > 1. We want to have light weight build tests before a patch series is reviewed
> > or committed.
> >
> > 2. We don't want to push broken patches to central repository such that
> > everyone is blocked.
> >
> > 3. We don't want to significantly change committer workflow.
> >
> > Requirement 2 means that our current branching model will need to be changed.
> > Details will follow.
> 
> While everything presented here is fine to do as a matter of policy, the
> committers still need to retain the ability to actually push directly to
> the staging branches on xen.git
> 
> The security team needs to be able to make embargoed content appear at
> the point of public disclosure.  The security team already takes
> responsibility for all testing of this content before the public embargo
> point, and this policy will need to continue.
> 
> ~Andrew

What about the ability to push a branch to the CI loop with the highest
priority so that its picked up immediately? There has been more than one
XSA where the patches provided in the emails don't apply cleanly or
don't build so it does seem valuable to still run the CI loop.

--
Doug

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-23  9:12     ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-23  9:12 UTC (permalink / raw)
  To: Andrew Cooper
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Xen-devel

On Thu, Apr 18, 2019 at 02:59:17PM +0100, Andrew Cooper wrote:
> On 18/04/2019 13:31, Wei Liu wrote:
> > Hi all
> >
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.
> >
> > ## Requirements
> >
> > 1. We want to have light weight build tests before a patch series is reviewed
> > or committed.
> >
> > 2. We don't want to push broken patches to central repository such that
> > everyone is blocked.
> >
> > 3. We don't want to significantly change committer workflow.
> >
> > Requirement 2 means that our current branching model will need to be changed.
> > Details will follow.
> 
> While everything presented here is fine to do as a matter of policy, the
> committers still need to retain the ability to actually push directly to
> the staging branches on xen.git
> 

But that would mean skipping all tests? I don't think that's desirable.

> The security team needs to be able to make embargoed content appear at
> the point of public disclosure.  The security team already takes
> responsibility for all testing of this content before the public embargo
> point, and this policy will need to continue.

I think as long as the system provides the capability to 1) run flights
in secret and 2) expedite certain flights, enforcing this policy even on
security team should be fine.

#1 makes sure security patches can be tested before they are published.
#2 makes sure once they are published, they will be tested at the
highest priority.

Wei.

> 
> ~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-23  9:12     ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-23  9:12 UTC (permalink / raw)
  To: Andrew Cooper
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Xen-devel

On Thu, Apr 18, 2019 at 02:59:17PM +0100, Andrew Cooper wrote:
> On 18/04/2019 13:31, Wei Liu wrote:
> > Hi all
> >
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.
> >
> > ## Requirements
> >
> > 1. We want to have light weight build tests before a patch series is reviewed
> > or committed.
> >
> > 2. We don't want to push broken patches to central repository such that
> > everyone is blocked.
> >
> > 3. We don't want to significantly change committer workflow.
> >
> > Requirement 2 means that our current branching model will need to be changed.
> > Details will follow.
> 
> While everything presented here is fine to do as a matter of policy, the
> committers still need to retain the ability to actually push directly to
> the staging branches on xen.git
> 

But that would mean skipping all tests? I don't think that's desirable.

> The security team needs to be able to make embargoed content appear at
> the point of public disclosure.  The security team already takes
> responsibility for all testing of this content before the public embargo
> point, and this policy will need to continue.

I think as long as the system provides the capability to 1) run flights
in secret and 2) expedite certain flights, enforcing this policy even on
security team should be fine.

#1 makes sure security patches can be tested before they are published.
#2 makes sure once they are published, they will be tested at the
highest priority.

Wei.

> 
> ~Andrew

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-25 12:33   ` Jan Beulich
  0 siblings, 0 replies; 32+ messages in thread
From: Jan Beulich @ 2019-04-25 12:33 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Lars Kurth, committers, Doug Goldstein, xen-devel

>>> On 18.04.19 at 14:31, <wei.liu2@citrix.com> wrote:
> ## New world
> 
> There will be an unified endpoint for committers and bots. Committers and bots
> will have their git trees. Patches are committed to those trees. An automated
> system will get patches from those trees and trigger CI runs.
> 
> The system will pick up commits from one of the trees, merge them with master
> and send the merge to CI systems.
> 
> For bots, only Gitlab CI build tests will run. Results are sent back to
> xen-devel.

This and ...

> For committers' trees, at first Gitlab CI build tests are run, if the result is
> successful, the merge commit is submitted to osstest. If osstest deems the
> merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> is discarded. Test results are sent back to xen-devel.

... this sounds like a lot of extra mail traffic. Already for the osstest
reports I wonder how many people actually look at them (at a
minimum level of detail). The more relatively similar mails, the more
likely it is in my opinion that some relevant one may not be paid
attention to.

> With this system, all published commits should have already passed Gitlab CI
> and osstest tests.

While this is certainly desirable as a goal, is the problem of
occasional build issues really this big, warranting introduction
of further overhead?

> ## Concerns
> 
> For individual committers, turnaround time may become longer since you need to
> wait for other trees to be processed.

Together with this larger latency, chances increase that two
committers pick up the same patch or series. With today's
single central instance everyone pushes to it is at least
possible to check whether something has gone in already
before starting to commit things. Iirc whenever I ended up
trying to commit a patch that was already there, it was
because of me not having checked (again), rather than
because of an actual race.

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-25 12:33   ` Jan Beulich
  0 siblings, 0 replies; 32+ messages in thread
From: Jan Beulich @ 2019-04-25 12:33 UTC (permalink / raw)
  To: Wei Liu; +Cc: Juergen Gross, Lars Kurth, committers, Doug Goldstein, xen-devel

>>> On 18.04.19 at 14:31, <wei.liu2@citrix.com> wrote:
> ## New world
> 
> There will be an unified endpoint for committers and bots. Committers and bots
> will have their git trees. Patches are committed to those trees. An automated
> system will get patches from those trees and trigger CI runs.
> 
> The system will pick up commits from one of the trees, merge them with master
> and send the merge to CI systems.
> 
> For bots, only Gitlab CI build tests will run. Results are sent back to
> xen-devel.

This and ...

> For committers' trees, at first Gitlab CI build tests are run, if the result is
> successful, the merge commit is submitted to osstest. If osstest deems the
> merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> is discarded. Test results are sent back to xen-devel.

... this sounds like a lot of extra mail traffic. Already for the osstest
reports I wonder how many people actually look at them (at a
minimum level of detail). The more relatively similar mails, the more
likely it is in my opinion that some relevant one may not be paid
attention to.

> With this system, all published commits should have already passed Gitlab CI
> and osstest tests.

While this is certainly desirable as a goal, is the problem of
occasional build issues really this big, warranting introduction
of further overhead?

> ## Concerns
> 
> For individual committers, turnaround time may become longer since you need to
> wait for other trees to be processed.

Together with this larger latency, chances increase that two
committers pick up the same patch or series. With today's
single central instance everyone pushes to it is at least
possible to check whether something has gone in already
before starting to commit things. Iirc whenever I ended up
trying to commit a patch that was already there, it was
because of me not having checked (again), rather than
because of an actual race.

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-25 12:37       ` Jan Beulich
  0 siblings, 0 replies; 32+ messages in thread
From: Jan Beulich @ 2019-04-25 12:37 UTC (permalink / raw)
  To: Ian Jackson
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Andrew Cooper, Doug Goldstein,
	committers, xen-devel

>>> On 18.04.19 at 16:02, <ian.jackson@citrix.com> wrote:
> Andrew Cooper writes ("Re: Xen project CI systems and committer workflow"):
>> While everything presented here is fine to do as a matter of policy, the
>> committers still need to retain the ability to actually push directly to
>> the staging branches on xen.git
> 
> Why ?
> 
> In particular, this seems to presuppose that these "staging" branches
> continue to exist.
> 
> One of our strange practices is that we push things to a non-rewinding
> branch before they have been tested.  Now, OK, we have been doing that
> for over a decade - since before people really invented the modern
> concept of "CI" - but that doesn't make it sensible.

Now the question of course is - why do you consider this practice
"strange"? And what do you mean by "before they have been
tested"? Any submitter should have tested their patches. Yes, not
everyone tests all possible (basic) configurations, but we spot
such issues in review more often than they slip through, I think.
And I don't expect CI will come anywhere near testing all
_possible_ configurations, i.e. the risk of subtle breakage won't
get eliminated altogether anyway.

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-25 12:37       ` Jan Beulich
  0 siblings, 0 replies; 32+ messages in thread
From: Jan Beulich @ 2019-04-25 12:37 UTC (permalink / raw)
  To: Ian Jackson
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Andrew Cooper, Doug Goldstein,
	committers, xen-devel

>>> On 18.04.19 at 16:02, <ian.jackson@citrix.com> wrote:
> Andrew Cooper writes ("Re: Xen project CI systems and committer workflow"):
>> While everything presented here is fine to do as a matter of policy, the
>> committers still need to retain the ability to actually push directly to
>> the staging branches on xen.git
> 
> Why ?
> 
> In particular, this seems to presuppose that these "staging" branches
> continue to exist.
> 
> One of our strange practices is that we push things to a non-rewinding
> branch before they have been tested.  Now, OK, we have been doing that
> for over a decade - since before people really invented the modern
> concept of "CI" - but that doesn't make it sensible.

Now the question of course is - why do you consider this practice
"strange"? And what do you mean by "before they have been
tested"? Any submitter should have tested their patches. Yes, not
everyone tests all possible (basic) configurations, but we spot
such issues in review more often than they slip through, I think.
And I don't expect CI will come anywhere near testing all
_possible_ configurations, i.e. the risk of subtle breakage won't
get eliminated altogether anyway.

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-25 12:53         ` Julien Grall
  0 siblings, 0 replies; 32+ messages in thread
From: Julien Grall @ 2019-04-25 12:53 UTC (permalink / raw)
  To: Jan Beulich, Ian Jackson
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Andrew Cooper, Doug Goldstein,
	committers, xen-devel

Hi Jan,

On 25/04/2019 13:37, Jan Beulich wrote:
>>>> On 18.04.19 at 16:02, <ian.jackson@citrix.com> wrote:
>> Andrew Cooper writes ("Re: Xen project CI systems and committer workflow"):
>>> While everything presented here is fine to do as a matter of policy, the
>>> committers still need to retain the ability to actually push directly to
>>> the staging branches on xen.git
>>
>> Why ?
>>
>> In particular, this seems to presuppose that these "staging" branches
>> continue to exist.
>>
>> One of our strange practices is that we push things to a non-rewinding
>> branch before they have been tested.  Now, OK, we have been doing that
>> for over a decade - since before people really invented the modern
>> concept of "CI" - but that doesn't make it sensible.
> 
> Now the question of course is - why do you consider this practice
> "strange"? And what do you mean by "before they have been
> tested"? Any submitter should have tested their patches. Yes, not
> everyone tests all possible (basic) configurations, but we spot
> such issues in review more often than they slip through, I think.

It is fairly common to see breakage on Arm because changes was only compiled on 
x86. The most common argument is "I don't have setup to build Arm".

The CI would allow us to test on every arch, different variation of .config (and 
possibly compiler).

> And I don't expect CI will come anywhere near testing all
> _possible_ configurations, i.e. the risk of subtle breakage won't
> get eliminated altogether anyway.

Nothing is fully bullet-proof, but this is an improvement over manual testing on 
most of the build configuration today. The CI actually proved the usefulness by 
catching build bug in random .config the last few months.

Cheers,

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-25 12:53         ` Julien Grall
  0 siblings, 0 replies; 32+ messages in thread
From: Julien Grall @ 2019-04-25 12:53 UTC (permalink / raw)
  To: Jan Beulich, Ian Jackson
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Andrew Cooper, Doug Goldstein,
	committers, xen-devel

Hi Jan,

On 25/04/2019 13:37, Jan Beulich wrote:
>>>> On 18.04.19 at 16:02, <ian.jackson@citrix.com> wrote:
>> Andrew Cooper writes ("Re: Xen project CI systems and committer workflow"):
>>> While everything presented here is fine to do as a matter of policy, the
>>> committers still need to retain the ability to actually push directly to
>>> the staging branches on xen.git
>>
>> Why ?
>>
>> In particular, this seems to presuppose that these "staging" branches
>> continue to exist.
>>
>> One of our strange practices is that we push things to a non-rewinding
>> branch before they have been tested.  Now, OK, we have been doing that
>> for over a decade - since before people really invented the modern
>> concept of "CI" - but that doesn't make it sensible.
> 
> Now the question of course is - why do you consider this practice
> "strange"? And what do you mean by "before they have been
> tested"? Any submitter should have tested their patches. Yes, not
> everyone tests all possible (basic) configurations, but we spot
> such issues in review more often than they slip through, I think.

It is fairly common to see breakage on Arm because changes was only compiled on 
x86. The most common argument is "I don't have setup to build Arm".

The CI would allow us to test on every arch, different variation of .config (and 
possibly compiler).

> And I don't expect CI will come anywhere near testing all
> _possible_ configurations, i.e. the risk of subtle breakage won't
> get eliminated altogether anyway.

Nothing is fully bullet-proof, but this is an improvement over manual testing on 
most of the build configuration today. The CI actually proved the usefulness by 
catching build bug in random .config the last few months.

Cheers,

-- 
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-25 13:01           ` George Dunlap
  0 siblings, 0 replies; 32+ messages in thread
From: George Dunlap @ 2019-04-25 13:01 UTC (permalink / raw)
  To: Julien Grall, Jan Beulich, Ian Jackson
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Andrew Cooper, Doug Goldstein,
	committers, xen-devel

On 4/25/19 1:53 PM, Julien Grall wrote:
> Hi Jan,
> 
> On 25/04/2019 13:37, Jan Beulich wrote:
>>>>> On 18.04.19 at 16:02, <ian.jackson@citrix.com> wrote:
>>> Andrew Cooper writes ("Re: Xen project CI systems and committer
>>> workflow"):
>>>> While everything presented here is fine to do as a matter of policy,
>>>> the
>>>> committers still need to retain the ability to actually push
>>>> directly to
>>>> the staging branches on xen.git
>>>
>>> Why ?
>>>
>>> In particular, this seems to presuppose that these "staging" branches
>>> continue to exist.
>>>
>>> One of our strange practices is that we push things to a non-rewinding
>>> branch before they have been tested.  Now, OK, we have been doing that
>>> for over a decade - since before people really invented the modern
>>> concept of "CI" - but that doesn't make it sensible.
>>
>> Now the question of course is - why do you consider this practice
>> "strange"? And what do you mean by "before they have been
>> tested"? Any submitter should have tested their patches. Yes, not
>> everyone tests all possible (basic) configurations, but we spot
>> such issues in review more often than they slip through, I think.
> 
> It is fairly common to see breakage on Arm because changes was only
> compiled on x86. The most common argument is "I don't have setup to
> build Arm".
> 
> The CI would allow us to test on every arch, different variation of
> .config (and possibly compiler).
> 
>> And I don't expect CI will come anywhere near testing all
>> _possible_ configurations, i.e. the risk of subtle breakage won't
>> get eliminated altogether anyway.
> 
> Nothing is fully bullet-proof, but this is an improvement over manual
> testing on most of the build configuration today. The CI actually proved
> the usefulness by catching build bug in random .config the last few months.

Furthermore, the long-term goal is to extend the boundary of things that
we test, such that what gets tested is far wider than it would even be
practical for submitters to test.  (This was partially the goal of the
SUPPORT.md, to have a place to enumerate testing status; and also
partially the goal of the osstest stretch upgrade, to enable osstest to
provide gcov reports to highlight testing deficiencies.)

Computers are good at boring, repetitive tasks like extensive testing;
humans are bad at it.  There's no reason to make humans do work that a
computer can do better.

 -George

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-25 13:01           ` George Dunlap
  0 siblings, 0 replies; 32+ messages in thread
From: George Dunlap @ 2019-04-25 13:01 UTC (permalink / raw)
  To: Julien Grall, Jan Beulich, Ian Jackson
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Andrew Cooper, Doug Goldstein,
	committers, xen-devel

On 4/25/19 1:53 PM, Julien Grall wrote:
> Hi Jan,
> 
> On 25/04/2019 13:37, Jan Beulich wrote:
>>>>> On 18.04.19 at 16:02, <ian.jackson@citrix.com> wrote:
>>> Andrew Cooper writes ("Re: Xen project CI systems and committer
>>> workflow"):
>>>> While everything presented here is fine to do as a matter of policy,
>>>> the
>>>> committers still need to retain the ability to actually push
>>>> directly to
>>>> the staging branches on xen.git
>>>
>>> Why ?
>>>
>>> In particular, this seems to presuppose that these "staging" branches
>>> continue to exist.
>>>
>>> One of our strange practices is that we push things to a non-rewinding
>>> branch before they have been tested.  Now, OK, we have been doing that
>>> for over a decade - since before people really invented the modern
>>> concept of "CI" - but that doesn't make it sensible.
>>
>> Now the question of course is - why do you consider this practice
>> "strange"? And what do you mean by "before they have been
>> tested"? Any submitter should have tested their patches. Yes, not
>> everyone tests all possible (basic) configurations, but we spot
>> such issues in review more often than they slip through, I think.
> 
> It is fairly common to see breakage on Arm because changes was only
> compiled on x86. The most common argument is "I don't have setup to
> build Arm".
> 
> The CI would allow us to test on every arch, different variation of
> .config (and possibly compiler).
> 
>> And I don't expect CI will come anywhere near testing all
>> _possible_ configurations, i.e. the risk of subtle breakage won't
>> get eliminated altogether anyway.
> 
> Nothing is fully bullet-proof, but this is an improvement over manual
> testing on most of the build configuration today. The CI actually proved
> the usefulness by catching build bug in random .config the last few months.

Furthermore, the long-term goal is to extend the boundary of things that
we test, such that what gets tested is far wider than it would even be
practical for submitters to test.  (This was partially the goal of the
SUPPORT.md, to have a place to enumerate testing status; and also
partially the goal of the osstest stretch upgrade, to enable osstest to
provide gcov reports to highlight testing deficiencies.)

Computers are good at boring, repetitive tasks like extensive testing;
humans are bad at it.  There's no reason to make humans do work that a
computer can do better.

 -George

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-25 14:51     ` George Dunlap
  0 siblings, 0 replies; 32+ messages in thread
From: George Dunlap @ 2019-04-25 14:51 UTC (permalink / raw)
  To: Jan Beulich, Wei Liu
  Cc: Juergen Gross, Lars Kurth, committers, Doug Goldstein, xen-devel

On 4/25/19 1:33 PM, Jan Beulich wrote:
>> With this system, all published commits should have already passed Gitlab CI
>> and osstest tests.
> 
> While this is certainly desirable as a goal, is the problem of
> occasional build issues really this big, warranting introduction
> of further overhead?

You seem to have missed the conjuction at the end of the sentence you're
relpying to:

"...and osstest tests".

It's not mainly to stop occasional build issues; it's to stop
long-running pushgate failures.

>> ## Concerns
>>
>> For individual committers, turnaround time may become longer since you need to
>> wait for other trees to be processed.
> 
> Together with this larger latency, chances increase that two
> committers pick up the same patch or series. With today's
> single central instance everyone pushes to it is at least
> possible to check whether something has gone in already
> before starting to commit things. Iirc whenever I ended up
> trying to commit a patch that was already there, it was
> because of me not having checked (again), rather than
> because of an actual race.

If this becomes an issue, I'm sure we can sort out a technical solution.
 A pre-push script that checks other "open" submissions for duplicates
shouldn't be difficult to implement.   Having a unified place for
committers to simply approve posts for merging (rather than submitting a
pull request) would be a longer-term improvement.

 -George

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-25 14:51     ` George Dunlap
  0 siblings, 0 replies; 32+ messages in thread
From: George Dunlap @ 2019-04-25 14:51 UTC (permalink / raw)
  To: Jan Beulich, Wei Liu
  Cc: Juergen Gross, Lars Kurth, committers, Doug Goldstein, xen-devel

On 4/25/19 1:33 PM, Jan Beulich wrote:
>> With this system, all published commits should have already passed Gitlab CI
>> and osstest tests.
> 
> While this is certainly desirable as a goal, is the problem of
> occasional build issues really this big, warranting introduction
> of further overhead?

You seem to have missed the conjuction at the end of the sentence you're
relpying to:

"...and osstest tests".

It's not mainly to stop occasional build issues; it's to stop
long-running pushgate failures.

>> ## Concerns
>>
>> For individual committers, turnaround time may become longer since you need to
>> wait for other trees to be processed.
> 
> Together with this larger latency, chances increase that two
> committers pick up the same patch or series. With today's
> single central instance everyone pushes to it is at least
> possible to check whether something has gone in already
> before starting to commit things. Iirc whenever I ended up
> trying to commit a patch that was already there, it was
> because of me not having checked (again), rather than
> because of an actual race.

If this becomes an issue, I'm sure we can sort out a technical solution.
 A pre-push script that checks other "open" submissions for duplicates
shouldn't be difficult to implement.   Having a unified place for
committers to simply approve posts for merging (rather than submitting a
pull request) would be a longer-term improvement.

 -George

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: Xen project CI systems and committer workflow
@ 2019-04-30 10:07     ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-30 10:07 UTC (permalink / raw)
  To: Stefano Stabellini
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Xen-devel

On Thu, Apr 18, 2019 at 10:54:05AM -0700, Stefano Stabellini wrote:
> On Thu, 18 Apr 2019, Wei Liu wrote:
> > Hi all
> > 
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.
> > 
> > ## Requirements
> > 
> > 1. We want to have light weight build tests before a patch series is reviewed
> > or committed.
> > 
> > 2. We don't want to push broken patches to central repository such that
> > everyone is blocked.
> > 
> > 3. We don't want to significantly change committer workflow.
> > 
> > Requirement 2 means that our current branching model will need to be changed.
> > Details will follow.
> > 
> > ## Overview of automation systems
> > 
> > - Gitlab CI
> > 
> >     It is capable of running build tests with relatively short turnaround time.
> > 
> > - Bots like Patchew and Patchwork
> > 
> >     They are able to slurp patches from xen-devel and maybe run customised
> >     scripts on those patches.
> > 
> > - Osstest
> > 
> >     Pushgate, integration test system. It runs more sophisticated tests
> >     compared to Gitlab CI. Turnaround time is long.
> >     
> > ## New world
> > 
> > There will be an unified endpoint for committers and bots. Committers and bots
> > will have their git trees. Patches are committed to those trees. An automated
> > system will get patches from those trees and trigger CI runs.
> > 
> > The system will pick up commits from one of the trees, merge them with master
> > and send the merge to CI systems.
> > 
> > For bots, only Gitlab CI build tests will run. Results are sent back to
> > xen-devel.
> > 
> > For committers' trees, at first Gitlab CI build tests are run, if the result is
> > successful, the merge commit is submitted to osstest. If osstest deems the
> > merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> > is discarded. Test results are sent back to xen-devel.
> > 
> > With this system, all published commits should have already passed Gitlab CI
> > and osstest tests.
> > 
> > ## Gaps
> > 
> > The component / system which merges trees and drives CI systems is missing.
> > 
> > Patchew and Patchwork don't do all the things we care about yet.
> 
> I understand the general principle and I am on board. But I missing some
> details.
> 
> Is the idea that each committer would have his own git tree and branch
> with a specific name which would be picked up automatically by the
> CI-loop daily? In the style of linux-next? If it passed, it is given to
> OSSTest automatically and eventually committed?

Branch / tree -- whichever works best.

If the target under test passes, it will eventually be committed to
xen.git; otherwise the target is discarded and submitters / committers
get notified what failed.

> 
> Or is it the idea that each committer would have a way to manually
> submit a branch to the CI-loop for testing when he wished to do so?  In
> the style of github pull-requests-based CI-loops? If this is the case,
> then we just need a way to trigger the CI-loops on a given branch?
> 

This is the same as above. How the system works internally has no
visible effect on committer workflow.

In both cases, you just need to follow instructions to commit to a tree
/ branch / repository.

> In any case, my only feedback would be to also allow CI-loops on
> branches that are *not* meant to be committed automatically if tests
> pass. So that we can apply a complex series to a branch and see if tests
> pass before doing reviews or running experiments.

Understood.

Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

* Re: [Xen-devel] Xen project CI systems and committer workflow
@ 2019-04-30 10:07     ` Wei Liu
  0 siblings, 0 replies; 32+ messages in thread
From: Wei Liu @ 2019-04-30 10:07 UTC (permalink / raw)
  To: Stefano Stabellini
  Cc: Juergen Gross, Lars Kurth, Wei Liu, Doug Goldstein, Committers,
	Xen-devel

On Thu, Apr 18, 2019 at 10:54:05AM -0700, Stefano Stabellini wrote:
> On Thu, 18 Apr 2019, Wei Liu wrote:
> > Hi all
> > 
> > We now have Gitlab CI as a complementary system to Osstest and have planned to
> > add bots. It's high time we think about how we integrate them and how it may
> > improve our workflow.
> > 
> > ## Requirements
> > 
> > 1. We want to have light weight build tests before a patch series is reviewed
> > or committed.
> > 
> > 2. We don't want to push broken patches to central repository such that
> > everyone is blocked.
> > 
> > 3. We don't want to significantly change committer workflow.
> > 
> > Requirement 2 means that our current branching model will need to be changed.
> > Details will follow.
> > 
> > ## Overview of automation systems
> > 
> > - Gitlab CI
> > 
> >     It is capable of running build tests with relatively short turnaround time.
> > 
> > - Bots like Patchew and Patchwork
> > 
> >     They are able to slurp patches from xen-devel and maybe run customised
> >     scripts on those patches.
> > 
> > - Osstest
> > 
> >     Pushgate, integration test system. It runs more sophisticated tests
> >     compared to Gitlab CI. Turnaround time is long.
> >     
> > ## New world
> > 
> > There will be an unified endpoint for committers and bots. Committers and bots
> > will have their git trees. Patches are committed to those trees. An automated
> > system will get patches from those trees and trigger CI runs.
> > 
> > The system will pick up commits from one of the trees, merge them with master
> > and send the merge to CI systems.
> > 
> > For bots, only Gitlab CI build tests will run. Results are sent back to
> > xen-devel.
> > 
> > For committers' trees, at first Gitlab CI build tests are run, if the result is
> > successful, the merge commit is submitted to osstest. If osstest deems the
> > merge is good, the merge is pushed (published) to xen.git, otherwise the merge
> > is discarded. Test results are sent back to xen-devel.
> > 
> > With this system, all published commits should have already passed Gitlab CI
> > and osstest tests.
> > 
> > ## Gaps
> > 
> > The component / system which merges trees and drives CI systems is missing.
> > 
> > Patchew and Patchwork don't do all the things we care about yet.
> 
> I understand the general principle and I am on board. But I missing some
> details.
> 
> Is the idea that each committer would have his own git tree and branch
> with a specific name which would be picked up automatically by the
> CI-loop daily? In the style of linux-next? If it passed, it is given to
> OSSTest automatically and eventually committed?

Branch / tree -- whichever works best.

If the target under test passes, it will eventually be committed to
xen.git; otherwise the target is discarded and submitters / committers
get notified what failed.

> 
> Or is it the idea that each committer would have a way to manually
> submit a branch to the CI-loop for testing when he wished to do so?  In
> the style of github pull-requests-based CI-loops? If this is the case,
> then we just need a way to trigger the CI-loops on a given branch?
> 

This is the same as above. How the system works internally has no
visible effect on committer workflow.

In both cases, you just need to follow instructions to commit to a tree
/ branch / repository.

> In any case, my only feedback would be to also allow CI-loops on
> branches that are *not* meant to be committed automatically if tests
> pass. So that we can apply a complex series to a branch and see if tests
> pass before doing reviews or running experiments.

Understood.

Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 32+ messages in thread

end of thread, other threads:[~2019-04-30 10:07 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-18 12:31 Xen project CI systems and committer workflow Wei Liu
2019-04-18 12:31 ` [Xen-devel] " Wei Liu
2019-04-18 12:32 ` Wei Liu
2019-04-18 12:32   ` [Xen-devel] " Wei Liu
2019-04-18 13:30   ` Doug Goldstein
2019-04-18 13:30     ` [Xen-devel] " Doug Goldstein
2019-04-18 13:21 ` Ian Jackson
2019-04-18 13:21   ` [Xen-devel] " Ian Jackson
2019-04-18 13:36   ` Doug Goldstein
2019-04-18 13:36     ` [Xen-devel] " Doug Goldstein
2019-04-18 13:59 ` Andrew Cooper
2019-04-18 13:59   ` [Xen-devel] " Andrew Cooper
2019-04-18 14:02   ` Ian Jackson
2019-04-18 14:02     ` [Xen-devel] " Ian Jackson
2019-04-25 12:37     ` Jan Beulich
2019-04-25 12:37       ` [Xen-devel] " Jan Beulich
2019-04-25 12:53       ` Julien Grall
2019-04-25 12:53         ` [Xen-devel] " Julien Grall
2019-04-25 13:01         ` George Dunlap
2019-04-25 13:01           ` [Xen-devel] " George Dunlap
2019-04-18 21:33   ` Doug Goldstein
2019-04-18 21:33     ` [Xen-devel] " Doug Goldstein
2019-04-23  9:12   ` Wei Liu
2019-04-23  9:12     ` [Xen-devel] " Wei Liu
2019-04-18 17:54 ` Stefano Stabellini
2019-04-18 17:54   ` [Xen-devel] " Stefano Stabellini
2019-04-30 10:07   ` Wei Liu
2019-04-30 10:07     ` [Xen-devel] " Wei Liu
2019-04-25 12:33 ` Jan Beulich
2019-04-25 12:33   ` [Xen-devel] " Jan Beulich
2019-04-25 14:51   ` George Dunlap
2019-04-25 14:51     ` [Xen-devel] " George Dunlap

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.