-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Add Oauth2 sample for Java 11 #1383
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
appengine-java11/oauth2/pom.xml
Outdated
<groupId>com.example.appengine</groupId> | ||
<artifactId>oauth2-sample</artifactId> | ||
|
||
<!-- <parent> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reminder to uncomment this before merging.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done.
appengine-java11/oauth2/pom.xml
Outdated
|
||
<dependencies> | ||
<!-- Compile/runtime dependencies --> | ||
<dependency> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A comment around where this can be found / why it's needed would be helpful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as comment on the other one - please add just a little more context so there is no mistaking where to find that folder.
appengine-java11/oauth2/pom.xml
Outdated
<groupId>com.google.oauth-client</groupId> | ||
<artifactId>google-oauth-client</artifactId> | ||
<version>1.28.0</version> | ||
<scope>provided</scope> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do these need to be scoped to provided?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe so for the runtime.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You may want to verify that these are provided by the runtime - Seems weird to me that they would be provided (I would think that would be a potential problem with versioning)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The user needs to copy the dependencies into ${project.build.directory}/appengine-staging; that folder provides the dependencies to the runtime. This is what I understand from Ludo, but correct me if this is off.
appengine-java11/oauth2/src/main/java/com/example/appengine/OAuth2CallbackServlet.java
Outdated
Show resolved
Hide resolved
@@ -0,0 +1,27 @@ | |||
<?xml version="1.0" encoding="UTF-8"?> | |||
<!-- | |||
Copyright 2015 Google Inc. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2019 Google LLC
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done.
appengine-java11/pom.xml
Outdated
@@ -0,0 +1,49 @@ | |||
<!-- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This pom can be removed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't we need this for the tests to run properly ie parent v child pom?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No - the update you made to Kokoro finds projects by using the pom's themselves instead of relying on the parent POM.
(If we were still doing it with the parent pom this tests wouldn't trigger anyway because it doesn't list the sub projects as modules and isn't listed in the pom located at root)
appengine-java11/pom.xml
Outdated
@@ -0,0 +1,49 @@ | |||
<!-- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No - the update you made to Kokoro finds projects by using the pom's themselves instead of relying on the parent POM.
(If we were still doing it with the parent pom this tests wouldn't trigger anyway because it doesn't list the sub projects as modules and isn't listed in the pom located at root)
appengine-java11/oauth2/pom.xml
Outdated
<groupId>com.google.oauth-client</groupId> | ||
<artifactId>google-oauth-client</artifactId> | ||
<version>1.28.0</version> | ||
<scope>provided</scope> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You may want to verify that these are provided by the runtime - Seems weird to me that they would be provided (I would think that would be a potential problem with versioning)
appengine-java11/oauth2/pom.xml
Outdated
|
||
<dependencies> | ||
<!-- Compile/runtime dependencies --> | ||
<dependency> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as comment on the other one - please add just a little more context so there is no mistaking where to find that folder.
@averikitsch tests on this sample didn't actually run (see the java11 logs) |
@@ -0,0 +1,7 @@ | |||
runtime: java11 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Should probably have a license?
No description provided.