#61 Consider writing XML counterpart for repository metadata output
Closed: Invalid Opened by ignatenkobrain.

YAML is nice and so on, but reality is that it is awful for machine parsing and some libraries (libsolv) do not want to grow with new dependencies which means, performance in tools like DNF will be slower than it could be.


This is a pretty reasonable request; We could add functionality to libmodulemd to export XML instead of/in addition to the YAML output. It wouldn't be much effort.

Reducing the delta that we require from the DNF folks makes sense to me. The main question I would have for @ignatenkobrain is whether we want to have it be a 100% complete conversion or if we should only output a subset of the modulemd content that is meaningful to DNF. If the latter, which attributes do you want?

That XML counterpart should also be supported by ModuleMetadata.dumps_all method.

@jkaluza Right, the way I envision it is that we will add a new option to dump() and dump_all() to set the output format.

@sgallagh we also need standard definition in XML, not just dump in some random form.

I want it to be 100% replacement for yaml

@sgallagh we also need standard definition in XML, not just dump in some random form.
I want it to be 100% replacement for yaml

I think you misunderstood; the output function in python-modulemd/libmodulemd is literally called dump(). But yes, there must be a spec to which the XML will conform.

-1 here.

I talked to @ignatenkobrain and he said he wouldn't even be using modulemd to read the XML data back in but rather reimplement whatever subset of modulemd functionality he'd need (if any), since depending on modulemd would pull YAML in anyway. This RFE requires us to maintain two formats, keep them in sync, and requires modulemd to grow dependencies on XML processing libraries, plus extra code to handle a feature which wouldn't actually be used.

If you want/need XML support, I suggest you convert modulemd YAML to whatever XML form (with DTD) you choose to maintain during the createrepo / modifyrepo phase.

Metadata Update from @psabata:
- Issue close_status updated to: Invalid
- Issue status updated to: Closed (was: Open)

Metadata