This is a multi-part message in MIME format.
--------------020507040501040703080208
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Hi,
In the case of Gluster, as there are no one to one mappings available
for all the error messages from Gluster, we set the error in the
VdcFault object as NULL.
We also populate the actual error from the Gluster as error message in
the fault object.
/getReturnValue().getExecuteFailedMessages().add(error);//
//getReturnValue().getFault().setMessage(error);//
//getReturnValue().getFault().setError(null);/
Because of above settings and the below code snippet in /Frontend.java/
class the error message as is gets displayed on the error dialog -
/
//public String translateVdcFault(final VdcFault fault) {//
// return
getVdsmErrorsTranslator().TranslateErrorTextSingle(fault.getError() ==
null//
// ? fault.getMessage() : fault.getError().toString());//
//}//
/
Well and good till now !!
But while translation of the error messages, all the occurrences of "."
get replaced with "_".
This causes an issue for the gluster errors. If the error message sent
from gluster has "."s (say IP Address of a host or FQDN for a host),
that also gets replaced with "_" and the error message does not look
correct.
Request your suggestion for handling such a case.
*PS: *One thing I can think of is, introducing a flag called
/isExternalError/ in /VdcFault/ class to identify if the source of the
fault is external. From Gluster we would set the flag as /true/, and
while replacement of "." with "_", if the flag is set it will not do
the
replacements.
Regards,
Shubhendu
--------------020507040501040703080208
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
<html>
<head>
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi,<br>
<br>
In the case of Gluster, as there are no one to one mappings
available for all the error messages from Gluster, we set the error
in the VdcFault object as NULL.<br>
We also populate the actual error from the Gluster as error message
in the fault object.<br>
<br>
<font
color="#000099"><i>getReturnValue().getExecuteFailedMessages().add(error);</i><i><br>
</i><i>getReturnValue().getFault().setMessage(error);</i><i><br>
</i><i>getReturnValue().getFault().setError(null);</i></font><br>
<br>
Because of above settings and the below code snippet in
<i>Frontend.java</i>
class the error message as is gets displayed on the error dialog -<br>
<font color="#000099"><i><br>
</i><i>public String translateVdcFault(final VdcFault fault)
{</i><i><br>
</i><i>
return
getVdsmErrorsTranslator().TranslateErrorTextSingle(fault.getError()
== null</i><i><br>
</i><i>
? fault.getMessage() :
fault.getError().toString());</i><i><br>
</i><i>}</i><i><br>
</i></font><br>
Well and good till now !!<br>
<br>
But while translation of the error messages, all the occurrences of
"." get replaced with "_".<br>
This causes an issue for the gluster errors. If the error message
sent from gluster has "."s (say IP Address of a host or FQDN for a
host), that also gets replaced with "_" and the error message does
not look correct.<br>
<br>
Request your suggestion for handling such a case.<br>
<br>
<b>PS: </b>One thing I can think of is, introducing a flag called
<i>isExternalError</i>
in <i>VdcFault</i> class to identify if the source of the fault is
external. From Gluster we would set the flag as <i>true</i>, and
while replacement of "." with "_", if the flag is set it will not
do
the replacements.<br>
<br>
Regards,<br>
Shubhendu <br>
</body>
</html>
--------------020507040501040703080208--