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

Java: split to a maven package per CDK package #111

Closed
eladb opened this issue Jun 17, 2018 · 1 comment · Fixed by #468
Closed

Java: split to a maven package per CDK package #111

eladb opened this issue Jun 17, 2018 · 1 comment · Fixed by #468
Assignees

Comments

@eladb
Copy link
Contributor

eladb commented Jun 17, 2018

At the moment, we produce one big maven module com.amazon.aws/aws-cdk which contains the entire CDK (all public modules in this repository). We would like to vend multiple maven packages so that each CDK module can evolve independently. This is especially important to not require major version bumps of everything if only one module had a breaking change.

@RomainMuller RomainMuller self-assigned this Jul 12, 2018
@eladb
Copy link
Contributor Author

eladb commented Jul 12, 2018

Related to aws/jsii#73

eladb pushed a commit that referenced this issue Aug 1, 2018
Setup a "package" npm script in all modules (via pkglint) to perform
packaging for the module:

If this is a jsii module, jsii-pacmak is invoked, which now generates
and builds the module for all target languages. Output goes to `dist/npm`,
`dist/java` and `dist/dotnet`.

If this is not a jsii module, we invoke 'npm pack' and move the tarball
to `dist/npm` (so it looks like the jsii output).

aws-cdk-docs dist/ directory modified to only contain a `docs/` output
(staging moved out).

Private modules don't have a "package" script.

Updated pack.sh to simply call "lerna run package", which will result
in "dist/" directories with artifacts throughput the repo.

Now, we merge all dist/ directories into "./pack/" and bundle-beta.sh
will use it as the base for the distribution zip file (implemented
in `pack-collect.sh`)

The distribution zip file still supports y-npm based installation, but
it's structure is now:


    aws-cdk-${version}.zip
    │
    ├─ bin
    ├─ node_modules
    ├─ y
    │  └─ npm - y-npm repository for local installs (duplicate tarballs)
    │
    ├─ docs   - rendered docsite
    ├─ npm    - npm tarballs
    ├─ dotnet - nuget packages
    ├─ java   - maven repository
    │
    └─ .version


Fixes #111
@eladb eladb closed this as completed in #468 Aug 2, 2018
eladb pushed a commit that referenced this issue Aug 2, 2018
Setup a "package" npm script in all modules (via pkglint) to perform
packaging for the module:

If this is a jsii module, jsii-pacmak is invoked, which now generates
and builds the module for all target languages. Output goes to `dist/npm`,
`dist/java` and `dist/dotnet`.

If this is not a jsii module, we invoke 'npm pack' and move the tarball
to `dist/npm` (so it looks like the jsii output).

aws-cdk-docs dist/ directory modified to only contain a `docs/` output
(staging moved out).

Private modules don't have a "package" script.

Updated pack.sh to simply call "lerna run package", which will result
in "dist/" directories with artifacts throughput the repo.

Now, we merge all dist/ directories into "./pack/" and bundle-beta.sh
will use it as the base for the distribution zip file (implemented
in `pack-collect.sh`)

The distribution zip file still supports y-npm based installation, but
it's structure is now:


    aws-cdk-${version}.zip
    │
    ├─ bin
    ├─ node_modules
    ├─ y
    │  └─ npm - y-npm repository for local installs (duplicate tarballs)
    │
    ├─ docs   - rendered docsite
    ├─ npm    - npm tarballs
    ├─ dotnet - nuget packages
    ├─ java   - maven repository
    │
    └─ .version


Fixes #111

Also:
* Don't build java example for now, we need to turn it into an integration test.
* Bundle the jsii java runtime w/ other java packages
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 a pull request may close this issue.

2 participants