Google Authentication / Drive / Download

Hello team,
Evening.
So I am trying to use Google Drive in our company to download / update / upload excel files.
I used Google Authentication, Google Drive node as shown below. For the time being, I have saved my authentication in the “Node” as shown below…

image

image

Then I download one template excel file from Drive to temporarily created folder and connect to database , run query and update that excel template.
image

image
Once updated, I am putting back on Drive at another location for client to use.

image

This entire process works fine on my local desktop.

Once I put this on server ( with reset workflow ) and scheduled it to run after 10 minutes to test, I get error on the “Download” node saying the “Connection Timed Out” because the “Drive is not connected”.

How do I make this such as, this works normally / automatically ? Am I missing something ?

My server admin has said that I may have some issues later on with saving credentials in “Node” but I atleast want to make it work.

Any one else encountered this kind of error?
Thank you for helping me…
SS

1 Like

Hi there @ss_123,

are you talking about KNIME Server or some other Server?

Anyways you can try Google Authentication (API Key) node.

You can find this topic useful:

Br,
Ivan

1 Like

Hi Ivan,
Good morning.
Yes I am referring to KNIME Server. Basically, in our company, we can develop the workflow on our knime analytics plateform (4.0.2) desktop application and once tested, publish on KNIME server to schedule / run.
I looked into little bit that Google API node. but have to digest it.
Is Google Authentication node supposed to work only from desktop ? More I look into this, makes me think, there is potential issue of “Credentials”. If I am publishing workflow with my credentials, can someone use it later on and get access to files on my drive ?

SS

1 Like

Hi there @ss_123,

ok. So it is KNIME Server related. Will check a bit more on best practices regarding Google services, your concerns and get back to you.

(Also changed category to KNIME Server.)

Br,
Ivan

Hi,
I would assume that the authentication information is deleted when the Google Authentication node is reset. Could you try resetting the workflow except for the Google Authentication node and then uploading that to the server? Make sure you uncheck the checkbox for resetting the workflow when deploying to the server via the context menu.
Kind regards
Alexander

Hi Ivan,
Thank you for updating to “Server” issue. No problem.
Hey Alex,
Yes… I have done that. Here are the steps…

  1. Test workflow (fresh) on my local desktop app. Works, file gets download/updates/uploads to drive back fine.
  2. Reset the entire workflow. Re-authenticate Google nodes as shown below.

image

  1. I deploy the workflow on KNIME server. Make sure that the box is unchecked…

image

  1. Schedule the workflow, where also I have unchecked the “Reset” box …

image


Even after all these, I tested again today and received following error.

image

This causes subsequent errors on “Download” node and fails after that.

Hope this clarifies.

==========
I also looked at the “Google API” node, but I believe I may not be able to use it, as it requires creating temp project folder, which I don’t have privilege to do. Looking into it more though.

Thank you much both,
SS.

1 Like

Hi,
what if you only keep the Google Authentication node executed? Have you tried that? The connection should be established again on the server, so it should be reset.
Kind regards
Alexander

1 Like

Tried… I am out of luck… Didn’t work… … sorry…
Tried both Memory / Node options below. None works on server. I can’t try the middle one custom.

image

1 Like

Hi,
Connection timed out suggests that KNIME cannot even create a connection to Google, so maybe there is no authentication going on in the first place. Do you think certain connections could be blocked on the server?
Kind regards
Alexander

2 Likes

Hi @ss_123,
any luck with the Google Authentication in the meantime?
Kind regards,
Alexander

Hi Alex,
Good afternoon
No… solution yet. Our server admin said, he has opened a case with Knime/Google… both…
He actually replicated the issue and also found that the Google Authentication in node/memory only stays till 1 hr… After that it expires.
So let’s see what he comes up with… But till then, I can not publish any of my workflows on server.
oh well
SS

1 Like

Hi,
That the authentication is only valid for a certain amount of time makes sense. KNIME acquires an authentication token but for security reasons this is only valid for a certain amount of time. I would be interested in what the Google Support says about this.
Kind regards
Alexander

1 Like

Hi @ss_123,
did you hear back from Google? Were you able to solve this issue?
Kind regards,
Alexander

1 Like

That’s correct. The token is a temporary certificate that has an expiration and would require the manual process of opening the node, going through the login, and now you have another certificate set to expire. @ss_123, what luck did you have setting up the API portion that lets you store the certificate on your computer :slight_smile:

Think of it like… this node is easy mode, good for prototyping…

The other node has a bit of a walkthrough, that’s because you need to setup GCP and Google API pieces need to be enabled, this is for your security and monitoring “benefits” and it’s identical to the workflow you have, however the TEMP file becomes a BETTER file and it’s not temporary. You also now have control of whether that file works anymore, which lets you administrate this solution better with smart permissions.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.