History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: QB-1179
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Robin Shen
Reporter: Pini Reznik
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
QuickBuild

QB Resource Available -1

Created: 23/Dec/11 09:13 AM   Updated: 27/Dec/12 01:07 PM
Component/s: None
Affects Version/s: 4.0.20
Fix Version/s: None

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
Environment:
System Date and Time 2011-12-23 10:09:30
Operating System Linux 2.6.16.60-0.21-smp, amd64
JVM Java HotSpot(TM) 64-Bit Server VM 1.6.0_23, Sun Microsystems Inc.
QuickBuild Version 4.0.20 - Sat Dec 17 14:28:14 CET 2011


 Description  « Hide
We have a QB resource configured to 1 parallel execution.
Today we saw this resource used twice on one of the agents and the resource tab on active nodes page said:
#Available=-1
#Used=2



 All   Comments   Work Log   Change History      Sort Order:
Robin Shen [24/Dec/11 05:26 AM]
I checked the code, and the #available is impossible to be "-1". We will round it to 0 if the value is less than 0. If you still encounter this, please let us know the reproducing step.

However it is possible that a resource with only 1 count can display a usage count of 2. Considering this case:
1. define a resource "db" with only one account at some agent.
2. master step of configuration "root/A" requires resource "db" to run, and it triggers and waits for finish of "roo/B".
3. master step of configuration "root/B" requires resource "db" to run, and it simply sleeps for some time.

In this case, master step of "root/B" is permitted to run as otherwise a deadlock will occur. Also allowing resource "db" to be occupied by master step of "root/B" will not cause problem as "root/A" is waiting and the acquired resource "db" is actually not being used. However in this case, QB can not distinguish whether or not the resource is used by which configuration, it simply displays all steps acquired the resource.

This also holds true in case when one configuration triggers and wait for another via the QuickBuild repository.

If this is not your case, please let us know the reproducing steps.