Unable to make connections from a deployed App Maker app to Cloud SQL - google-cloud-sql

I had a working App Maker application which uses the Directory API and the default Cloud SQL instance that gets created for the App Maker.
Before it was working fine and I was able to retrieve data from the Admin Console and insert them into the Cloud SQL database. Now it stopped working and when I check logs, I see the following:
Exception: Authorization Failed. More information: Unable to fetch
tokens for CloudSql connection:
I have not got any changes to the code and I did not modify anything. I only created a new deployment and I did change the product name in the OAuth Consent screen in the app's project properties to make it more use friendly...
I don't know what parts of the code to share since I did not change/type any new code and nothing in the error above points to anything specific about any part in the code...
Thanks a lot for any feedback and help on this!

Related

How to solve permission denied error on Huawei Cloud DB

I implemented the Huawei's Cloud DB and Auth Service into my project. After i create my Cloud DB Zone and Object Types i tried to use the executeUpsert() function of Cloud DB. But i got an error message that says "Permission Denied". Program executes all database operations after user authenticated. And authenticated users has permission to update the table. I don't know how to solve this permission problem. Does anyone have opinion?
Error Message;
I talked to some employees who are authorized in Huawei's Cloud DB and they helped me to find the cause of the problem. When i was getting the error, as you see in the screenshot below, the instance when user gets authentication and the instance when i initialize the AGConnectCloudDB were different.
after i defined the instance object globally and use the same instance when i am getting the auth and also initializing the AGConnectCloudDB object as you see in the below picture, the problem is solved!
Even though you implemented Huawei's Cloud DB and Auth Service into your project, there are still cases that can cause the “permission denied” error. https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-Guides/agc-clouddb-error-code-0000001117436042
Please check the following areas in your project to rule out the causes.
If in the log, you see auth error as well, please check:
If the above are all cleared out and the issue is still there, please provide more details for further troubleshooting.

Credentials for Db2 in IBM

I recently signed up for the Lite version (free) of Db2 in IBM. When I select 'open console', I receive an error message: {"trace":"89cc4337d11c197f1e4c12c51f027b77","errors":[{"code":"authentication_failure","message":"HWCSEC0016E: Authentication failed for SSO. This may caused by failed to generate access token in console side using existing credentials.","target":{"type":"","name":""},"more_info":""}]}. I've placed a couple of ticktets with IBM, but they say since I signed up for the 'free' service that they are unable to assist even though I only need assistance to access the service. Any thoughts?
Deleted the existing DB instance and created a new one in different location. And that worked for me.

How to setup google service account authorization in Node.js with JSON key file?

Trying to make use of the Server to Server OAuth flow defined here:
https://developers.google.com/identity/protocols/OAuth2ServiceAccount
Since I'm running from a local dev environment, I've created a service account in GCP and downloaded the JSON file with the private key, but cannot find any Node.js code examples on how to:
1) load the json file
2) set delegated credentials (for G Suite domain-wide authorization)
Places I've looked (besides stackoverflow) are Google's git wiki for the node.js client library, which does talk about server to server auth, but seems to assume you're running from appengine or google cloud and don't need to load a key file:
https://github.com/googleapis/google-api-nodejs-client#service-to-service-authentication
The Admin SDK Activities Reports API has a Node example, but it's using the web-based flow assuming a user is present:
https://developers.google.com/admin-sdk/reports/v1/quickstart/nodejs
Buried deep in the Node.js samples is use of the Directory API, which does seem to take a keyfile as input, but when I try running locally it says getClient is not a constructor, and still this example doesn't show how to set the G Suite admin user for context (which is generally when a refresh token and access token are loaded into the app):
https://github.com/googleapis/google-api-nodejs-client/blob/master/samples/directory_v1/group-delete.js
So... does anybody have an example of this? I really don't want to switch to a Python runtime but Google seems to have left out important examples on this topic.

Bluemix: how do I create a service?

I have a problem when creating a Bluemix service - when I select Create Service for either the language translator or any other service, the page stays loaded and never creates the service. What may be the problem? Appreciate any help you can give me.
Looking at the URL in your screen cap, you are using the old Bluemix console, which is no longer supported. Log into the new console using your existing User ID and password, and try creating your service again.

Do I need account-based permissions to initialize an mssoap client from a wsdl file?

I'm getting the this error when I try to use an ASP.NET WebService through an MSSOAP Client:
"WSDL Reader: Loading of the WSDL file failed HRESULT=0X80040154 Class not registered - Client: An
unanticipated error occured during the processing of this request.HRESULT=0x1812040:Class not registered."
At first I thought the SOAP library was not properly registered. But when I debugged the code I realized the error was being raised at the time of reading the web service definition (The Soap client does get created).
SOAPClient.mssoapinit "wsdl_URL"
Now, the issue only occurs when I execute the code as certain account (as for the rest of the accounts the code works pretty well). The original client is a Classic ASP page but I've reproduced the problem using a vbs script.
I run the script under several accounts, but just one presents the wsdl-reading failure.
I've granted reading permissions to the directory that contains the
asmx file to the failing account.
I've changed the physical path of the virtual directory where the
webservice is hosted to a general non-particular-profile location
like C:.
Ironically the application pool identity of the web application is
the account that presents the failure.
All the accounts can read the wsdl file through a browser just typing
the url (but still one of them can't from client code)
Do I need to grant additional permissions for the account in order to read the web service definition and initialize the soap client?