Issue Details (XML | Word | Printable)

Key: FELIX-600
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Felix Meschberger
Reporter: Felix Meschberger
Votes: 0
Watchers: 0
Operations

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

Insert Delay before refreshing packages after install/update

Created: 06/Jun/08 01:30 PM   Updated: 12/Jun/08 10:10 PM
Return to search
Component/s: Web Console
Affects Version/s: webconsole-1.0.0
Fix Version/s: webconsole-1.2.0

Time Tracking:
Not Specified

Resolution Date: 12/Jun/08 10:10 PM


 Description  « Hide
The WebConsole can be instructed to do a PackageAdmin.refreshPackages(null) after installing or updating a bundle. As there may be some things going on asynchronously behind the scenes after an installation/update, the call of the refreshPackages method should be delayed. Because the install/update actually works in a background thread, we can add such a delay without delaying client interactivity.

I insert a delay of 2 seconds for now. This is an empiric number, not a scientifically computed one, but I assume it should work out fine.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Karl Pauls added a comment - 06/Jun/08 01:40 PM
Could you not listen to the installed/updated events and then do the refresh?

Felix Meschberger added a comment - 06/Jun/08 01:55 PM
I could, but this would not, I fear. The problem here is, that the framework signals successfull installation/update when it is done. At this time the Declarative Services manager has scheduled the components to be activated.

So when the framework has finished updating the bundles Declarative Services is still working. So whether I wait for an event or not does not matter.

Karl Pauls added a comment - 06/Jun/08 02:05 PM
o.k., I'm not claiming I understand what the issue is anyways - it just looked like it would be more sound this way then introducing a magic timeout value :-)

Felix Meschberger added a comment - 06/Jun/08 02:37 PM
No problem with that at all. In fact, I value your input very much, because it may in fact be a mistake on my part.

(also my alert system also goes off on words like "delay" and "poll" ;-) )

Felix Meschberger added a comment - 12/Jun/08 10:10 PM
This has been implemented and tested and confirmed successfull. Therefore closing this issue for now.