Not able to fetch the FileSystem from Hitachi_NAS_File_Storage - file

When I try to execute the below curl command I am getting an issue:
curl -vk -H "X-Api-Key: zrxvSDAv9x.RIP4gkmKarG3beF.or.4Tc2im7oeqYN88C9XPGHxbXC" https://172.17.11.11:8444/v7/storage/filesystems
Error:
{
"errorCode" : 1081427,
"errorDetail" : {
"detail" : "[no detail]",
"fault" : "SOAP-ENV:Receiver",
"fileName" : "FileSystemMgmntProvider.cpp",
"function" : "getAllFileSystems",
"lineNumber" : 54,
"message" : "Failed to find a list of file system IDs on the server.",
"reason" : "Failed to find a list of file system IDs on the server.",
"returnedValue" : 2,
"subCode" : 8992
},
"errorMsg" : "An internal HNAS error which usually results from an object not found or an invalid parameter."
}
But I am able to see the FileSystems on that specific server. Am I missing anything.
Please let me know if any permission or any issue with the version.
Reference:
https://knowledge.hitachivantara.com/Documents/Storage/NAS_Platform/13.9/Hitachi_NAS_File_Storage_REST_API_Reference/File_system_resource/02_Get_file_systems

Related

Error on send email endpoint. Precondition check failed

I have got an application up and running, and sending emails using the API with no problem at all. But for specific customers, I am getting the following error and I cannot manage to reproduce it. Could you give me further details about the problem? It works for most of my customers
{
"code" : 400,
"errors" : [ {
"domain" : "global",
"message" : "Precondition check failed.",
"reason" : "failedPrecondition"
} ],
"message" : "Precondition check failed.",
"status" : "FAILED_PRECONDITION"
}
I am using the Java Client library from Google, and this is how my code looks I followed the Google guides:
MimeMessage content = emailService.createEmail(sendEmailRequest);
Message message = createMessageWithEmail(content);
gmail.users().messages().send(ME, message).execute();
The path that the client is hitting is this one {userId}/messages/send and these are the scopes the application asks:
openid email https://www.googleapis.com/auth/gmail.send
Thanks in advance

Error in createIndexes: Failed to send "createIndexes" command with database "mydb": Failed to read 4 bytes: socket error or timeout

I have been recently migrating python code to C using libmongoc-1.0 1.15. I am having troubles creating indexes. I am following the example here. I think it has something to do with me using MongoDB 4.2 since it changed all indexes to be background by default, but I thought version 1.15.3 of libmongoc does support everything new in 4.2.
{ "createIndexes" : "mycol", "indexes" : [ { "key" : { "x" : 1, "y" : 1 }, "name" : "x_1_y_1" } ] }
{ }
Error in createIndexes: Failed to send "createIndexes" command with database "mydb": Failed to read 4 bytes: socket error or timeout
Any thoughts?
"failed to send "createIndexes" command with database "testdb" mongodb error"
I was having a similar issue, in our case, one of the replica sets was having the issue after fixing the issue related replica set and restarting the cluster issue solved

how to set an OCR language in Google Drive

I need to upload image into Google Drive including the OCR feature.
The problem with the setOcrLanguage method. I need to specify Hebrew language and based on ISO 639-1 codes its should be "heb".
I'm getting the response
"code" : 400,
"errors" : [ {
"domain" : "global",
"location" : "ocrLanguage",
"locationType" : "parameter",
"message" : "Invalid Value",
"reason" : "invalid"
} ],
Any idea what should be the code or where I can get the list of avaliable codes?

Exception is sometimes being thrown when coppying messages from folder to another using javamail

When trying to copy a list of messages from one folder to another, sometime this exceptions appears.
nested exception is :
com.sun.mail.iap.BadCommandException: A5 BAD COPY failed. Invalid messageset.
at com.sun.mail.imap.IMAPFolder.copyMesages(IMAPFolder.java.1769)
Caused by:
com.sun.mail.iap.BadCommandException: A5 BAD COPY failed. Invalid messageset.
at com.sun.mail.iap.Protocol.handleResult(Protocol.java:353)
at com.sun.mail.iap.Protocol.simpleCommand(Protocol.java:373) ...
My Code :
public void moveMessageToTrash(String sourceFolder, String destinationFolder,
MimeMessage mimeMessage) throws MessagingException
{
IMAPFolder source = null;
IMAPFolder destination = null;
if(store.isConnected())
{
source = (IMAPFolder) store.getFolder(sourceFolder);
destin= (IMAPFolder) store.getFolder(destinationFolder);
source.open(Folder.READ_WRITE);
destin.open(Folder.READ_WRITE);
}
Message [] messages = new MimeMessage[1];
messages[0] = mimeMessage;
source.copyMessages(messages,destin);
source.setFlags(messages,new Flags(Flags.Flag.DELETED),true);
source.expunge():
}
EDIT :
Before removing the
source.expunge();
The thrown exception was :
messageRemovedException.
And nothing is being said by the debugger more than what is already said on the initialization of the javamail session :
When the copy fails, nothing is said by the debugger. Everything is shown is only at the initialization of the session :
INFO : DEBUG : JavaMail version 1.5.1
INFO : DEBUG : failed to load any providers, using defaults.
INFO : DEBUG : Tables of loaded providers.
INFO : DEBUG : Providers Listed By Class Name : {com.sun.mail.smtp.SMTPSSLTRANSORT=javax.mail.Provider[TRANSPORT,smtps,com.sun.mail.smtp.SMTPSSLTRANSPORT,Oracle,1.5.1]....
INFO : DEBUG : Providers Listed By Protocol :
....
INFO : DEBUG : failed to load address map, using defaults.
what i want to say is that after i removed the source.expunge() from the code, no exception is being thrown anymore, but actually the failure is still exists, some messages are being copied to the target and set deleted in the source, and a litle number of them are copied to the target but set deleted there, not in the source.
Possibly some of the messages you're copying have been deleted and expunged, either by your application or by some other application accessing the same folder? A detailed protocol trace might provide more information.

log() instruction leads to build error : cannot find symbol "to()"

When I try to compile this
from(rule.getInput().getUrl()).
log(LoggingLevel.INFO, "New incoming message, rule n°"+getRule().getId()).
routeId(getId()).
filter().method(rule, "verify").
to(outputs);
I have a build error :
MVN : C:\........\DynamicRouteBuilder.java:[38,33] cannot find symbol
MVN : symbol : method to(java.lang.String[])
( to(java.lang.String[]) refers to to(outputs) )
But if I remove the log row :
from(rule.getInput().getUrl()).
//log(LoggingLevel.INFO, "New incoming message, rule n°"+getRule().getId()).
routeId(getId()).
filter().method(rule, "verify").
to(outputs);
It works!
It also works if I move the log row beetween filter() and to().
I can't see why. Any clue?

Resources