[jbosstools-issues] [JBoss JIRA] Issue Comment Edited: (JBIDE-7537) [deltacloud] Error response when launching instance
Andre Dietisheim (JIRA)
jira-events at lists.jboss.org
Tue Nov 9 12:47:01 EST 2010
[ https://jira.jboss.org/browse/JBIDE-7537?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12562268#action_12562268 ]
Andre Dietisheim edited comment on JBIDE-7537 at 11/9/10 12:45 PM:
-------------------------------------------------------------------
the exact reason is that the deltacloud client assumes that every url is related to a base url. When deltacloud reports actions that are available to instances, it reports full urls. I therefore try to strip the baseurl.
DeltaCloudClient:
private String stripBaseUrl(String url) throws DeltaCloudClientException {
String baseUrlString = baseUrl.toString();
if (url.indexOf(baseUrlString) != 0) {
throw new DeltaCloudClientException(MessageFormat.format(
"Resource at {0} is not child resource of root resource at {1}", url, baseUrl));
}
return url.substring(baseUrlString.length());
}
The deltacloud server seems to always report on behalf of IPs. If the user created the connection by using a hostname, stripping fails and creates the errors shown above.
was (Author: adietish):
the exact reason is that the deltacloud client assumes that every url is related to a base url. When deltacloud reports actions that are available to instances, it reports full urls. I therefore try to strip the baseurl.
private String stripBaseUrl(String url) throws DeltaCloudClientException {
String baseUrlString = baseUrl.toString();
if (url.indexOf(baseUrlString) != 0) {
throw new DeltaCloudClientException(MessageFormat.format(
"Resource at {0} is not child resource of root resource at {1}", url, baseUrl));
}
return url.substring(baseUrlString.length());
}
The deltacloud server seems to always report on behalf of IPs. If the user created the connection by using a hostname, stripping fails and creates the errors shown above.
> [deltacloud] Error response when launching instance
> ---------------------------------------------------
>
> Key: JBIDE-7537
> URL: https://jira.jboss.org/browse/JBIDE-7537
> Project: Tools (JBoss Tools)
> Issue Type: Bug
> Components: deltacloud
> Affects Versions: 3.2.0.Beta2
> Reporter: Libor Zoubek
> Assignee: Andre Dietisheim
> Attachments: .log, deltacloud.png
>
>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jbosstools-issues
mailing list