ISolutionFile fileToSave = repository.getSolutionFile(fullPath, ISolutionRepository.ACTION_UPDATE);
if (fileToSave != null || (!repository.resourceExists(filePath) && parentFile != null)) {
repository.publish(base, '/' + parentPath, action, content.getBytes() , true);
log.debug(PluginConfig.PLUGIN_NAME + " : Published " + solution + " / " + path + " / " + action );
} else {
throw new Exception("Error ocurred while saving query to solution repository");
}
return Response.ok().build();