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

[Feature] Easy Ec2 deployment #1160

Merged
merged 83 commits into from
Nov 11, 2020
Merged

Conversation

mayurnewase
Copy link
Contributor

@mayurnewase mayurnewase commented Oct 6, 2020

Description

One click deployment for AWS ec2 with autoscaling group.

Motivation and Context

For easy deployment without load balancing

How Has This Been Tested?

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature and improvements (non-breaking change which adds/improves functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Code Refactoring (internal change which is not user facing)
  • Documentation
  • Test, CI, or build

Component(s) if applicable

  • BentoService (service definition, dependency management, API input/output adapters)
  • Model Artifact (model serialization, multi-framework support)
  • Model Server (mico-batching, dockerisation, logging, OpenAPI, instruments)
  • YataiService gRPC server (model registry, cloud deployment automation)
  • YataiService web server (nodejs HTTP server and web UI)
  • Internal (BentoML's own configuration, logging, utility, exception handling)
  • BentoML CLI

Checklist:

  • My code follows the bentoml code style, both ./dev/format.sh and
    ./dev/lint.sh script have passed
    (instructions).
  • My change reduces project test coverage and requires unit tests to be added
  • I have added unit tests covering my code change
  • My change requires a change to the documentation
  • I have updated the documentation accordingly

@mayurnewase
Copy link
Contributor Author

Sorry for too many file changes.Seems like black changed lot of quotes.

@parano
Copy link
Member

parano commented Oct 6, 2020

Hi @mayurnewase - could you run make format instead of running black directly? Looks like you run black without -S option? We would want to avoid introducing those unnecessary formatting changes.

And could you look into where the conflicts are from? You may need to rebase or merge with the latest master branch.

@parano parano requested a review from yubozhao October 6, 2020 17:44
bentoml/cli/aws_ec2.py Outdated Show resolved Hide resolved
protos/deployment.proto Outdated Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Oct 7, 2020

Codecov Report

Merging #1160 into master will decrease coverage by 0.47%.
The diff coverage is 53.88%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1160      +/-   ##
==========================================
- Coverage   65.98%   65.50%   -0.48%     
==========================================
  Files         135      141       +6     
  Lines        8563     9068     +505     
==========================================
+ Hits         5650     5940     +290     
- Misses       2913     3128     +215     
Impacted Files Coverage Δ
bentoml/adapters/image_input.py 91.89% <ø> (ø)
bentoml/cli/utils.py 65.54% <ø> (-0.85%) ⬇️
bentoml/yatai/deployment/operator.py 65.62% <0.00%> (-6.79%) ⬇️
bentoml/yatai/deployment/utils.py 41.66% <ø> (-9.19%) ⬇️
bentoml/yatai/client/deployment_api.py 32.20% <8.57%> (-4.12%) ⬇️
bentoml/yatai/validator/deployment_pb_validator.py 75.67% <25.00%> (-6.15%) ⬇️
bentoml/yatai/deployment/aws_lambda/utils.py 27.56% <30.12%> (+1.45%) ⬆️
bentoml/yatai/deployment/aws_utils.py 37.89% <37.89%> (ø)
bentoml/cli/bento_service.py 64.56% <40.00%> (-5.14%) ⬇️
bentoml/yatai/deployment/aws_ec2/utils.py 41.66% <41.66%> (ø)
... and 22 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4efb41b...0fe5108. Read the comment docs.

e2e_tests/aws_ec2/utils.py Outdated Show resolved Hide resolved
protos/deployment.proto Outdated Show resolved Hide resolved
@parano
Copy link
Member

parano commented Nov 11, 2020

Hi @mayurnewase - thank you again for this massive contribution! I really appreciate your effort in refactoring the code, improving code quality in related code path, adding end-to-end tests, and writing up documentation. Great work!

I've done some more testing on my end and everything looks good, I will mark it as a beta feature in the next release note and ask folks to try it out and give feedback. Merging now!

@parano parano merged commit d77f80b into bentoml:master Nov 11, 2020
aarnphm pushed a commit to aarnphm/BentoML that referenced this pull request Jul 29, 2022
* proto deploymentSpce remaining

* cli

* fixed

* complete functional logic

* complete functional logic

* remaining: add info in deployment spec,and use it to delete,update stacks/buckets

* 3 tests failing for aws_lambda deployment and ec2_deployment tests remaining

* formatted

* Delete deploy.sh

* Delete sample_template.yaml

* Delete startup.sh

* optional params for containerize

* existing tests fixed

* update,list,get apis complete

* quotes fixed

* quotes fixwed

* fixed quotes

* more options for deployment

* separate containerize function for cli and fixed quotes

* fixed quotes

* error handling

* initial tests added

* lambda tests imports fixed

* tests complete

* linted

* bug fix

* tests fixed

* formatted

* added spinner

* linted

* logging

* lint

* Update image_input.py

* default options in update

* fixed lambda test

* print removed

* more tests

* bug fixes

* test fixes

* spelling fixes

* Remove bucket on delete deployment
Show instance details on describe deployment command
bug fixes

* full endpoints in describe output

* end to end tests added

* bug fix

* static load balancer

* load balancer complete

* load balancer and end to end tests complete

* bug fix

* same bucket,pb validate,state from target health

* spelling fixed

* tests fixed

* bug fixed

* more spelling fixes

* bug fix

* deployment doc added

* spelling fix

* fixed target group without initial instance

* cleanups

* lint

* lint

* cleanup

* bug fix

* doc and lint fix

* added ec2 in ignore spelling list

* added ec in ignore spelling list

* Fixed docs,added inline comments for e2e tests

* Lint fix

* lint fix

* changed capacity to size

* Used defined elb name

* formatted

* tests fixed

* size to desired capacity

* fix

* added script to create iam user for deployments

* policy name fixed

* added permissions in doc

* spellings ignored

* permissions added in deployment doc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants