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

Key: QB-3884
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Robin Shen
Reporter: Phong Trinh
Votes: 0
Watchers: 0
Operations

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

User Attributes in QuickBuild and attributes.properties are not in sync

Created: 07/Sep/22 03:00 AM   Updated: 14/Sep/22 10:57 PM
Component/s: None
Affects Version/s: 11.0.28
Fix Version/s: None

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown


 Description  « Hide
 - On one of our QuickBuild agent, I set its user attribute named CleanMachine equals to 1 and made sure this attribute and its value in its attributes.properties are the same ( CleanMachine=1)Then I took a snapshot of this machine.
 - I had a configuration to run tests on this machine. After the tests were done, it set the attribute, CleanMachine equals to 0 (for taking this machine out of the pool. So other tests would not jump on this machine right away) and then reverted the machine to the snapshot.
 - I expected that CleanMachine would set back 1 in Grid after the reversion was done, but it was not. Although CleanMachine equals to 1 in attributes.properties.

 Please look into this when you have very early chance or give me any alternative/workaround on this.

 Thanks

 All   Comments   Work Log   Change History      Sort Order:
Robin Shen [07/Sep/22 02:12 PM]
Please restart agent after reversion to see if attributes can be synchronized.

Phong Trinh [07/Sep/22 03:06 PM]
I rebooted the agent, but the attributes were still not synchronized.

Robin Shen [08/Sep/22 07:56 AM]
This is odd. Please stop the agent, waiting for it to be removed from active agent list, and start again to see it works.

Phong Trinh [09/Sep/22 03:20 AM]
Thank you for prompt response. It works with stopping and then starting the agent as your suggestion. However, it may not work for my test automation, since I cannot revert and stop/start agent in one automation and have many agents and tests that are running in parallel.

Robin Shen [09/Sep/22 08:06 AM]
Without restarting the agent, QB has no chance to know the agent attribute is updated.

Phong Trinh [09/Sep/22 01:41 PM]
Thanks, again!
Looks like QB updates agent's attributes after the agent is re-started. I am curious that when I revert the machine/agent, QB also loses the connection to the agent and reconnects to it successfully. Why the attributes are not updated?

Robin Shen [09/Sep/22 02:17 PM]
QB only thinks that the connection is temporarily down, and if it reconnects, it thinks network comes back, but in this case there is no reason to re-sync the attributes.

Phong Trinh [09/Sep/22 05:05 PM]
Is it possible if QB re-syncs the attributes every re-connection? I think that is helpful and keeps the attributes in sync.

Robin Shen [09/Sep/22 11:35 PM]
Seems that in your case, your agent reconnects shortly after a snapshot restore, and QB actually does not detect a connection loss. You will have to add some logic to make snapshot restore a bit longer to wait for agent to be timedout. In that case, QB server console will display something like:

Active build agent 'agentmachine:8811' timed out, removing..

Otherwise, everything seems fine to QB server, and there is no reason to reload attributes from time to time.

Phong Trinh [10/Sep/22 11:38 PM]
I will do as your suggestion and let you know. Thanks!

Phong Trinh [14/Sep/22 01:58 PM]
I changed 'Agent Timeout' setting to shorter time instead of making the reversion to take longer and then reverted the agents. I still received the the same issue. The OS of these agents Windows 11. Do you think the OS causes the issue?

Robin Shen [14/Sep/22 10:57 PM]
OS is not an issue. When snapshot is being restore, please check server log to see if agent is timedout. Only in that case, reconneted agent will reload the attributes.