Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be available on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 528199 - Calling Bug.get is being stuck in an endless loop and never returns dues to ExternalBugs
Summary: Calling Bug.get is being stuck in an endless loop and never returns dues to E...
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Bugzilla
Classification: Community
Component: WebService
Version: 3.4
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Noura El hawary
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: RHBZ34UpgradeTracker
TreeView+ depends on / blocked
 
Reported: 2009-10-09 18:13 UTC by David Lawrence
Modified: 2009-10-28 20:37 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-10-28 20:37:41 UTC


Attachments (Terms of Use)
v1 for fixing problem with endless loop in Bug.get (591 bytes, patch)
2009-10-26 12:46 UTC, Noura El hawary
nelhawar: review? (dkl)
Details | Diff

Description David Lawrence 2009-10-09 18:13:11 UTC
Description of problem:
When calling Bug.get via XMLRPC it never returns and causes httpd on the test server to consume large amount of resources. Somewhere it is getting stuck in endless loop of some kind. If I comment out the following line in extensions/external_bugs/code/get_bug_data.pl it works fine:

#$bugref->{'external_bugs'} = extensions::external_bugs::lib::ExternalBugs->new( { bug => $bugref } );

I have temporarily added extensions/external_bugs/disabled to allow us to continue testing. Will need to be removed when we figure out what is wrong.

Dave

Comment 1 Noura El hawary 2009-10-26 12:46:01 UTC
Created attachment 366097 [details]
v1 for fixing problem with endless loop in Bug.get

Hi Dave,

I was able to fix the problem with the endless loop of Bug.get by adding the line 
$bug->{external_bugs} = $bug->external_bugs->{bugs}; 

to Bugzilla/WebService/Bug.pm 

similar to what we have in bugzilla.getBugs and also in our 3.2 code we had it for Bug.get.

Thanks,
Noura

Comment 2 David Lawrence 2009-10-26 21:16:08 UTC
Thanks Noura. I am going to hold off on this review as I got the idea to rewrite the External Bugs code completely today as I was never really happy with my old implementation. The new one is more clean and more compliant with normal Bugzilla objects. I am almost done and will show what I have tomorrow. So the patch 
you made will probably need changing as well.

Also as a side note. I am making quite a bit of changes to the hook naming that we currently use which will touch quite a few files. I am also removing hooks that we created ourselves that are not longer needed as upstream has added more.

Thanks
Dave

Comment 3 Noura El hawary 2009-10-28 12:07:59 UTC
Hey Dave,

This seems to be working with your new external_bugs code. and the testcase t/400_webservice_bug_get_bugs.t passes successfully.

Thanks,
Noura

Comment 4 David Lawrence 2009-10-28 20:37:41 UTC
Closing as this should be better now.


Note You need to log in before you can comment on or make changes to this bug.