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

refactor(ecs): stop using deprecated methods and remove them #2947

Merged
merged 3 commits into from
Jun 21, 2019
Merged

refactor(ecs): stop using deprecated methods and remove them #2947

merged 3 commits into from
Jun 21, 2019

Conversation

hencrice
Copy link
Contributor

@hencrice hencrice commented Jun 20, 2019

The deprecated methods are: placeOnMemberOf(), placeSpreadAcross(), placePackedBy(), placeRandomly().

Closes #2946.


Pull Request Checklist

  • Testing
    • Unit test added (prefer not to modify an existing test, otherwise, it's probably a breaking change)
    • CLI change?: coordinate update of integration tests with team
    • cdk-init template change?: coordinated update of integration tests with team
  • Docs
    • jsdocs: All public APIs documented
    • README: README and/or documentation topic updated
    • Design: For significant features, design document added to design folder
  • Title and Description
    • Change type: title prefixed with fix, feat and module name in parens, which will appear in changelog
    • Title: use lower-case and doesn't end with a period
    • Breaking?: last paragraph: "BREAKING CHANGE: <describe what changed + link for details>"
    • Issues: Indicate issues fixed via: "Fixes #xxx" or "Closes #xxx"
  • [N/A] Sensitive Modules (requires 2 PR approvers)
    • IAM Policy Document (in @aws-cdk/aws-iam)
    • EC2 Security Groups and ACLs (in @aws-cdk/aws-ec2)
    • Grant APIs (only if not based on official documentation with a reference)

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license.

The deprecated methods are: `placeOnMemberOf()`, `placeSpreadAcross()`, `placePackedBy()`, `placeRandomly()`. This closes #2946.
@hencrice hencrice requested review from SoManyHs and a team as code owners June 20, 2019 01:12
@hencrice
Copy link
Contributor Author

hencrice commented Jun 20, 2019

@rix0rrr I think master is broken(?). I ran into the following error on both master and my own fork:

lerna info run Ran npm script 'build' in '@aws-cdk/aws-iam' in 5.4s:

> @aws-cdk/[email protected] build /workplace/yenlinc/aws-cdk/packages/@aws-cdk/aws-iam
> cdk-build

lerna ERR! npm run build exited 1 in '@aws-cdk/aws-ssm'
lerna ERR! npm run build stdout:

> @aws-cdk/[email protected] build /workplace/yenlinc/aws-cdk/packages/@aws-cdk/aws-ssm
> cdk-build


lerna ERR! npm run build stderr:
Error: Error: Unable to locate module: @aws-cdk/cx-api/.jsii
    at _tryResolve (/workplace/yenlinc/aws-cdk/tools/cdk-build-tools/node_modules/jsii/lib/project-info.js:168:15)
    at _loadDependencies (/workplace/yenlinc/aws-cdk/tools/cdk-build-tools/node_modules/jsii/lib/project-info.js:122:21)
    at Object.loadProjectInfo (/workplace/yenlinc/aws-cdk/tools/cdk-build-tools/node_modules/jsii/lib/project-info.js:59:32)
    at /workplace/yenlinc/aws-cdk/tools/cdk-build-tools/node_modules/jsii/bin/jsii.js:31:46
    at Object.<anonymous> (/workplace/yenlinc/aws-cdk/tools/cdk-build-tools/node_modules/jsii/bin/jsii.js:38:3)
    at Module._compile (internal/modules/cjs/loader.js:774:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:785:10)
    at Module.load (internal/modules/cjs/loader.js:641:32)
    at Function.Module._load (internal/modules/cjs/loader.js:556:12)
    at Module.require (internal/modules/cjs/loader.js:681:19)
Error: /workplace/yenlinc/aws-cdk/tools/cdk-build-tools/node_modules/jsii/bin/jsii --project-references exited with error code 255
Build failed. Total time (0.7s) | /workplace/yenlinc/aws-cdk/tools/cdk-build-tools/node_modules/jsii/bin/jsii (0.4s) | cfn2ts (0.2s)
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @aws-cdk/[email protected] build: `cdk-build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @aws-cdk/[email protected] build script.

@hencrice
Copy link
Contributor Author

c5e43e2#diff-7a15a977f3f5e042a3d8db8f32830fb3 is the last working commit where ../../../scripts/buildup passed when executed from aws-cdk/packages/@aws-cdk/aws-ssm

@hencrice
Copy link
Contributor Author

@pkandasamy91

@hencrice
Copy link
Contributor Author

After consulting Parideep, I realized that when the CDK core is changed, running ../../../script/buildup is insufficient. Need to rebuild the core first by running ./build.sh (at the root of the repo)

Copy link
Contributor

@piradeepk piradeepk left a comment

Choose a reason for hiding this comment

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

LGTM! @eladb @rix0rrr please merge.

@eladb eladb merged commit 343a9e8 into aws:master Jun 21, 2019
@hencrice hencrice deleted the stop-using-deprecated-methods branch June 21, 2019 17:21
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.

ecs: remove deprecated methods for ECS Placement strategies/constraints
4 participants