use of com.intellij.tasks.impl.RequestFailedException in project intellij-community by JetBrains.
the class BugzillaRepository method ensureVersionDiscovered.
private void ensureVersionDiscovered() throws Exception {
if (myVersion == null) {
Hashtable<String, Object> result = new BugzillaXmlRpcRequest("Bugzilla.version").execute();
if (result == null) {
throw new RequestFailedException(TaskBundle.message("bugzilla.failure.no.version"));
}
String version = (String) result.get("version");
String[] parts = version.split("\\.", 3);
myVersion = new Version(Integer.parseInt(parts[0]), parts.length > 1 ? Integer.parseInt(parts[1]) : 0, parts.length > 2 ? Integer.parseInt(parts[2]) : 0);
if (myVersion.lessThan(3, 4)) {
throw new RequestFailedException("Bugzilla before 3.4 is not supported");
}
}
}
Aggregations