ON-PREM CHOREO CLOUD BOTH

What it is

sync-upstream is a GitHub Actions workflow in the private repository wso2-enterprise/agent-manager. It keeps that repository level with the public wso2/agent-manager by opening a pull request that merges the public changes in. A person merges that pull request.

Like a library branch that checks every hour for new books at the main library and puts them on a trolley for the librarian to shelve.

Why it exists

The SaaS team works from a private copy so that urgent fixes can be tested before they are public. The copy must not drift away from the public project.

How it works

  • A schedule runs it hourly (the cron expression is 17 * * * *, so at 17 minutes past each hour). It can also be started by hand, with optional branch, upstream branch and upstream ref.
  • It fetches the public branch and compares it with the private one. If they match, or the private one is ahead because a fix is in flight, it stops.
  • If the private branch is behind, it merges the public commit onto a branch named sync/upstream-<branch>. A merge conflict stops it and sends a chat alert.
  • It opens or updates a pull request that lists the commits brought in, and posts a Google Chat message when a new pull request opens or the sync is blocked.
  • The workflow does not merge the pull request. Its fallback instructions say to merge with a merge commit, never squash.

Key facts

Repository
wso2-enterprise/agent-manager
Upstream
wso2/agent-manager (public)
Schedule
Hourly, at 17 minutes past
Sync branch
sync/upstream-<branch>
Merge style
A merge commit, never a squash
Alerts
Google Chat, only when a pull request opens or a step newly fails
Namespace
GitHub Actions

Talks to (1)

Used by (1)