Skip to content
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

Introduce datatypes/java module for proto generation #391

Merged
merged 1 commit into from
Jan 8, 2020
Merged

Introduce datatypes/java module for proto generation #391

merged 1 commit into from
Jan 8, 2020

Conversation

ches
Copy link
Member

@ches ches commented Dec 24, 2019

Rather than the Maven protobuf plugin running on the same symlinked definitions in several Java modules, localize this process into one module that the others depend on.

This provides a single module that can be depended on by third-party extensions with the bare minimum of dependencies.

Also removes proto files that are no longer used.

The Maven protobuf plugin includes source .proto files when packaging by default, so third parties interested in consuming them (like us, for Scala SDK code generation) could potentially get them from the Feast Java SDK artifact at build time, without this PR. However, it's possible the SDK may add dependencies over time (auth libraries come to mind) that not all extenders will want.

From a Feast developer perspective also, it seems cleaner to build the mostly ubiquitous generated code once, rather than have redundant build products under the target/ directories of several modules and introducing the worry that those caches might become inconsistent.

I've named the module datatypes from a convention I've used for situations like this in the past, but perhaps that's not suggestive of gRPC service code also generated therein. I'm open to naming suggestions, or if we'd like to put pure data vs. service code in separate modules, I'm happy to make that change too. It just seemed like overkill to me for now (we need both for a Scala SDK anyway).

I will also backport this to v0.3-branch if we have consensus.

@feast-ci-bot
Copy link
Collaborator

Hi @ches. Thanks for your PR.

I'm waiting for a gojek member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

----------

TODO: this module should be published to Maven Central upon Feast releases—this
needs to be set up in POM configuration and release automation.
Copy link
Member Author

Choose a reason for hiding this comment

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

@davidheryanto Maybe you can help us here if you already have Maven configuration for publishing the SDK to Sonatype. Things can be published later by a credential holder, but we can include any needed build config in this branch so it gets cherry-picked for backport. (Not sure if Sonatype will approve a group ID of feast, let's see).

I think CI configuration for publishing on release builds can be a separate PR, including the SDK too, unless you disagree. You probably know best how you'd like that automation to work, how secrets are handled in Prow, etc.

Copy link
Collaborator

@davidheryanto davidheryanto Dec 27, 2019

Choose a reason for hiding this comment

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

Hi @ches
Yes, we already have a PR for the publishing of Feast library to Sonatype (which will sync it to Maven Central) #394 The group id we use is dev.feast
Will include the publishing of these protos as well in another PR.

@woop
Copy link
Member

woop commented Dec 25, 2019

/ok-to-test

@ches
Copy link
Member Author

ches commented Dec 26, 2019

/retest

@ches
Copy link
Member Author

ches commented Dec 26, 2019

The test failures are maybe flaky, they're timeouts and I don't expect any functional change from this PR, but I don't have much ability to troubleshoot beyond the raw build log in Prow so if you think/see otherwise please let me know.

@woop
Copy link
Member

woop commented Dec 27, 2019

@davidheryanto @khorshuheng can either of you have a look at these tests? It doesnt seem like we are solving the root cause of these flaky tests. They keep randomly failing.

@khorshuheng
Copy link
Collaborator

I will take a look tonight.

@davidheryanto
Copy link
Collaborator

The failing test currently is because we hardcode the revision number in the test script. Will make a quick update.

@davidheryanto
Copy link
Collaborator

After this PR is merged to master, I think test-end-to-end batch should succeed
#395

@davidheryanto
Copy link
Collaborator

/retest

@ches
Copy link
Member Author

ches commented Jan 2, 2020

Happy New Year!

CI looks green now, is there anything more I should do here?

@woop
Copy link
Member

woop commented Jan 3, 2020

After this PR is merged to master, I think test-end-to-end batch should succeed
#395

@davidheryanto the above PR is now merged.

@ches Is this PR consistent with #394? Some comments

  • I think it makes sense to have this as a separate module. I am fine with the name. I would prefer to not add more folders to the top level of the repo, but that would create an inconsistency with how we structure submodules so perhaps this is fine for the time being.
  • Porting to 0.3 makes sense.
  • Thanks for removing unused protos.

@khorshuheng @davidheryanto are we happy with approving this PR? You both have more Java fu than I do :)

core/pom.xml Outdated Show resolved Hide resolved
@ches
Copy link
Member Author

ches commented Jan 4, 2020

Rebased, which entailed updating to dev.feast group ID following #394.

@davidheryanto
Copy link
Collaborator

/lgtm

Rather than the Maven protobuf plugin running on the same symlinked
definitions in several Java modules, localize this process into one
module that the others depend on.

This provides a single module that can be depended on by third-party
extensions with the bare minimum of dependencies.

Also removes proto files that are no longer used.
@feast-ci-bot feast-ci-bot removed the lgtm label Jan 7, 2020
@ches
Copy link
Member Author

ches commented Jan 7, 2020

Resolved conflicts after #406 (changed back to ${revision} for Feast version in POMs)

@davidheryanto
Copy link
Collaborator

/lgtm

@woop
Copy link
Member

woop commented Jan 8, 2020

/approve

@feast-ci-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ches, woop

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ches
Copy link
Member Author

ches commented Jan 8, 2020

/retest

@ches
Copy link
Member Author

ches commented Jan 8, 2020

Hmm, does Prow build the magic GitHub merge ref for speculatively merging the PR to master? This latest failure comment from the bot says commit 1cf9e4c, which is the one from my last rebase that passed yesterday. Trying to understand why it built again (and failed).

The current rerun is extremely slow, took more than 20 minutes to reach the point of pytest running, 10 more now with no test output… I wonder if the host executing it is unhealthy. (Edit: failures are now from TimeoutErrors).

@woop
Copy link
Member

woop commented Jan 8, 2020

Hmm, does Prow build the magic GitHub merge ref for speculatively merging the PR to master? This latest failure comment from the bot says commit 1cf9e4c, which is the one from my last rebase that passed yesterday. Trying to understand why it built again (and failed).

The current rerun is extremely slow, took more than 20 minutes to reach the point of pytest running, 10 more now with no test output… I wonder if the host executing it is unhealthy. (Edit: failures are now from TimeoutErrors).

@davidheryanto can you reply on @ches's first question.

@ches currently tests are not based on readiness but instead assume that the system will be ready at some point in time and will start the tests which then time out. Ideally we would stage the system, wait until it is ready (up to some point in time), and then start the tests when everything is ready.

We're investigating the logs of the Kubernetes cluster right now to see if we can figure out why this is so flaky and slow. Nothing jumps out yet. Unfortunately we don't have the bandwidth to allocate somebody to redo this setup right now, but it's one of the biggest things on my radar to resolve.

@davidheryanto
Copy link
Collaborator

davidheryanto commented Jan 8, 2020

@ches Yes, before running tests on pull request, Prow will merge the latest commit on pull request with the base branch, to make sure that the test runs succesfully after the pull request is merged in.

@ches
Copy link
Member Author

ches commented Jan 8, 2020

Thanks guys for the answers.

The latest failure is same as the one on #407 that seemed to be fixed by #412, but the latter is on master now so maybe the wait time is sometimes still not enough? Or it’s exacerbated by cluster conditions. It’d be good to eventually get a retry strategy in place for integration tests instead of relying on plain sleeps, not sure if pytest or extra plugins for it may have some integration utilities like that already.

Are we confident this PR is not a source of issues and can move forward? This is the base in a chain of rebases for a few things I’m working on.

@woop
Copy link
Member

woop commented Jan 8, 2020

/test test-end-to-end-batch

@feast-ci-bot feast-ci-bot merged commit 8bdc38c into feast-dev:master Jan 8, 2020
@ches ches deleted the protos-as-module branch January 8, 2020 08:37
khorshuheng pushed a commit to khorshuheng/feast that referenced this pull request Feb 13, 2020
Rather than the Maven protobuf plugin running on the same symlinked
definitions in several Java modules, localize this process into one
module that the others depend on.

This provides a single module that can be depended on by third-party
extensions with the bare minimum of dependencies.

Also removes proto files that are no longer used.
davidheryanto pushed a commit that referenced this pull request Feb 13, 2020
* Update Changelog (#423)

* Initial commit of changelog up to 0.4.3

* Remove unreleased changes on master

* Add missing changelog manually

Co-authored-by: Khor Shu Heng <32997938+khorshuheng@users.noreply.github.com>

* Introduce datatypes/java module for proto generation (#391)

Rather than the Maven protobuf plugin running on the same symlinked
definitions in several Java modules, localize this process into one
module that the others depend on.

This provides a single module that can be depended on by third-party
extensions with the bare minimum of dependencies.

Also removes proto files that are no longer used.

* Update basic Feast example to Feast 0.4 (#424)

* Add documentation for bigquery batch retrieval (#428)

* Add documentation for bigquery batch retrieval

* Fix formatting for multiline comments

* Bump hibernate-validator from 6.0.13.Final to 6.1.0.Final in /ingestion (#421)

Bumps [hibernate-validator](https://github.com/hibernate/hibernate-validator) from 6.0.13.Final to 6.1.0.Final.
- [Release notes](https://github.com/hibernate/hibernate-validator/releases)
- [Changelog](https://github.com/hibernate/hibernate-validator/blob/master/changelog.txt)
- [Commits](hibernate/hibernate-validator@6.0.13.Final...6.1.0.Final)

Signed-off-by: dependabot[bot] <support@github.com>

* Publish datatypes/java along with sdk/java (#426)

This forward-ports a straggling commit from #407: it was missed when
initially creating the datatypes module because Sonatype publishing
setup was added concurrently.

* Remove "resource" concept and the need to specify a kind in feature sets (#432)

* Update GKE installation and chart values to work with 0.4.3 (#434)

* Fix logging (#430)

Allow log level to be set via environmental variable.
Add ability to set appender type in serving.
Remove logback-classic from ingestion as it is a library so should not bring its own impl.
Upgrade log4j to 2.12.1 to support objectMessageAsJsonObject.
Fix logger config targeting feast package in serving an add same concept for core.

* Bump chart version

* Update Changelog (#447)

* Update Changelog

* Remove closed issues

Co-authored-by: Willem Pienaar <6728866+woop@users.noreply.github.com>
Co-authored-by: Ches Martin <ches@whiskeyandgrits.net>
Co-authored-by: Chen Zhiling <chnzhlng@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Lionel Vital <lgvital@gmail.com>
Co-authored-by: Iain Rauch <Yanson@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants