public void reportResourceModification(String resourceKey) {
ResourceDto rootProject = resourceDao.getRootProjectByComponentKey(resourceKey);
+ if (rootProject == null) {
+ throw new SonarException("Unable to find root project for component with [key=" + resourceKey + "]");
+ }
propertiesDao.setProperty(new PropertyDto().setKey(SONAR_DRY_RUN_CACHE_LAST_UPDATE_KEY).setResourceId(rootProject.getId())
.setValue(String.valueOf(System.nanoTime())));
}
}
}
if (req.getPath().getPath().contains("/gzip/")) {
+ if (!"gzip".equals(req.getValue("Accept-Encoding"))) {
+ throw new IllegalStateException("Should accept gzip");
+ }
resp.set("Content-Encoding", "gzip");
GZIPOutputStream gzipOutputStream = new GZIPOutputStream(resp.getOutputStream());
gzipOutputStream.write("GZIP response".getBytes());
}
}
} catch (IOException e) {
+ throw new IllegalStateException(e);
} finally {
try {
resp.close();
</div>
<table class="data width100" id="permission-templates">
<thead>
- <tr>
+ <tr valign="top">
<th class="left" width="20%"><%= message('name') -%></th>
<th class="left">
<%= message('projects_role.admin') -%><br/>