Commits on Source 12

  • GitLab Release Tools Bot's avatar
  • Patrick Steinhardt's avatar
    ruby: Drop README for our Protobuf files · b29f8633
    Patrick Steinhardt authored
    The README file located with our generated Ruby Protobuf code still
    provides information of the old times where Protobuf definitions were
    living in their own `gitaly-proto` repository. These times have long
    gone by, and I doubt anybody still tries to search for that repository.
    
    Remove the README. This also prepares for us dropping the generated Ruby
    code from our tree altogether.
    b29f8633
  • Patrick Steinhardt's avatar
    ruby: Move scripts that generate Proto sources into tools directory · d17621d7
    Patrick Steinhardt authored
    We've got multiple scripts that are required to generate Ruby code from
    our Protobuf definitions in the `_support` directory. This has multiple
    smells:
    
        - It's out-of-line with all the other tools, which nowadays are
          located in the `tools` directory.
    
        - It's hard to discover and find out which parts logically form a
          unit.
    
        - We are reusing the Gemfile of the Ruby sidecar to pin the
          `grpc-tools` dependency to a specific version.
    
    Move the tooling into its own `tools/protogem` directory that's got its
    own Gemfile to fix these points. This also allows us to auto-update
    dependencies via the Renovate bot like we do for our other tools.
    d17621d7
  • Patrick Steinhardt's avatar
    tools/protogem: Refactor code to be less dependent on output dir · 95c43479
    Patrick Steinhardt authored
    The `generate-proto-ruby` script assumes a specific output directory
    that's always fixed at `ruby/proto`. We're about to drop our in-tree
    copy of generated Ruby code in favor of using the `gitaly` Gem, which
    will require us to generate the code in a temporary directory.
    
    Refactor the code to be less dependent on the output directory. Like
    this we can easily change the location where we generate the code into.
    Right now the location is unchanged though, which also demonstrates that
    there is no change in the generated code.
    95c43479
  • Patrick Steinhardt's avatar
    tools/protogem: Generate version file ad-hoc · efdc609d
    Patrick Steinhardt authored
    On every version bump the GitLab Release Tools bot updates the version
    in two different files: first in our top-level `VERSION` file, and
    second in the Ruby Protobuf files at `ruby/proto/version.rb`. Both files
    basically contain the same information, but serve different purposes.
    
    We're about to drop our generated Ruby Protobuf code though in favor of
    creating the Protobuf Gem ad-hoc. This also means it doesn't make a
    whole lot of sense anymore to carry around the version file in our tree.
    Consequentially, we've adjusted the Release Tools bot to stop writing
    the `version.rb` file completely. Instead, we now generate the file via
    the information we already have in our `VERSION` file.
    efdc609d
  • Patrick Steinhardt's avatar
    tools/protogem: Generate Protobuf sources ad-hoc when building Gem · 94b05d9e
    Patrick Steinhardt authored
    The Ruby sidecar is slowly nearing its end: right now, it only
    implements a single RPC that is in the process of being migrated to Go.
    This means we'll start to soon remove all the Ruby infrastructure in the
    Gitaly project.
    
    Part of the infrastructure is the Ruby code generated from our Protobuf
    definitions. And while we won't need that code ourselves anymore, it is
    important for clients written in Ruby that want to interface with us. As
    such, the Gitaly project still has to release the `gitaly` Gem. In the
    past, we built the Gem by simply soaking up the code in `ruby/proto`.
    But as it does not make any sense for us to keep the Ruby code around
    anymore this strategy will fail once we have removed it.
    
    Merge the `generate-proto-ruby` any `publish-gem` scripts into a single
    script that:
    
        1. Generates all required Ruby sources into a temporary directory.
    
        2. Writes the `gitaly.gemspec` file into the same directory.
    
        3. Builds the Gitaly Gem from those temporary files.
    
    Like this, all code is generated ad-hoc and doesn't need to be committed
    to the repository anymore.
    
    Change the Makefile's `proto` target to not generate Ruby code anymore.
    Instead, there are two new Makefile targets `build-proto-gem` and
    `publish-proto-gem` that are responsible for building and publishing the
    Gem, respecfively.
    
    The generated Ruby code is thus stale now and will be removed in a
    subsequent commit.
    94b05d9e
  • Patrick Steinhardt's avatar
    tools/protogem: Rename `generate-proto-ruby` to `build-proto-gem` · 1ac9019a
    Patrick Steinhardt authored
    The `generate-proto-ruby` script is not only generating the Ruby sources
    anymore, but also builds the `gitaly` Gem. It wasn't renamed in the
    preceding commit though as Git doesn't detect the rename by default,
    which would have made the diff hard to read.
    
    Rename the file now to the more fitting `build-proto-gem`.
    1ac9019a
  • Patrick Steinhardt's avatar
    tools/protogem: Merge helper script into `build-proto-gem` · 58e26888
    Patrick Steinhardt authored
    The helper functions in `run.rb` had in the past been used by multiple
    different scripts. Nowadays there is only a single user though, so let's
    inline it.
    58e26888
  • Patrick Steinhardt's avatar
    ruby: Remove stale generated Protobuf code · 1db0f5c7
    Patrick Steinhardt authored
    Now that we stopped updating our Ruby code generated from the Protobuf
    definitions in favor of ad-hoc generating it when building a new Gem it
    does not make sense to carry these files around anymore:
    
        - They are stale and will not be updated anymore.
    
        - Most of these files are unused anyway.
    
        - It is not expected that there will be any changes in the generated
          code that is relevant to our Ruby sidecar anymore. There is only a
          single RPC served by it nowadays which is in the process of being
          migrated to Go.
    
    Remove the Protobuf definitions and use the `gitaly` Gem instead.
    1db0f5c7
  • Quang-Minh Nguyen (Ex-GitLab)'s avatar
    Merge branch 'pks-tooling-refactor-building-protobuf-gem-v15.5' into '15-5-stable' · e8f4d228
    Quang-Minh Nguyen (Ex-GitLab) authored
    Generate Ruby's Protobuf sources ad-hoc when building Gem and drop generated code (v15.5 backport)
    
    See merge request gitlab-org/gitaly!5008
    
    
    
    Merged-by: Quang-Minh Nguyen (Ex-GitLab)'s avatarQuang-Minh Nguyen <qmnguyen@gitlab.com>
    Approved-by: Quang-Minh Nguyen (Ex-GitLab)'s avatarQuang-Minh Nguyen <qmnguyen@gitlab.com>
    Co-authored-by: Patrick Steinhardt's avatarPatrick Steinhardt <psteinhardt@gitlab.com>
    e8f4d228
  • GitLab Release Tools Bot's avatar
    Update changelog for 15.5.3 · 5acb930d
    GitLab Release Tools Bot authored
    [ci skip]
    5acb930d
  • GitLab Release Tools Bot's avatar
    Update VERSION files · 3600e168
    GitLab Release Tools Bot authored
    [ci skip]
    3600e168
Loading
Loading