Skip to content

RFE - determine build batches from modulemd  #8

Open
@FrostyX

Description

I imagine that every build system that supports building modules needs to have some piece of code determining what module RPMs can be built simultaneously and which need to wait and be built after some prerequisites. At this moment it is (AFAIK) trivially determined by buildorder.

The problem is, that build systems still need to parse the modulemd (i.e. directly depend on python3-libmodulemd) and implement this basic functionality by themselves. Therefore I think, that modulemd-tools is the right place to put such code.

I am suggesting to create a script called modulemd-builds or more explicitly modulemd-build-batches that will parse a modulemd YAML file and return output in this format.

[
  [
    {
      "name": "jss",
      "repository": "http://foo.bar/jss.git",
      "ref": "master"
    }
  ],
  [
    {
      "name": "tomcatjss",
      "repository": "http://foo.bar/tomcat.git",
      "ref": "master"
    },
    {
      "name": "ldapjdk",
      "repository": "http://foo.bar/ldapjdk.git",
      "ref": "master"
    }
  ],
  [
    {
      "name": "pki-core",
      "repository": "http://foo.bar/pki-core.git",
      "ref": "master"
    },
    {
      "name": "dogtag-pki",
      "repository": "http://foo.bar/dogtag-pki.git",
      "ref": "master"
    }
  ]
]

So, the format it JSON having a list of batches where each batch is represented by a list of packages. The batches need to be built after each other if and only if all the builds from the previous batch succeeded. Packages within a batch can be submitted in random order or in parallel. Each package is represented by a dictionary of all the parameters required for building it.

Do you think it is worth it having such script? Do you like the output format?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions