Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[389699] Run on server on starting server will not publish if the

module is changed
  • Loading branch information...
commit dd67198c92ab84dfc28957f6ad090a18bb03d4d4 1 parent efceeb8
Elson Yuen elsony authored
15 ...erver.ui/serverui/org/eclipse/wst/server/ui/internal/actions/RunOnServerLaunchConfigurationDelegate.java
View
@@ -140,8 +140,19 @@ public boolean supports(IServer server3, Object launchable2, String launchMode3)
IModule[] modules = new IModule[] { module }; // TODO: get parent hierarchy correct
int state = server.getServerState();
if (state == IServer.STATE_STARTING) {
- LaunchClientJob clientJob = new LaunchClientJob(server, modules, launchMode, moduleArtifact, launchableAdapter, client);
- clientJob.schedule();
+ final LaunchClientJob clientJob = new LaunchClientJob(server, modules, launchMode, moduleArtifact, launchableAdapter, client);
+ final IServer server2 = server;
+ if (server2.shouldPublish()) {
+ server2.publish(IServer.PUBLISH_INCREMENTAL, null, info, new IServer.IOperationListener() {
+ public void done(IStatus result) {
+ if (result.isOK()){
+ clientJob.schedule();
+ }
+ }
+ });
+ } else {
+ clientJob.schedule();
+ }
} else if (state == IServer.STATE_STARTED) {
boolean restart = false;
String mode = server.getMode();
Please sign in to comment.
Something went wrong with that request. Please try again.