I did not attend Google I/O but as soon as the video "Google I/O 2009 - Best Practices for Architecting GWT App" (http://www.youtube.com/ watch?v=PDuhR18-EdM) was posted I reviewed it and was a bit confused by the idea of an EventBus.
>From what I can tell the idea is that UI widgets requiring data from the server are able to fire off requests for some form of data like "void getTransactionsForAccount(Account acct)" then at some unknown later time (ms to seconds ussually) when a response comes in from the RPC call the eventbus is what actually directly recives the data and then it is dispatched Client UI: "Hey call some RPC method with these parameters, my AsyncCallback is this EventBus thing" ...some unknown time passes while the server does magic... Client Event Bus: "A response came in of type X/Y/Z I should fire an event to all interested parties" Client UI: "According to this event I just recieved some of my UI code needs to change" A few things are still very hazy for me... 1- What is missing here is when would the Client UI typically subscribe/unsubscribe from the event bus. If this were a desktop application I would simply use weak reference so I would not have to unsubscribe my UI manually to prevent a memory leak. 2- Is there some EventBus code I should be using that already exists in the GWT SDK? Is this the same code that is used for handling widget events like clicking a button? 3- Would you typically have one eventbus code for everything? 4- How does this tie in with the MVP pattern? If anybody else watched the video I would be curious what they have to say. Also Ray Ryan mentioned he was going to be creating a new demo application for GWT developers to see this sort of thing in action. That would be awesome, does anybody have any thoughts on this as well? Thanks in advance for your comments. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to Google-Web-Toolkit@googlegroups.com To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/Google-Web-Toolkit?hl=en -~----------~----~----~----~------~----~------~--~---