I'm using the library ibm-cos-sdk, and when I'm calling the upload or the putObject function to send a file into a COS.
At first, I was having some issues because of the configuration object, the values were wrong. After that, I started testing the settings with different values just to check if the error handling was working.
That's when I realized that if I set the correct accessKeyID / secretAccessKey values, but with a different endpoint/bucket name (The bucket name and the endpoint exists), I still get the uploaded successfully log into the console even that the file was not uploaded into the COS.
I try to read the data response, but I'm only getting (using upload function) /// there was no file uploaded.
So, my question is, is there a way to know if the file is been successfully uploaded?
const cos = new COS.S3({
accessKeyId: 'ce6e8 .........edf', /// CORRECT VALUE
secretAccessKey: "7d874d.......afd6", /// CORRECT VALUE
endpoint: 's3.us-east.cloud-object-storage.appdomain.cloud' /// WRONG VALUE
});
Description
I'm using the library ibm-cos-sdk, and when I'm calling the upload or the putObject function to send a file into a COS. At first, I was having some issues because of the configuration object, the values were wrong. After that, I started testing the settings with different values just to check if the error handling was working.
That's when I realized that if I set the correct accessKeyID / secretAccessKey values, but with a different endpoint/bucket name (The bucket name and the endpoint exists), I still get the
uploaded successfully
log into the console even that the file was not uploaded into the COS. I try to read the data response, but I'm only getting (using upload function) /// there was no file uploaded.and with the putObject the response only has
So, my question is, is there a way to know if the file is been successfully uploaded?