Sitelet https://github.com/GoogleCloudPlatform/java-docs-samples/pull/1537
Skip to content

Add Cloud Tasks snippets - #1537

Merged
averikitsch merged 10 commits into
masterfrom
taskqueues
Aug 6, 2019
Merged

averikitsch merged 10 commits into
masterfrom
taskqueues

Conversation

@averikitsch

Copy link
Copy Markdown
Contributor

No description provided.

@averikitsch
averikitsch requested a review from a team August 6, 2019 03:45
@kurtisvg kurtisvg self-assigned this Aug 6, 2019
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Aug 6, 2019
@@ -0,0 +1,314 @@
/*
* Copyright 2018 Google LLC

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* Copyright 2018 Google LLC
* Copyright 2019 Google LLC

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

// [END taskqueues_retrying_tasks]

// Run sample: mvn clean package exec:java -Dexec.mainClass="com.example.appengine.Snippets"
public static void main(String[] args) throws Exception {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we remove this?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

import java.nio.charset.Charset;

public class Snippets {
// [START taskqueues_using_yaml]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should these follow the new format and be in different files?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done.

@kurtisvg kurtisvg left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have a few region tags that don't follow the guidelines from the previous sample - if they aren't in use it would be nice to remove them (or update if they are still being used).

queue.add(TaskOptions.Builder.withurl(/sitelet?url=https%3A%2F%2Fgithub.com%2FGoogleCloudPlatform%2Fjava-docs-samples%2Fpull%2F%26quot%3B%2Fworker%26quot%3B).param("key", key));
// [END addQueue]
try (CloudTasksClient client = CloudTasksClient.create()) {
String projectId = "starter-akitsch";

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

😲

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

?! I have no idea how that file got added to this PR?!

@averikitsch
averikitsch merged commit b407ebf into master Aug 6, 2019
@averikitsch
averikitsch deleted the taskqueues branch August 6, 2019 22:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants