davido / gerrit-ci-plugin

Deprecated: Gerrit CI reporting and visualization plugin. Moved to https://gerrit.googlesource.com/plugins/verify-status
Apache License 2.0
4 stars 1 forks source link

Extending the RevisionInfo object #5

Open zaro0508 opened 8 years ago

zaro0508 commented 8 years ago

I see that the data is in a separate DB now however there's is now a disconnect between the revision and verifications data. I believe we still want to add the VerificationInfo object to the RevisionInfo object so that verifications are saved per patch set and REST API can show 'verifications' as documented here: https://github.com/davido/gerrit-ci-plugin/blob/master/src/main/resources/Documentation/rest-api-changes.md#response

It seemed pretty straight forward making that relationship when adding VerificationInfo in core however I'm not seeing a good way to do that from a plugin. Do you have any ideas?

davido commented 8 years ago

Why would we need to include VerificationInfo into RevisionInfo?

Let's talk about main use case and ignore all other issues for now. When a change screen is opened in any UI (Gertty, GWT, PollyGerrit, ReviewIT, ...) patch set is retrieved, and for this patch set the verification iinfo request should be triggered by our UI-Plugin-Integration, in which case, this REST endpoint is called:

https://github.com/davido/gerrit-ci-plugin/blob/master/src/main/java/com/googlesource/gerrit/plugins/ci/server/GetVerifications.java

The data is retrieved and is rendered/integrated on the change screen, like JavaScript table on OpenStack's gerrit.