Currently we have the information about the brew build artifact type duplicated:
brew-build.test.complete
"type": "brew-build"
The same applies for koji-build. This means that the two artifact definitions are in fact almost the same (basically just naming):
koji-build
An alternative way would be to have just a single artifact definition called rpm-build and reference it from both koji-build and brew-build messages. The type attribute could be removed.
rpm-build
brew-build
type
We could also use just a single definition for both koji & brew builds like suggested in this pull request:
Although this approach does not ensure the type is correct (enum lists both koji and brew build). But I don't think it is a big deal...
I have to say I don't like the idea of leaving the artifact.type attribute out. The problem that I see is that names of the topics are not part of the standard, so there's no guarantee on how they might evolve/change, unlike attributes that are part of the message.
artifact.type
Additionally, if the topic names do change, this would lead to necessary changes in the code that processes messages without the format changing, which again is not optimal.
I would personally go for the solution mentioned in PR #7, but I don't have a strong preference.
Yeah, current solution seems fine. I would not remove also artifact.type.
#7 was merged. Closing this.
Metadata Update from @mvadkert: - Issue assigned to mvadkert
Metadata Update from @mvadkert: - Issue status updated to: Closed (was: Open)
Login to comment on this ticket.