Closed Bug 928410 Opened 11 years ago Closed 11 years ago

Bug.get should return detail about cc list members similar to assigned_to, creator and qa_contact

Categories

(Bugzilla :: WebService, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
Bugzilla 5.0

People

(Reporter: dkl, Assigned: dkl)

Details

Attachments

(1 file)

Currently when returning data from Bug.get, you can get extra details about the assignee, reporter, and qa contact. But not for members of the cc list. Patch coming that will also add 'cc_detail' for the cc list members.

dkl
Attached patch 928410_1.patchSplinter Review
Attachment #819044 - Flags: review?(LpSolit)
Comment on attachment 819044 [details] [diff] [review]
928410_1.patch

Gerv has less reviews and this one should be short.
Attachment #819044 - Flags: review?(LpSolit) → review?(gerv)
Comment on attachment 819044 [details] [diff] [review]
928410_1.patch

dkl: this seems like a bit of a hack; are you doing it this way rather than updating the "cc" item to be a hash because of backwards compatibility?

Can we change the contents of "cc" in the next major-numbered release of Bugzilla (5.0), do your change for now, but use documentation to encourage people to write code which checks for both cases?

Gerv
(In reply to Gervase Markham [:gerv] from comment #3)
> Comment on attachment 819044 [details] [diff] [review]
> 928410_1.patch
> 
> dkl: this seems like a bit of a hack; are you doing it this way rather than
> updating the "cc" item to be a hash because of backwards compatibility?
> 
> Can we change the contents of "cc" in the next major-numbered release of
> Bugzilla (5.0), do your change for now, but use documentation to encourage
> people to write code which checks for both cases?
> 
> Gerv

We cannot change the contents of 'cc' as long as Bug.get is marked as STABLE even when we go to 5.0. We can only
add additional keys such as *_detail. Of course when we support versioning of the API, REST 2.0 will have cc, assigned_to, qa_contact, creator, etc. be replaced by their _detail counterparts. I would rather do that method
than change a stable method as Bugzilla versions and API versions should be different.

dkl
(In reply to David Lawrence [:dkl] from comment #4)
> We cannot change the contents of 'cc' as long as Bug.get is marked as STABLE
> even when we go to 5.0. 

From http://www.bugzilla.org/docs/4.2/en/html/api/Bugzilla/WebService.html:

"If we ever break a STABLE interface, we'll post a big notice in the Release Notes, and it will only happen during a major new release."

So I think we can.

> Of course when we support versioning
> of the API, REST 2.0 will have cc, assigned_to, qa_contact, creator, etc. be
> replaced by their _detail counterparts.

That would lead to a divergence between REST and XML-RPC (unless you are proposing to version XML-RPC as well?). Are you cool with that?

Gerv
(In reply to Gervase Markham [:gerv] from comment #5)
> (In reply to David Lawrence [:dkl] from comment #4)
> > We cannot change the contents of 'cc' as long as Bug.get is marked as STABLE
> > even when we go to 5.0. 
> 
> From http://www.bugzilla.org/docs/4.2/en/html/api/Bugzilla/WebService.html:
> 
> "If we ever break a STABLE interface, we'll post a big notice in the Release
> Notes, and it will only happen during a major new release."
> 
> So I think we can.
> 

The original thinking was:

1) For 5.0+ we would make REST the primary API and XMLRPC/JSONRPC would be carried along and only security fixes would be added.
2) After 6.0+, XMLRPC/JSONRPC to be removed completely and all work to be on REST only.

After some discussion it could be that we just do 1) as a 4.6 release and then do 2) for 5.0 when it comes out and speed things along soon. 

Both scenarios would hinge on getting versioning to work and we would brand what we have now as 1.0 and then 1.1 of the REST API we can start making incremental changes where it makes sense.

> > Of course when we support versioning
> > of the API, REST 2.0 will have cc, assigned_to, qa_contact, creator, etc. be
> > replaced by their _detail counterparts.
> 
> That would lead to a divergence between REST and XML-RPC (unless you are
> proposing to version XML-RPC as well?). Are you cool with that?

We would never version the XMLRPC/JSONRPC APIs, only REST.

dkl
Comment on attachment 819044 [details] [diff] [review]
928410_1.patch

OK. r=gerv.

Gerv
Attachment #819044 - Flags: review?(gerv) → review+
Flags: approval?
OS: Linux → All
Hardware: x86_64 → All
Target Milestone: --- → Bugzilla 5.0
Severity: normal → enhancement
Flags: approval? → approval+
Committing to: bzr+ssh://dlawrence%40mozilla.com@bzr.mozilla.org/bugzilla/trunk
modified Bugzilla/WebService/Bug.pm
Committed revision 8788.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: