-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
[BEAM-11289] [Java] Integrate Google Cloud Recommendations AI functio… #13645
[BEAM-11289] [Java] Integrate Google Cloud Recommendations AI functio… #13645
Conversation
Quick question - due to the usage of GenericJsons in the transforms, I had to add 2 coders ( |
cbf20b2
to
ff7fba0
Compare
taking a look at this... |
to get passing RAT PreCommit, you need to add apache license headers to all new files : ) or excemptions for files that can't fit a comment with the license |
2a1fb72
to
51120a3
Compare
@pabloem thanks - made some changes and looks like the tests are passing now :) |
...ions/ml/src/main/java/org/apache/beam/sdk/extensions/ml/BatchRequestForRecommendationAI.java
Outdated
Show resolved
Hide resolved
...s/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportCatalogItems.java
Outdated
Show resolved
Hide resolved
...ons/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportUserEvents.java
Outdated
Show resolved
Hide resolved
51120a3
to
c385c2c
Compare
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.
added a few comments
...ns/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAICreateCatalogItem.java
Show resolved
Hide resolved
...ns/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAICreateCatalogItem.java
Outdated
Show resolved
Hide resolved
...tensions/ml/src/test/java/org/apache/beam/sdk/extensions/ml/RecommendationAIUserEventIT.java
Outdated
Show resolved
Hide resolved
Run Java PostCommit |
...s/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportCatalogItems.java
Outdated
Show resolved
Hide resolved
...s/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportCatalogItems.java
Show resolved
Hide resolved
...ons/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportUserEvents.java
Show resolved
Hide resolved
880a80d
to
a8604af
Compare
hey @pabloem - I have addressed the comments we discussed, can you take another look please? :) |
Run Java PreCommit |
@pabloem looks like those test failures are not related to this PR? |
Run Java PreCommit |
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.
Sorry, I just added one more comment to remove public
where possible, and to depend on BeamModulePlugin. All else looks good.
...s/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportCatalogItems.java
Outdated
Show resolved
Hide resolved
...s/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportCatalogItems.java
Outdated
Show resolved
Hide resolved
...s/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportCatalogItems.java
Outdated
Show resolved
Hide resolved
...ons/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportUserEvents.java
Outdated
Show resolved
Hide resolved
...ons/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIImportUserEvents.java
Outdated
Show resolved
Hide resolved
...sions/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIWriteUserEvent.java
Outdated
Show resolved
Hide resolved
...sions/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIWriteUserEvent.java
Outdated
Show resolved
Hide resolved
...sions/ml/src/main/java/org/apache/beam/sdk/extensions/ml/RecommendationAIWriteUserEvent.java
Outdated
Show resolved
Hide resolved
The Workflow run is cancelling this PR. It is an earlier duplicate of 2173354 run. |
The Workflow run is cancelling this PR. It is an earlier duplicate of 2173354 run. |
Run Java PostCommit |
Run PostCommit_Java_DataflowV2 |
note that some tests are failing: https://ci-beam.apache.org/job/beam_PostCommit_Java_PR/680/ |
Hey @pabloem - the tests (for CatalogItem and UserEvent) work locally for me, but I am hitting my own GCP project (since the tests are calling APIs inside a project that needs the API enabled). I think this is why the tests are returning For the Predict test I think the reason is related: since the model has no data yet (and we are trying to get a prediction based on |
Adjusting docs Adjusting prediction eventtype
Run Java PostCommit |
@pabloem could it be that the serviceaccount running the tests doesn't have the correct permissions yet? (e.g. |
Run Java PostCommit |
post commit test is still failing. - What is the next step on this PR? |
@aaltay I would assume the same trouble as we have on the Python PR (service account permissions) |
Run Java PostCommit |
1 similar comment
Run Java PostCommit |
sorry about the delay! - yes, I think you can squash and merge please @matthiasa4 : ) |
I can do it if you prefer, but since you're a committer, feel free to merge it yourself. Thanks! |
@Override | ||
public PCollectionTuple expand(PCollection<GenericJson> input) { | ||
return input.apply( | ||
ParDo.of(new WriteUserEvent(projectId(), catalogName(), eventStore())) |
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.
Based on the usage here, it seems like projectId
cannot actually be null. I see that it is explicitly nullable, though. Am I missing something?
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.
Is it to allow the withXYZ
pattern? And then we should validate the final state of everything at the beginning of expand?
Integrate Google Cloud Recommendations AI functionality
Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:
R: @username
).[BEAM-XXX] Fixes bug in ApproximateQuantiles
, where you replaceBEAM-XXX
with the appropriate JIRA issue, if applicable. This will automatically link the pull request to the issue.CHANGES.md
with noteworthy changes.See the Contributor Guide for more tips on how to make review process smoother.
Post-Commit Tests Status (on master branch)
Pre-Commit Tests Status (on master branch)
See .test-infra/jenkins/README for trigger phrase, status and link of all Jenkins jobs.
GitHub Actions Tests Status (on master branch)
See CI.md for more information about GitHub Actions CI.