Ask Your Question
2

OAuth2 token refresh

asked 2018-10-02 04:40:20 -0500

peter_f gravatar image

updated 2018-10-12 04:03:19 -0500

When using Google OAuth2 in the HTTPClient destination, the pipeline starts failing after the token has reached it's validity.

{ "iss":"removed-stuff", "target_audience":"removed-stuff", "aud":"https://www.googleapis.com/oauth2/v4/token", "exp":${(time:dateTimeToMilliseconds(time:now())/1000) + 50 * MINUTES}, "iat":${time:dateTimeToMilliseconds(time:now())/1000} }

I was expecting that after 50 minutes the client tries to refresh the token before it expires, but that doesn't seem to happen. Even after several hours, just to rule out some timezone mismatch (UTC, Vienna Time Zone), it keeps failing.

After restarting the whole pipeline it starts working again until the token expires again.

Does the HTTPClient support token refresh? Regarding the documentation I was expecting it does.

Version used: 3.4.3

regards Peter

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2018-10-05 04:41:09 -0500

Alexander gravatar image

updated 2018-10-05 04:44:23 -0500

Hi Peter,

For myself, I could not get the OAuth2.0 feature working for GoogleAdwords, however found a workaround for it, including refreshing the tokens. You can check my answer at my crosspost, maybe it will help you: https://ask.streamsets.com/question/3...

edit flag offensive delete link more

Comments

Hi Alexander, Thank you for sharing the workaround, as I'm using a private API I'm not sure if I can use that 1:1, but I'll figure that out. What really makes me sad is the complete lack of information provided by Streamsets regarding the intended behavior if a refresh should happen.

peter_f gravatar imagepeter_f ( 2018-10-12 04:02:00 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2018-10-02 04:40:20 -0500

Seen: 39 times

Last updated: Oct 12