Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 100: refresh user directory after src config changes copied over #101

Open
wants to merge 1 commit into
base: integration
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,18 @@ private boolean lookForSrcConfigChanges(IResourceDelta projectDelta, IProgressMo
IPath location = project.getLocation();
buildPluginHelper.updateSrcConfig(location, config, monitor);

// Any changes to the src server config have been copied over to the
// user directory so make sure it is refreshed
UserDirectory userDir = wsServer.getServerInfo().getUserDirectory();
final IProject userDirProject = userDir.getProject();
if (userDirProject != null && userDirProject.isAccessible()) {
try {
userDirProject.refreshLocal(IResource.DEPTH_INFINITE, new NullProgressMonitor());
} catch (Exception e) {
Trace.logError("Refreshing user directory project failed", e);
}
}

// Change the server to republish state so it will process the changed file on the next publish operation
WebSphereServerBehaviour wsb = wsServer.getWebSphereServerBehaviour();
wsb.setWebSphereServerPublishState(IServer.PUBLISH_STATE_INCREMENTAL);
Expand Down