Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [WTP-DEV] in wst.server, sync-ing with server question

Hi Rob,

Various changes can be made to a server (adding and removing modules, possibly other local configuration changes), but they are not guaranteed to be synchronized on the server until after the next publish. In some local cases this distinction may not really matter (e.g. if the server is directly running against the workspace and automatically picks up changes), but in the remote or disconnected case, the model is that the user can make changes locally (e.g. add or remove a module) and these changes are pushed to the server the next time they publish.

In API terms, ServerDelegate handles making changes to the local model, and does not interact with the server. ServerBehaviourDelegate is responsible for all the runtime interaction with the server, publishing, etc. During a publish, the publish flags and deltas provide the server with information on which modules are new, removed, changed, etc.

Please feel free to email me directly or we can setup a call if you have further questions. Also, feel free to open bugs or submit patches if you find places where this could be described better and help the next adopter.

Tim deBoer
WebSphere Tools - IBM Canada Ltd.
(905) 413-3503  (tieline 969)

"Robert Stryker" <rob.stryker@xxxxxxxxx>
Sent by: wtp-dev-bounces@xxxxxxxxxxx

22/05/2006 02:30 PM

Please respond to
"General discussion of project-wide or architectural issues." <wtp-dev@xxxxxxxxxxx>

[WTP-DEV] in wst.server, sync-ing with server question

Hi All:

In wst.server, I'm uncertain as to which of the following classes are responsible for syncing with the server. Is it my ServerBehaviorDelegate implementation (and its publishModule method?) or is it the ServerDelegate implementation (and its modifyModules(add, remove, progress) method?)

Up until this point I assumed it was the responsibility of the publishModule method in the serverbehavior, as it is called from the runOnServerAction via a PublishServerJob. I started to get doubts, though, when I noticed the RemoveModuleAction does not create any such job, but only calls wc.modifyModules(etc).

So at this point it seemed to me that the RunOnServerAction is keeping the ServerBehaviorDelegate responsible for publishing to the server, but the RemoveModuleAction only alerts the ServerDelegate. I remained confused primarily because of a new bug I posted:, where if I select an object and try to run it on a server, it first adds it to the server (via modifyModules) and then later does a PublishJob, with the potential if no client is selected or cancel is pressed that it's been added via ModifyModule but not published via the server behavior delegate.

So in short, I'm trying to figure out the suggested or recommended implementation for adding and removing modules from the local model, as well as actually publishing and unpublishing to/from the server.

Thanks for your time.

- Rob Stryker
wtp-dev mailing list

Back to the top