diff --git a/docs/versions/latest/General/Cheatsheets/abx-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/abx-plugin-arguments.md index c4ff113de..586b9094b 100644 --- a/docs/versions/latest/General/Cheatsheets/abx-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/abx-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'abx-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:abx-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:abx-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:abx-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:abx-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/actions-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/actions-plugin-arguments.md index fbc60bd43..a17d0943f 100644 --- a/docs/versions/latest/General/Cheatsheets/actions-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/actions-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'o11n-actions-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-actions-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-actions-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-actions-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-actions-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/bsc-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/bsc-plugin-arguments.md index fe6a03249..e5721a37d 100644 --- a/docs/versions/latest/General/Cheatsheets/bsc-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/bsc-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'bsc-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:bsc-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:bsc-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:bsc-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:bsc-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/cs-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/cs-plugin-arguments.md index ff53a5aa3..ca5f352dd 100644 --- a/docs/versions/latest/General/Cheatsheets/cs-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/cs-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'cs-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:cs-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:cs-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:cs-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:cs-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/polyglot-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/polyglot-plugin-arguments.md index dcfc39cd9..0c1fe81dd 100644 --- a/docs/versions/latest/General/Cheatsheets/polyglot-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/polyglot-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'o11n-polyglot-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-polyglot-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-polyglot-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-polyglot-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-polyglot-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/ssh-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/ssh-plugin-arguments.md index 9de0360bd..d2373d5c5 100644 --- a/docs/versions/latest/General/Cheatsheets/ssh-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/ssh-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'ssh-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:ssh-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:ssh-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:ssh-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:ssh-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/typescript-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/typescript-plugin-arguments.md index 7d7cb629f..0919e7d00 100644 --- a/docs/versions/latest/General/Cheatsheets/typescript-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/typescript-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'o11n-typescript-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-typescript-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-typescript-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-typescript-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-typescript-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/vcd-ng-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/vcd-ng-plugin-arguments.md index d9640e860..41ad3080d 100644 --- a/docs/versions/latest/General/Cheatsheets/vcd-ng-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/vcd-ng-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'vcd-ng-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vcd-ng-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vcd-ng-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vcd-ng-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vcd-ng-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/vra-ng-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/vra-ng-plugin-arguments.md index cf5cf1e01..88907816c 100644 --- a/docs/versions/latest/General/Cheatsheets/vra-ng-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/vra-ng-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'vra-ng-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vra-ng-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vra-ng-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vra-ng-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vra-ng-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/vrealize-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/vrealize-plugin-arguments.md index 212e00853..5615165c0 100644 --- a/docs/versions/latest/General/Cheatsheets/vrealize-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/vrealize-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'vrealize-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrealize-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrealize-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrealize-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrealize-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/vrli-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/vrli-plugin-arguments.md index b675c9642..0b58b5cab 100644 --- a/docs/versions/latest/General/Cheatsheets/vrli-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/vrli-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'vrli-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrli-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrli-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrli-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrli-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/vrops-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/vrops-plugin-arguments.md index c685f806e..108b6f651 100644 --- a/docs/versions/latest/General/Cheatsheets/vrops-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/vrops-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'vrops-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrops-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrops-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrops-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrops-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/General/Cheatsheets/xml-plugin-arguments.md b/docs/versions/latest/General/Cheatsheets/xml-plugin-arguments.md index b9e4017aa..fd7870b60 100644 --- a/docs/versions/latest/General/Cheatsheets/xml-plugin-arguments.md +++ b/docs/versions/latest/General/Cheatsheets/xml-plugin-arguments.md @@ -1,7 +1,7 @@ [ERROR] [ERROR] groupId: 'com.vmware.pscoe.maven.plugins' [ERROR] artifactId: 'o11n-xml-package-maven-plugin' -[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-xml-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-xml-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] version: '2.44.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-xml-package-maven-plugin:2.44.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-xml-package-maven-plugin:jar:2.44.1-SNAPSHOT [ERROR] -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. diff --git a/docs/versions/latest/Release.md b/docs/versions/latest/Release.md index b48a28592..e328b5945 100644 --- a/docs/versions/latest/Release.md +++ b/docs/versions/latest/Release.md @@ -10,83 +10,12 @@ [//]: # (Describe the breaking change AND explain how to resolve it) [//]: # (You can utilize internal links /e.g. link to the upgrade procedure, link to the improvement|deprecation that introduced this/) -### *`vrang.project.id` has been removed in favor of `vrang.project.name`* - -Moving forward, `vrang.project.id` will not be accepted as part of the configuration. Instead, use `vrang.project.name`. - -`project.name` is more flexible as it will automatically find out the `project.id`. - -### *`vrang.org.id` has been removed in favor of `vrang.org.name`* - -Moving forward, `vrang.org.id` will not be accepted as part of the configuration. Instead, use `vrang.org.name`. - -`org.name` is more flexible as it will automatically find out the `org.id`. - -### *Polyglot projects will not try to fix mistakes due to issues with the manifest* - -Before, the `polyglot.json` could be defined like this: - -```json5 -{ - "platform": { - "runtime": "nodejs", // Here, this makes sense only for `ABX` projects, but not `vro` ones, which this is, looking 5 rows down - "action": "auto", - "tags": [], - "entrypoint": "out/handler.handler" - }, - "vro": { - "module": "com.vmware.pscoe.templates.buildtoolsforvmwareariasamples", - "inputs": { - "limit": "number", - "vraEndpoint": "CompositeType(host:string,base:string):VraEndpointType" - }, - "outputType": "Array/string" - }, - "files": ["%out", "!**/package.json", "!**/polyglot.json", "!**/tsconfig.json"] -} -``` -That would result the build tools to compile this correctly and default to using `node:12`. - -Now, however, you have to define the `runtime` correctly as `node:12` if you want this to work. - -This applies for automatic fixes for `vro` and `abx` types. - -### *Policy Templates's `templateVersion` is now mandatory* - -`@PolicyTemplate` decorators now **must** specify a `templateVersion`. - -The possible options are `v1` and `v2` (you can also see this in the definitions). - -```ts -@PolicyTemplate({ - name: "Sample Policy", - path: "MyOrg/MyProject", - templateVersion: "v2", // This is now mandatory - variables: { /* ... */ }, - elements: { /* ... */} -}) -``` - ## Deprecations [//]: # (### *Deprecation*) [//]: # (Explain what is deprecated and suggest alternatives) -### *Deprecation of vRA 7 archetype* - -The vRA 7 Archetype and all related plugins/mojos/code are removed due to the fact that vRA 7 is Out Of Support. - -The suggested alternative is to use version 2.44.0 of the toolchain. That is the last version that supports vRA7 - -### *Deprecation of vRA 7 types* - -The `o11n-plugin-vcac` and `o11n-plugin-vcacafe` types are also removed. - -### *Deprecated Regional Content* - -The Regional content supported in previous versions of Build Tools for Aria has been removed. Unfortunately that part of the build tools never functioned the way we wanted it to, and managing the "infrastructure" tab in Assembler is no longer something we want to do as it contradicts the principles behind the `vra-ng` archetype. - -As an alternative, we suggest you use some sort of install workflow to manage them. +[//]: # (Features -> New Functionality) ## Features @@ -95,32 +24,10 @@ As an alternative, we suggest you use some sort of install workflow to manage th [//]: # (Optional But higlhy recommended Specify *NONE* if missing) [//]: # (#### Relevant Documentation:) -### *Added a health check script* - -To check if the dependencies are met, you can now run: - -```sh -curl -o- https://raw.githubusercontent.com/vmware/build-tools-for-vmware-aria/main/health.sh | bash -``` - -Works for Linux,Mac and Windows with Git Bash - [//]: # (Improvements -> Bugfixes/hotfixes or general improvements) - ## Improvements -### *Flexible unit tests setup* -It is now possible to configure how the unit tests are being bootstrapped and executed. -#### Previous Behavior -Unit tests were locked to a specific version of Jasmine. -#### New Behavior -There are two out-of-the-box options for test frameworks: Jasmine and Jest. -The default behavior will be fully backwards compatible. Optionally the user is able to specify which -framework should be used as well as its version or even completely override how the unit tests are being ran. -#### Relevant Documentation -More in-depth documentation is available in the [vrotest](./../../../typescript/vrotest/) component. - [//]: # (### *Improvement Name* ) [//]: # (Talk ONLY regarding the improvement) [//]: # (Optional But higlhy recommended) @@ -134,40 +41,4 @@ More in-depth documentation is available in the [vrotest](./../../../typescript/ ## Upgrade procedure -### *Polyglot projects using `nodejs` as a runtime for a `vro` project need to be migrated* - -1. Look for all of your polyglot projects made for `vro`. -2. Look for `nodejs` runtimes and change them to `node:12`. -3. Look for `powershell` runtimes and change them to `powercli:11-powershell-6.2` -4. Look for `python` runtimes and change them to `python:3.7` - -Note: - -You don't need to migrate projects if they are `abx` based. `nodejs` is the correct value for `abx` projects. - -### *Polyglot projects using vro runtimes for abx projects need to be migrated* - -1. Take a look at the documentation for the available runtimes -2. Correctly set the `vro` runtime you want to use instead of the `abx` -3. `nodejs`, `powershell` or `python` only - -### *Migrate PolicyTemplates* - -Search your projects that use `@PolicyTemplate` decorator. The `templateVersion` property is now required. Check on top for possible values - -### *Migrate away from `vrang.project.id`* - -1. Open your `settings.xml`. -2. Search for `vrang.project.id`. -3. If found, replace it with the name of the project as seen in Aria - -### *Migrate away from `vrang.org.id`* - -1. Open your `settings.xml`. -2. Search for `vrang.org.id`. -3. If found, replace it with the name of the organization as seen in Aria - -### *Modify your `environment.properties` files if in use (installer)* - -1. If you have `environment.properties` that rely on `vrang_project_id`, they should be modified to use the `vrang_project_name` -2. If you have `environment.properties` that rely on `vrang_org_id`, they should be modified to use the `vrang_org_name` +[//]: # (Explain in details if something needs to be done) diff --git a/docs/versions/v3.0.0/Components/Archetypes/General/Goals/Vrealize Clean.md b/docs/versions/v3.0.0/Components/Archetypes/General/Goals/Vrealize Clean.md new file mode 100644 index 000000000..e44d6aec2 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/General/Goals/Vrealize Clean.md @@ -0,0 +1,36 @@ +# Vrealize Clean + +`vrealize:clean` is a goal used to clean up archetype packages on a given environment. + +## Overview + +`vrealize:clean` gives us a lot of flexibility in what is going to be deleted. You can find more about the different options in the sections below. + +## Table Of Contents + +1. [Archetype Support for vrealize:clean](#archetype-support-for-vrealizeclean) +2. [Usage](#usage) + +### Archetype Support for vrealize:clean + +| Archetype | Supported | Comment | +|-----------|-----------|--------------------------------------------------------------------| +| vra | Yes | - | +| vro | Yes | - | +| vcd | Partial | It does not support dryRunning | +| abx | No | Not implemented | +| vrops | No | Not implemented | +| vra-ng | Partial | Does not support dryRunning and does not work for regional content | +| vrli | No | vRLI does not provide native package support | +| cs | No | Code Stream Services does not provide native support for packages | + +### Usage + +```bash +mvn vrealize:clean -DincludeDependencies=true -DcleanUpOldVersions=true -DcleanUpLastVersion=false -Ddryrun=true -P${PROFILE} +``` + +- includeDependencies - a flag depicting if dependencies should also be deleted +- cleanUpOldVersions - a flag depicting if old versions of the package (and dependencies in case of includeDependencies) should be deleted +- cleanUpLastVersion - a flag depicting if the latest version should also be deleted before importing +- dryrun - Dryrun or not diff --git a/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/New Project.md b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/New Project.md new file mode 100644 index 000000000..ab4b5dea5 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/New Project.md @@ -0,0 +1,32 @@ +# New Project + +## Table Of Contents + +- [Generate A New Project](#generate-a-new-project) + +### Generate A New Project + +- Replace `archetypeVersion` with the latest toolchain version +- Specify `type` to be either `abx` (vRA ABX Actions) or `vro` (vRO Polyglot Actions). + +```bash +#vRO: +mvn archetype:generate \ + -DinteractiveMode=false \ + -DarchetypeGroupId=com.vmware.pscoe.polyglot.archetypes \ + -DarchetypeArtifactId=package-polyglot-archetype \ + -DarchetypeVersion={LATEST_VERSION} \ + -DgroupId=com.vmware.pscoe \ + -DartifactId=testvronew \ + -Dtype=vro + +#ABX: +mvn archetype:generate \ + -DinteractiveMode=false \ + -DarchetypeGroupId=com.vmware.pscoe.polyglot.archetypes \ + -DarchetypeArtifactId=package-polyglot-archetype \ + -DarchetypeVersion={LATEST_VERSION} \ + -DgroupId=com.vmware.pscoe \ + -DartifactId=testabxnew \ + -Dtype=abx +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Project Structure.md b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Project Structure.md new file mode 100644 index 000000000..b90a4f27f --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Project Structure.md @@ -0,0 +1,120 @@ +# Project Structure + +## Overview + +The polyglot archetype supports multiple actions in the src folder. Each has it's own structure depending on the type of the package. + +## Table Of Contents + +- [General](#general) +- [Templates](#templates) + - [NodeJS](#nodejs) + - [Python](#python) + - [Powershell](#powershell) + +### General + +- `polyglot.json` - marks a folder as a polyglot package. Contains information about the package. + - If the `platform.action` is set to `auto` the name of the folder will be used as the package name. + - If the `platform.protocolType` is set to one of possible values `'Ssl3' | 'Tls' | 'Tls11' | 'Tls12' | 'Tls13'` all external modules(Added through Import-Module in the code) will be downloaded using the selected encryption protcol, otherwise the system default is used. + +#### `polyglot.json` + +The `polyglot.json` file is used to define the package. It is a JSON file with the following properties: + +```json5 +{ + "platform": { + "action": "auto", // The name of the action, if set to auto, the folder name will be used, otherwise the value will be used + "entrypoint": "handler.handler", // The entrypoint for the action. First part is the file name, second part is the function name + "runtime": "python", // The runtime for the action. Check below for possible values + "tags": [], // Tags for the action... TBD + "memoryLimitMb": 64, // The memory limit for the action + "timeoutSec": 60, // The timeout for the action + "protocolType": "Tls12", // Use to download external modules using a specific protocol. Check below for possible values + } + // If VRO + "vro": { + "module": "${groupId}", + "inputs": { // These are the inputs and their type + "limit": "number", + "vraEndpoint": "CompositeType(host:string,base:string):VraEndpointType" + }, + "outputType": "Array/string" + }, + // If ABX + "abx": { + "inputs": { + "someKey": "someValue" + // ... + } + }, + "files": ["%out", "!**/package.json", "!**/polyglot.json", "!**/requirements.txt"] // Needed for the build, don't edit +} +``` + +##### `runtime` + +###### VRO + +- `node:12` +- `node:14` +- `node:18` +- `node:20` +- `powercli:11-powershell-6.2` +- `powercli:12-powershell-7.1` +- `powercli:12-powershell-7.4` +- `powercli:13-powershell-7.4` +- `powershell:7.4` +- `python:3.7` +- `python:3.10` + +###### ABX + +- `nodejs` +- `powershell` +- `python` + +##### `protocolType` + +- `Ssl3` +- `Tls` +- `Tls11` +- `Tls12` +- `Tls13` + +### Templates + +There are three templates: + +- src/template-nodejs ([NodeJs](#nodejs)) +- src/template-powershell ([Powershell](#powershell)) +- src/template-python ([Python](#python)) + +Note: you do not need to delete template folders. Any folder starting with `template-` is ignored. + +#### NodeJS + +- `handler.ts` - holds all the logic for the action +- `tsconfig.json` - used by typescript to compile the code during `mvn package`, since rootDirs and srcDirs are dynamic, there are placeholders in this file. **do not modify** + +> Dependencies +> +> NodeJS' dependencies are defined in the `package.json` file in the `dependencies` property. Specify only dependencies to your code, there are no mandatory dependencies as well as no default ones. + +#### Python + +- `handler.py` - holds all the logic for the action +- `requirements.txt` - holds dependency information e.g. requirements.txt: + + ```python + requests==2.23.0 + ``` + +> Dependencies +> +> These follow the standard python `requirements.txt` structure. No default or mandatory dependencies. [More Info](https://learnpython.com/blog/python-requirements-file/) + +#### Powershell + +- `handler.ps1` - holds all the logic for the action diff --git a/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Troubleshooting.md b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Troubleshooting.md new file mode 100644 index 000000000..0a4a1971c --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Troubleshooting.md @@ -0,0 +1 @@ +[//]: # (Finish with some troubleshooting tips, when any error are encountered and fixed for future issues) diff --git a/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Usage.md b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Usage.md new file mode 100644 index 000000000..aec52d8ab --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/General/Usage.md @@ -0,0 +1,15 @@ +# Usage + +## Overview + +Polyglot archetype just like any other archetype utilizes the `vrealize:push` to package and deploy the artifacts. + +## Table Of Contents + +1. [Command](#command) + +### Command + +```bash +mvn clean package vrealize:push -Penvironment_profile +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/Polyglot/README.md b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/README.md new file mode 100644 index 000000000..474fdd5b0 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/Polyglot/README.md @@ -0,0 +1,15 @@ +# Polyglot + +The polyglot archetype is an archetype that allows you to push "polyglot" actions to vRO and vRA (like powershell, python, nodejs). + +## Overview + +The polyglot archetype is used to push multiple of these actions at the same time in a single package. + +## Navigation + +- Getting Started + - [Project Structure](./General/Project%20Structure.md) + - [New Project](./General/New%20Project.md) +- [Usage](./General/Usage.md) +- [Troubleshooting](./General/Troubleshooting.md) diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Actions.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Actions.md new file mode 100644 index 000000000..dae3f433b --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Actions.md @@ -0,0 +1,103 @@ +# Actions + +vRO Actions, supported types, and how to use them inside the Typescript Archetype. + +## Overview + +vRO Actions can essentially be viewed as javascript modules that can be used inside workflows and other actions. This +is where classes, functions, objects, etc. are defined. + +## Table Of Contents + +1. [Pushing Actions](#pushing-actions) +2. [Action Parameters](#action-parameters) +3. [Action Return Type](#action-return-type) +4. [Examples](#examples) + +### Pushing Actions + +Actions are pushed when running `mvn clean package vrealize:push`. + +#### Limitations + +- Only actions that are under `PROJECT_ROOT/src` will be pushed to vRO. +- Only actions that end in `.js` and `.ts` will be pushed. +- Action name can contain only letters, numbers and the symbols "_" and "$". +- Action name cannot start with a number. + +### Action Parameters + +Action Parameters are **NOT** mandatory, but they will be taken into consideration if passed. + +JSDoc Parameters in vRO native actions are used when you want to define the parameter type. It will be taken into consideration, otherwise it will be Any. You must follow the way parameter types are defined in vRO. The argument name must match the regex: `^[a-zA-Z0-9_$]+$`. If it does not match, the parameter is ignored + +If the action is a typescript one, then typescript hints will be used instead. + +#### Action parameter description + +You can define descriptions per parameter by adding a `-`. + +Example: + +```javascript +/** + * @param {Any} arugment - This is the description + */ +``` + +#### Action parameters with properties + +You can define action parameters with properties like: + +```javascript +/** + * @param {Any} args + * @param {string} args.url + */ +(function (args) { + return args.url; +}) +``` + +In this example, the args.url will be ignored. + +[JSDoc documentation](https://jsdoc.app/tags-param.html#parameters-with-properties) + +#### Unsupported Parameters + +- Optional `@param {string} [optional=123]` or `@param {string=} optional` +- Union type `@param {(string|string[])} union` +- Repeated parameter `@param {...number} num` + +### Action Return Type + +Action return type is **NOT** mandatory, but it will be taken into consideration if passed. + +You can add `@return` or `@returns` to define the return type of the action, or alternatively if the action is typescript, +the typescript hints will be used. + +### Examples + +#### Native vRO Action + +```javascript +/** + * @param {Any} args + * @param {number} test + */ +(function (args, test, willBeAnyType) { + return args.url; +}); + +//...... + +// Will be transpiled to +return args.url; +``` + +In this example: + +- Param `args` of type Any +- Param `test` of type number +- Param `willBeAnyType` of type Any +- Return type: Any diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Config.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Config.md new file mode 100644 index 000000000..3770216ab --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Config.md @@ -0,0 +1,152 @@ +# Config elements + +vRO Configuration Elements and how to define them in a typescript project + +## Overview + +Configuration Elements are vRO constructs that allow you to store configuration data. Build Tools for VMware Aria supports a few ways of defining configuration elements as well as different types of values. + +## Table Of Contents + +- [Pushing Configuration Values](#pushing-configuration-values) +- [Secure Strings](#secure-strings) +- [CompositeTypes](#compositetypes) +- [Examples](#examples) + +### Pushing Configuration Values + +When doing `mvn clean package vrealize:push` you need to include some extra arguments if you want to push configuration values + +- `-Dvro.packageImportConfigurationAttributeValues=true` - Pushes all configuration values besides SecureStrings. +- `-Dvro.packageImportConfigSecureStringAttributeValues=true` - Pushes all Secure String configuration values. + +### Secure Strings + +Up to version 2.23.0 + +Secure strings in configuration elements are defined as shown below: + +```ts +import { Configuration } from "vrotsc-annotations"; + +@Configuration({ + name: "Test", + path: "PSCoE/Test", + attributes: { + password: + { + type: "SecureString", + value: "36BJ62U35V34T31R64I31H38Q39L2DH62K37Q63T61M2DK34O62R66K35U2DY38Y32S66Q35G2DQ63K66U64Z62X33Q37T31R34Q37W31Z66M31K", + description: "some number" + } + } +}) +export class Test { + password: SecureString; +} +``` + +When pushing them to vRO, you have to add `-Dvro.packageImportConfigSecureStringAttributeValues=true` to indicate to the Build Tools for VMware Aria that the SecureStrings should be imported as well. + +The value is encoded, and the best way to know what to set there would be to manually add it to vRO, then fetch it using the VSCode vRDT /vRealize Developer tools/ plugin by clicking on the extension in the sidebar and navigating to it. After you find it you will be able to extract the value from the retrieved `xml` and put it here. + +### CompositeTypes + +Currently, composite types are implemented for both vRO7 and vRO8. vRO8 is compatible with the old vRO7 way of importing composite types, so that format is used to import composite types in both systems. + +Composite types conform to these constraints: + +```ts +type PossibleAttributeValues = string | boolean | number; + +type AttributeValue = PossibleAttributeValues | PossibleAttributeValues[]; +``` + +Meaning that a Composite type can be a string, boolean, number or an array of each. + +### Examples + +Example Typescript Configuration Element: + +```ts +import { Configuration } from "vrotsc-annotations"; + +@Configuration({ + name: "GeneralConfig", + path: "PSCoE/MyProject", + attributes: { + composite: { + type: "CompositeType(field1:number,field2:boolean,field3:string,field4:Array/string):ITest", + value: { + field1: 1, + field2: true, + field3: '2222', + field4: ['test',"test2", `test3`] + }, + description: "A composite value with all the basics" + }, + numericAttr: { + type: "number", + value: 123, + description: "Represents a numeric variable" + }, + stringAttr: { + type: "string", + value: "Some String", + description: "A string variable" + }, + stringArray: { + type: "Array/string", + value: ["first", "second"], + description: "This is an array of strings" + }, + host: { + type: "REST:RESTHost", + description: "A RESTHost without any value ( placeholder )" + // Does not support values + }, + vm: { + type: "VC:VirtualMachine", + description: "A VirtualMachine without any value ( placeholder )" + // Does not support values + }, + password: { + type: "SecureString", + value: "36BJ62U35V34T31R64I31H38Q39L2DH62K37Q63T61M2DK34O62R66K35U2DY38Y32S66Q35G2DQ63K66U64Z62X33Q37T31R34Q37W31Z66M31K", + description: "some number" + } + } +}) +export class CompositeValuesTest { +} +``` + +Example YAML configuration element + +```yaml +name: CompositeConfigYaml +path: PSCoE/MyProject +attributes: + field1: + type: CompositeType(field1:number,field2:boolean,field3:string,field4:Array/string):ITest + description: "A composite type with primitives" + value: + field1: 1 + field2: true + field3: Test + field4: + - test1 + - test2 + - test3 + field2: + type: number + value: 123 + description: "Some number" + field3: + type: boolean + value: true + description: "Some boolean" + field4: + type: string + description: "Some string" +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Policy.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Policy.md new file mode 100644 index 000000000..9ad70438d --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Policy.md @@ -0,0 +1,328 @@ +# Policies + +vRO Policies and how to define them in Aria Orchestrator + +## Overview + +Aria Orchestrator supports creating Policies with different elements and variables. + +## Table of Contents + +1. [Policy Template Versioning](#policy-template-versioning) +2. [Example Policy](#example-policy) +3. [Naming Convention](#naming-convention) +4. [Creating Variables in Policy](#creating-a-variable-in-policy) +5. [Creating Elements to a Policy](#creating-elements-to-a-policy) + +### Policy Template Versioning + +Policy template now has two versions for backward compatability. Template versions can be changed using the **templateVersion** attribute. Use v2 for full support of creating Policy with variables and multiple elements. + +**NOTE:** templateVersion attribute is optional. if not provided, templateVersion will be considered as v1 by default. + +```ts +import { PolicyTemplate } from "vrotsc-annotations"; + +@PolicyTemplate({ + name: "Sample Policy", + path: "MyOrg/MyProject", + description: "Some Description", + templateVersion: "v2", // or v1 +}) +``` + +### Example Policy + +A Example typescript policy with all posible configurations for Policy Template Version 2 (v2). + +#### Version 1 + +```ts +import { PolicyTemplate } from "vrotsc-annotations"; + +@PolicyTemplate({ + name: "Policy Template Amqp", + path: "MyOrg/MyProject", + type: "AMQP:Subscription", + templateVersion: "v1" +}) +export class PolicyTemplateAmqp { + onMessage(self: AMQPSubscription, event: any) { + System.log("onMessage"); + } +} +``` + +#### Version 2 + +```ts +import { PolicyTemplate } from "vrotsc-annotations"; + +@PolicyTemplate({ + name: "Sample Policy", + path: "MyOrg/MyProject", + description: "Some Description", + templateVersion: "v2", + variables: { + sample: { + type: "string", + value: "a string value with type mentioned", + description: "A variable created with type and description" + }, + config: { + type: "Properties", + configId: "8e2d3ba0-4e2c-4d4c-ad82-76de4967bf9f", + configKey: "props", + description: "A variable created with configuration binding" + }, + sample2: "a direct string value" + }, + elements: { + ElementOne: { + type: "AMQP:Subscription", + events: { + onMessage: "onMessage" + } + }, + ElementTwo: { + type: "SNMP:SnmpDevice", + events: { + OnTrap: { + workflowId: "56652d1b-f797-3e1c-a108-7db9ddfb1f42", + bindings: { + workflowInputOne: { + type: "string", + variable: "sample" + } + } + } + } + } + ElementThree: { + type: "Periodic Event", + schedule: { + periode: "every-minutes", + when: "13,15", + timezone: "Asia/Calcutta" + } + } + } +}) +``` + +### Naming Convention + +Naming convention for creating variables, elements with different types of elements and events. + +```ts +import { PolicyTemplate } from "vrotsc-annotations"; + +@PolicyTemplate({ + name: "Sample Policy", + path: "MyOrg/MyProject", + description: "Some Description", + templateVersion: "v2", // Policy Template Version: v1 or v2 + variables: { + sample: { // variable name + type: "string", // variable type + value: "a string value with type mentioned", // variable value + description: "A variable created with type and description" // variable description + }, + config: { // variable name + type: "Properties", // variable type + configId: "8e2d3ba0-4e2c-4d4c-ad82-76de4967bf9f", // configuration element ID + configKey: "props", // configuration element key + description: "A variable created with configuration binding" // variable description + }, + sample2: "a direct string value" // directly assiged string value to a variable + }, + elements: { + // Policy with script for event + ElementOne: { // Policy element name + type: "AMQP:Subscription", // policy element type + events: { // list of events for element + onMessage: "onMessage" // event : method name in class + } + }, + // Policy with workflow execution + ElementTwo: { // Policy element name + type: "SNMP:SnmpDevice", // Policy element type + events: { // list of events for element + OnTrap: { // event name + workflowId: "56652d1b-f797-3e1c-a108-7db9ddfb1f42", // workflow id to execute + bindings: { // workflow input bindings + workflowInputOne: { // workflow input name + type: "string", // workflow input type + variable: "sample" // variable name for workflow input + } + } + } + } + }, + // Policy with Periodic Event + ElementThree: { // Policy element name + type: "Periodic Event", // Policy element type + schedule: { // Periodic event schedule - mandatory for periodic event + periode: "every-minutes", // period of schedule + when: "13,15", // time for schedule, can be multiple + timezone: "Asia/Calcutta" // timezone for schedule + } + } + } +}) +``` + +### Creating a Variable in Policy + +Variables can be created in a policy by adding them under **variables** attribute as shown in the example. + +#### Creating a String variable + +String variables can be added by directly assigning values to the them. + +```ts +variables: { + sample2: "a direct string value" +} +``` + +#### Creating Variables with other data types + +Other data type variables can be added by providing the additional information to them. + +```ts +variables: { + sample: { + type: "boolean", + value: true, + description: "A variable created with type and description" + }, + sample2:{ + type: "number", + value: 2, + description: "A Numeric value" + } +} +``` + +#### Creating Variables with Configuration binding + +Variables can be binded to configurations by providing configuration ID and key. + +```ts +variables: { + config: { + type: "Properties", + configId: "8e2d3ba0-4e2c-4d4c-ad82-76de4967bf9f", + configKey: "props", + description: "A variable created with configuration binding" + } +} +``` + +**Note:** Configuration binding will be considered if both value and configuration ID are provided to a variable. + +### Creating Elements to a Policy + +Elements can be created in a policy by adding them under **elements** attribute as shown in example + +#### Supported Element types + +- AMQP:Subscription +- MQTT:Subscription +- SNMP:SnmpDevice +- SNMP:TrapHost +- Periodic Event + +#### Creating a Periodic Event Element with defined event Method + +Periodic Event element can be added by providing the list of events and schedules as below. Schedules are mandatory for Periodic Event type elements + +```ts +elements: { + PeriodicEvent: { + type: "Periodic Event", + events:{ + OnExecute: "onExecuteEvent" + }, + schedule: { + periode: "every-minutes", + when: "13,15", + timezone: "Asia/Calcutta" + } + } +} + +export class SamplePolicy { + onExecuteEvent(self: AMQPSubscription, event: any) { + let message = self.retrieveMessage(event); + System.log(`Received message ${message.bodyAsText}`); + } +} +``` + +#### Creating a Periodic Event Element with bound event Method + +Events can either be a method defined in the typescipt Policy or can be bound to a workflow. + +```ts +elements: { + PeriodicEvent: { + type: "Periodic Event", + events:{ + OnExecute: { + workflowId: "56652d1b-f797-3e1c-a108-7db9ddfb1f42", + bindings: { + workflowInputOne: { + type: "string", + variable: "sample" + } + } + } + }, + schedule: { + periode: "every-minutes", + when: "13,15", + timezone: "Asia/Calcutta" + } + } +} +``` + +From the above example, the workflow ID and its input bindings are provided. The inputs are binded to variables created in the policy. + +#### Creating Other Element Types + +Other supported element types can be as below. Events can be a method defined in the policy or can be binded to a workflow. + +```ts +elements: { + ElementOne: { + type: "AMQP:Subscription", + events: { + onMessage: "onMessage" + } + }, + ElementTwo: { + type: "SNMP:SnmpDevice", + events: { + OnTrap: { + workflowId: "56652d1b-f797-3e1c-a108-7db9ddfb1f42", + bindings: { + sourceGroup: { + type: "string", + variable: "sample" + } + } + } + } + } +} + +export class SamplePolicy { + onMessage(self: AMQPSubscription, event: any) { + let message = self.retrieveMessage(event); + System.log(`Received message ${message.bodyAsText}`); + } +} +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Workflows.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Workflows.md new file mode 100644 index 000000000..a2b9ff842 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/Workflows.md @@ -0,0 +1,613 @@ +# Workflows + +How to use Aria Orchestrator Workflows and available decorators. + +## Overview + +You can use the method decorators to define various canvas items that will be included in the workflow. + +## Table of Contents + +1. [Argument Decorators](#argument-decorators) +2. [Available Method Decorators](#available-method-decorators) + - [`@DefaultErrorHandler`](#defaulterrorhandler) + - [`@WorkflowEndItem`](#workflowenditem) + - [`@Item`](#item) + - [`@WaitingTimerItem`](#waitingtimeritem) + - [`@DecisionItem`](#decisionitem) + - [`@RootItem`](#rootitem) + - [`@DefaultErrorHandler`](#defaulterrorhandler) + - [`@UserInteractionWorkflowItem`](#userinteractionworkflowitem) + - [`@WorkflowEndItem`](#workflowenditem) +3. [Example Workflow](#example-workflow) + +### Argument Decorators + +- `@In` - Used to bind an input to a function. +- `@Out` - Used to bind an output to a function. +- `@Err` - Used to bind an error to a function. + +### Available Method Decorators + +#### `@DefaultErrorHandler` + +This decorator is used to specify a default error handler. It can be bound either to a workflow item component or workflow end. + +#### Supported Parameters + +- `target` - target item to be attached to the default error handler, could be one of workflow item or workflow end. +- `exceptionVariable` - Exception variable that will hold the exception data when triggered. + +In order to bind inputs and outputs, you do it with the `@In` and `@Out` decorators. This is the same way we do it for other items. + +#### Example + +```ts +import { + Workflow, + RootItem, + In, + Out, + Err, + Item, + DefaultErrorHandler, + WorkflowEndItem, +} from "vrotsc-annotations"; + +@Workflow({ + name: "Default Error Handler Workflow", + path: "VMware/PSCoE", + description: + "Default error handler workflow with error handler redirecting to a workflow item", + attributes: { + errorMessage: { + type: "string", + }, + }, +}) +export class DefaultErrorHandlerWorkflow { + @RootItem({ target: "workflowEnd" }) + public initiateWorkflow() { + System.log("Initiating workflow execution"); + } + + @Item({ + target: "end", + }) + public goToEnd() { + // NOOP + } + + @Item({ + target: "workflowEnd", + }) + public processError(@In errorMessage: string) { + System.log( + `Processing error using custom task with message '${errorMessage}'` + ); + } + + @DefaultErrorHandler({ + target: "processError", + exceptionBinding: "errorMessage", + }) + public defaultErrorHandler(@Out @Err errorMessage: string) { + // NOOP + } + + @WorkflowEndItem({ + endMode: 0, + }) + public workflowEnd(@Out @Err errorMessage: string) { + System.log(`Terminating workflow with error ${errorMessage}`); + } +} +``` + +The example above would generate the following workflow. + +[![Default Error Handler Workflow](images/Canvas_Item_Default_Error_Handler_Workflow.png)](images/Canvas_Item_Default_Error_Handler_Workflow.png) + +#### `@WorkflowEndItem` + +The decorator is used to specify a custom workflow end item. + +##### Supported Parameters + +- `endMode` - End mode of the component, could be one of 0 or 1, where 0 is exit success and 1 is error. +- `exceptionVariable` - Exception variable that will hold the exception data when triggered. +- `businessStatus` - Value of the business status in the end component. + +#### `@Item` + +This decorator is used to specify a scriptable task. + +##### Supported Parameters + +- `target` - The name of the next in line item. If this is set to `end`, it will point to the end of the workflow. If this is set to `null`, it will point to the next item or if none, the end of the wf. If this is set to a string, but it does not exist in the workflow, it will point to the end of the wf. +- `exception` - **Not implemented yet** + +#### `@WaitingTimerItem` + +This decorator is used to specify a waiting timer. + +##### Supported Parameters + +- `target` - The name of the next in line item. Same as `@Item`. This decorator expects an `@In` parameter with the name of the waiting timer. If one isn't added, the workflow will not work. + +##### Example + +```ts +import { Workflow, In, WaitingTimerItem } from "vrotsc-annotations"; + +@Workflow({ + name: "Waiting Timer Workflow", + path: "VMware/PSCoE", + description: "Waiting timer will point with target to shouldGoHere", + attributes: { + waitingTimer: { + type: "Date", + }, + }, +}) +export class WaitingTimerWorkflow { + @WaitingTimerItem({ + target: "shouldGoHere", + }) + public waitForEvent(@In date: Date) { + // NOOP + } + + public shouldGoHere() { + // NOOP + } +} +``` + +The example above would generate the following workflow. + +[![Waiting Timer Workflow](images/Waiting_Timer_Canvas_Item_Workflow.png)](images/Waiting_Timer_Canvas_Item_Workflow.png) + +#### `@DecisionItem` + +This decorator is used to specify a decision item. + +##### Supported Parameters + +- `target` - The name of the next in line item. Same as `@Item`. +- `else` - The name of the next in line item if the decision is false. If this is set to `end`, it will point to the end of the workflow. If this is set to `null`, it will point to the next item or if none, the end of the wf. If this is set to a string, but it does not exist in the workflow, it will point to the end of the wf. + +##### Example + +```ts +import { Workflow, DecisionItem } from "vrotsc-annotations"; + +@Workflow({ + name: "Decision Item Workflow", + path: "VMware/PSCoE", + description: + "decisionElement is the root, it will point with else to end and target to shouldGoHere. shouldGoHere will point to end too", + attributes: { + waitingTimer: { + type: "Date", + }, + }, +}) +export class DecisionItemWorkflow { + @DecisionItem({ + target: "shouldGoHere", + else: "end", + }) + public decisionElement(waitingTimer: Date) { + return waitingTimer !== null; + } + + // This will point to end too, but no incoming + public shouldGoHere() { + // NOOP + } +} +``` + +The example above would generate the following workflow. + +[![Decision Item Workflow](images/Decision_Item_Canvas_Item_Workflow.png)](images/Decision_Item_Canvas_Item_Workflow.png) + +#### `@WorkflowItem` + +The decorator is used to specify a workflow item that will be called. + +##### Supported Parameters + +- `target` - The name of the next in line item. Same as `@Item`. +- `linkedItem` - The ID of the workflow to call. + +In order to bind inputs and outputs, you do it with the `@In` and `@Out` decorators. This is the same way we do it for other items. + +#### `@ScheduledWorkflowItem` + +The decorator is used to specify a scheduled workflow item that will be called. + +##### Supported Parameters + +- `target` - The name of the next in line item. Same as `@Item`. +- `linkedItem` - The ID of the workflow to schedule. + +In order to bind inputs and outputs, you do it with the `@In` and `@Out` decorators. This is the same way we do it for other items. + +##### Inputs + +Special input is needed for the ScheduledWorkflowItem. + +- `workflowScheduleDate` - {Date} is required. The name **must** be `workflowScheduleDate`. If this is missing an error is thrown. We don't check if the type is `Date` but Aria Orchestrator will complain. + +##### Outputs + +Special output is needed for the ScheduledWorkflowItem. + +- `scheduledTask` - {Task} is optional. If it's missing nothing will happen, if it's added, then the name **must** be `scheduledTask`. This is the task that is scheduled. + +##### Example + +```ts +import { + Workflow, + Out, + In, + Item, + RootItem, + ScheduledWorkflowItem, +} from "vrotsc-annotations"; + +@Workflow({ + name: "Scheduled Workflow", + path: "VMware/PSCoE", + description: "Scheduling another workflow and binding values correctly", + attributes: { + workflowScheduleDate: { + type: "Date", + }, + scheduledTask: { + type: "Task", + }, + }, +}) +export class ScheduledWorkflow { + @RootItem({ target: "prepareItems" }) + public start() { + System.log("Starting workflow"); + } + + @Item({ target: "scheduleOtherWf" }) + public prepareItems(@In @Out workflowScheduleDate: Date) { + workflowScheduleDate = System.getDate("1 minute from now", null); + } + + @ScheduledWorkflowItem({ + target: "printScheduledDetails", + linkedItem: "c2c9d5c4-468e-3cde-a64a-d1de50989214", + }) + public scheduleOtherWf( + @In first: number, + @In second: number, + @In workflowScheduleDate: Date, + @Out scheduledTask: Task + ) { + // NOOP + } + + @Item({ target: "end" }) + public printScheduledDetails(@In scheduledTask: Task) { + System.log(`Scheduled task: ${scheduledTask.id}, [${scheduledTask.state}]`); + } +} +``` + +The example above would generate the following workflow. + +[![Scheduled Workflow](images/Scheduled_Workflow_Canvas_Item_Workflow.png)](images/Scheduled_Workflow_Canvas_Item_Workflow.png) + +#### `@RootItem` + +This is a meta decorator. Add this to whichever function you want to be the entry point of the workflow. + +#### `@AsyncWorkflowItem` + +##### Supported Parameters + +- `@AsyncWorkflowItem({target: "", linkedItem: "" })` + - `target` - The name of the next in line item. + - `linkedItem` - The ID of the workflow to call + +##### Outputs + +Special output is needed for the AsyncWorkflowItem. + +- `wfToken` - {WorkflowToken} is required. The name **must** be `wfToken`. If this is missing an error is thrown. We don't check if the type is `WorkflowToken` but Aria Orchestrator will complain. + +##### Inputs + +No special inputs are needed for the AsyncWorkflowItem. + +#### `@ActionItem` + +##### Supported Parameters + +- `@ActionItem({target: "", scriptModule: "" })` + - `target` - The name of the next in line item. Same as `@Item`. + - `scriptModule` - The path of the action you want to call and the action name, separated by `/`. Example: `com.vmware.pscoe.library.general/echo`. + +In order to bind inputs and outputs, you do it with the `@In` and `@Out` decorators. This is the same way we do it for other items. + +##### Outputs + +There is a requirement to have only one output, and it will be of type `ActionResult`. + +#### `@UserInteractionWorkflowItem` + +The decorator is used to specify an user interaction workflow item. + +##### Supported Parameters + +- `target` - The name of the target to that user interaction workflow item is connected to. You can specify another user interaction workflow item as a target, thus chaining multiple user interaction components. + +In order to bind inputs and outputs, you do it with the `@In` and `@Out` decorators. + +##### Inputs + +If you need to specify certain access limitation for the user interaction component you can specify them with `@In` decorators. +Those inputs are optional. + +- `security_assignees` (type `Array/LdapUser`) - Any user from this array of users will be authorized to fill in this form. +- `security_assignee_groups` (type `Array/LdapGroup`) - Any user member of any of the groups will be authorized to fill in this form. +- `security_group` (type `LdapGroup`) - Any user member of this group will be authorized to fill in this form. +- `timeout_date` (type `Date`) - If not null, this input item will wait until date and will continue workflow execution. + +Note that those parameters should match also the input parameters of the workflow. + +##### Known Limitations for the Input Parameters + +The names of the variables in the additional method decorators should be as following: + +- `security_assignees` - for the security assignees parameter. +- `security_assignee_groups` - for the security assignee group parameter. +- `security_group` - for the security group parameter. +- `timeout_date` - for the timeout date parameter. + +##### Outputs + +You can specify multiple output variables that would hold the answer of the user interaction components. + +##### Example + +```ts +import { + Workflow, + In, + Item, + RootItem, + UserInteractionItem, +} from "vrotsc-annotations"; + +@Workflow({ + name: "User Interaction", + path: "VMware/PSCoE", + description: "Adding user interaction parameters", +}) +export class UserInteractionWorkflow { + + @RootItem({ target: "userInteraction1Enter", exception: "" }) + public start() { + System.log("Starting workflow"); + } + + @UserInteractionItem({ + target: "userInteraction2Enter", + }) + public userInteraction1Enter() { + System.log("User interaction component 1 activation"); + } + + @UserInteractionItem({ + target: "userInteractionExit", + }) + public userInteraction2Enter( + @In security_assignees: LdapUser[], + @In security_assignee_groups: LdapGroup[], + @In security_group: LdapGroup, + @In timeout_date?: Date, + @In userInteractionAnswer?: string + ) { + System.log("User interaction component 2 activation"); + } + + @Item({ target: "end" }) + public userInteractionExit(@In userInteractionAnswer: string) { + System.log("User Interaction exit"); + } +``` + +The example above would generate the following workflow. + +[![User Interaction Workflow](images/User_Interaction_Canvas_Item_Workflow.png)](images/User_Interaction_Canvas_Item_Workflow.png) + +### Example Workflow + +This example workflow combines all currently supported method decorators in a single workflow. + +```ts +/*- + * #%L + * vro.ts.workflows + * %% + * Copyright (C) 2024 TODO: Enter Organization name + * %% + * TODO: Define header text + * #L% + */ +import { + Workflow, + Out, + In, + Item, + RootItem, + DecisionItem, + WaitingTimerItem, + WorkflowItem, + WorkflowEndItem, + ScheduledWorkflowItem, +} from "vrotsc-annotations"; + +@Workflow({ + name: "Complex Workflow", + path: "VMware/PSCoE", + attributes: { + waitingTimer: { + type: "Date", + }, + counter: { + type: "number", + }, + first: { + type: "number", + }, + second: { + type: "number", + }, + result: { + type: "number", + }, + workflowScheduleDate: { + type: "Date", + }, + scheduledTask: { + type: "Task", + }, + errorMessage: { + type: "string", + }, + wfToken: { + type: "WorkflowToken", + }, + actionResult: { + type: "ActionResult", + }, + }, +}) +export class ComplexWorkflow { + @RootItem({ target: "execute" }) + public start() { + System.log("Starting workflow"); + } + + @Item({ target: "decisionItem" }) + public execute(@Out @In waitingTimer: Date, @Out @In counter: number): void { + if (!counter) { + counter = 0; + } + counter++; + if (counter < 2) { + const tt = Date.now() + 5 * 1000; + waitingTimer = new Date(tt); + } else { + waitingTimer = null; + } + System.log("Counter: " + counter); + System.log("Waiting Timer: " + waitingTimer); + } + + @DecisionItem({ target: "waitForEvent", else: "prepareItems" }) + public decisionItem(waitingTimer: Date) { + return waitingTimer !== null; + } + + @WaitingTimerItem({ target: "callAction" }) + public waitForEvent(@In waitingTimer: Date) { + // NOOP + } + + @ActionItem({ + target: "printActionResult", + scriptModule: "com.vmware.pscoe.library.ecmascript/Set", + }) + public callAction( + @In first: number, + @In second: number, + @Out actionResult: ActionResult + ) { + // NOOP + } + + @Item({ target: "callOtherWf" }) + public prepareItems( + @In @Out first: number, + @In @Out second: number, + @In @Out workflowScheduleDate: Date + ) { + first = 1; + second = 2; + workflowScheduleDate = System.getDate("1 minute from now", undefined); + } + + @WorkflowItem({ + target: "print", + linkedItem: "c2c9d5c4-468e-3cde-a64a-d1de50989214", + }) + public callOtherWf( + @In first: number, + @In second: number, + @Out result: number + ) { + // NOOP + } + + @Item({ target: "scheduleOtherWf" }) + public print(@In result: number) { + System.log("Result: " + result); + } + + @ScheduledWorkflowItem({ + target: "printScheduledDetails", + linkedItem: "9e4503db-cbaa-435a-9fad-144409c08df0", + }) + public scheduleOtherWf( + @In first: number, + @In second: number, + @In workflowScheduleDate: Date, + @Out scheduledTask: Task + ) { + // NOOP + } + + @Item({ target: "asyncCall" }) + public printScheduledDetails(@In scheduledTask: Task) { + System.log(`Scheduled task: ${scheduledTask.id}, [${scheduledTask.state}]`); + } + + @AsyncWorkflowItem({ + target: "printAsync", + linkedItem: "9e4503db-cbaa-435a-9fad-144409c08df0", + }) + public asyncCall( + @In first: number, + @In second: number, + @Out wfToken: WorkflowToken + ) { + // NOOP + } + + @Item({ target: "printActionResult" }) + public printAsync(@In wfToken: WorkflowToken) { + System.log(`Workflow token: ${wfToken.id} and state: ${wfToken.state}`); + } + + @Item({ target: "end" }) + public printActionResult(@In actionResult: ActionResult) { + System.log(`Action result: ${JSON.stringify(actionResult, null, 4)}`); + } +} +``` + +The example above would generate the following workflow. + +[![Complex Workflow](images/Canvas_Item_Complex_Workflow.png)](images/Canvas_Item_Complex_Workflow.png) diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Canvas_Item_Complex_Workflow.png b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Canvas_Item_Complex_Workflow.png new file mode 100644 index 000000000..3aaefe103 Binary files /dev/null and b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Canvas_Item_Complex_Workflow.png differ diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Canvas_Item_Default_Error_Handler_Workflow.png b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Canvas_Item_Default_Error_Handler_Workflow.png new file mode 100644 index 000000000..662bf1577 Binary files /dev/null and b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Canvas_Item_Default_Error_Handler_Workflow.png differ diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Decision_Item_Canvas_Item_Workflow.png b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Decision_Item_Canvas_Item_Workflow.png new file mode 100644 index 000000000..54788acda Binary files /dev/null and b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Decision_Item_Canvas_Item_Workflow.png differ diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Scheduled_Workflow_Canvas_Item_Workflow.png b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Scheduled_Workflow_Canvas_Item_Workflow.png new file mode 100644 index 000000000..f6ed7fcdb Binary files /dev/null and b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Scheduled_Workflow_Canvas_Item_Workflow.png differ diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/User_Interaction_Canvas_Item_Workflow.png b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/User_Interaction_Canvas_Item_Workflow.png new file mode 100644 index 000000000..2d318069c Binary files /dev/null and b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/User_Interaction_Canvas_Item_Workflow.png differ diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Waiting_Timer_Canvas_Item_Workflow.png b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Waiting_Timer_Canvas_Item_Workflow.png new file mode 100644 index 000000000..bf5c32caa Binary files /dev/null and b/docs/versions/v3.0.0/Components/Archetypes/typescript/Components/images/Waiting_Timer_Canvas_Item_Workflow.png differ diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Core Concepts.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Core Concepts.md new file mode 100644 index 000000000..69df68c24 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Core Concepts.md @@ -0,0 +1,30 @@ +[//]: # (DEFAULT TEMPLATE, Used if no others match) + +[//]: # (Remove Comments when you are done) +[//]: # (What is this?) + +# Title + +[//]: # (Additional Information on the topic goes here) + +[//]: # (What will you learn) +[//]: # (Optional) + +## Overview + +[//]: # (Internal navigation) +[//]: # (Navigational links may have a short description after them separated by a `-`) + +## Table Of Contents + +1. [Section](#section) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section + +[//]: # (Optional Section) +[//]: # (## Previous:) + +[//]: # (Optional Section) +[//]: # (## Next:) diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Getting Started.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Getting Started.md new file mode 100644 index 000000000..ecd8bbe2a --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Getting Started.md @@ -0,0 +1,32 @@ +[//]: # (DEFAULT TEMPLATE, Used if no others match) + +[//]: # (Remove Comments when you are done) +[//]: # (What is this?) + +# Title + +[//]: # (Additional Information on the topic goes here) + +[//]: # (What will you learn) +[//]: # (Optional) + +## Overview + +[//]: # (Internal navigation) +[//]: # (Navigational links may have a short description after them separated by a `-`) + +## Table Of Contents + +1. [Properties](#properties) + +### Properties + +#### skipInstallNodeDeps + +Add the `skipInstallNodeDeps` flag to skip the deletion and re-installation of node-deps. Ex: `mvn clean package -DskipInstallNodeDeps=true`. + +Note: If node_modules folder doesn't exist, then this flag is ineffective. + +#### -Dvro.forceImportLatestVersions + +This strategy will force you to upload the same or newer version of a package, otherwise it will fail the build, allowing us for better CI/CD pipelines, where we can ensure that the latest versions are always used on the server. diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Known Issues.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Known Issues.md new file mode 100644 index 000000000..27e64d851 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Known Issues.md @@ -0,0 +1,118 @@ +# Known Issues + +A list of known typescript archetype issues. + +## Table Of Contents + +1. [Array functions are not transpiled to vRO code](#array-functions-are-not-transpiled-to-vro-code) + +### Array functions are not transpiled to vRO code + +If an `Array` variable is not explicitly defined or recognized as such, the transpiler does not convert the TS-specific `Array` prototype functions (`find()`, `some()`, etc.) into vRO compatible code which results in a runtime error. + +Consider the following example: + +```javascript +const testArray = [1, 2, 3, 4, 5]; + +let objectsForIteration = null; +if (true) { + objectsForIteration = testArray; +} + +// Fails to transpile correctly because type is resolved to "any" +const res = objectsForIteration.find(o => o === 2) +System.log(res + "") +``` + +The code above is be converted to the following vRO code, which during execution throws the error `TypeError: Cannot find function find in object 1,2,3,4,5.` + +```javascript +var testArray = [1, 2, 3, 4, 5]; + +var objectsForIteration = null; +if (true) { + objectsForIteration = testArray; +} + +// Fails to transpile correctly because type is resolved to "any" +var res = objectsForIteration.find(function (o) { return o === 2; }); +System.log(res + ""); +``` + +Proper variable typization solves this problem. Let's revisit the example but this time we will explicitly define the type of values that we expect the `objectsForIteration` variable to receive. + +```javascript +const testArray = [1, 2, 3, 4, 5]; + +let objectsForIteration: Array = null; +if (true) { + objectsForIteration = testArray; +} + +// Transpiles correctly because of explicit typization +const res = objectsForIteration.find(o => o === 2) +System.log(res + "") +``` + +The code is transpiled correctly to vRO code and executes successfully. + +```javascript +var __global = System.getContext() || (function () { + return this; +}).call(null); +var VROES = __global.__VROES || (__global.__VROES = System.getModule("com.vmware.pscoe.library.ecmascript").VROES()); +var testArray = [1, 2, 3, 4, 5]; + +var objectsForIteration = null; +if (true) { + objectsForIteration = testArray; +} +// Transpiles correctly because of explicit typization +var res = VROES.Shims.arrayFind(objectsForIteration, function (o) { return o === 2; }); +System.log(res + ""); +``` + +#### How to prevent this issue + +The recommended configuration to prevent such issues is to set the `strictNullChecks` property to `true` in your project's local `tsconfig.json` file. This allows for a type hint warning to be displayed in case the type is not explicitly defined. + +> **NOTE!** The warning messages received are optional and are NOT blocking package build and push operations. + +Let's revisit the example once again with `strictNullChecks` enabled: + +```javascript +const testArray = [1, 2, 3, 4, 5]; + +let objectsForIteration = null; +if (true) { + // The following warning message is displayed: Type 'number[]' is not assignable to type 'null'.ts(2322) + objectsForIteration = testArray; +} + +// The following warning message is displayed: 'objectsForIteration' is possibly 'null'.ts(18047) +const res = objectsForIteration.find(o => o === 2) +System.log(res + "") +``` + +Sample `tsconfig.json`: + +```javascript +{ + "compilerOptions": { + "target": "ES5", + "module": "CommonJS", + "moduleResolution": "Node", + "lib": [ + "ES5", + "ES2015.Core", + "ES2015.Collection", + "ES2015.Iterable", + "ES2015.Promise", + "ES2017.String" + ], + "experimentalDecorators": true, + "strictNullChecks": true + } +} +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Code Coverage.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Code Coverage.md new file mode 100644 index 000000000..b75212271 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Code Coverage.md @@ -0,0 +1,123 @@ +# Code Coverage + +Details on how to enable, configure and read code coverage + +## Overview + +After code has been compiled to javascript (from typescript), a testbed is created. A VRO Runtime is inserted so you can use some modules natively (things like Workflow, Properties, LockingSystem, Server, System, etc.). After the test bed is created, jasmine is run either through IstanbulJS or directly (depending if code coverage is enabled or not). + +> **Jasmine version: 4.0.2** + +## Table Of Contents + +1. [Enabling Code Coverage](#enabling-code-coverage) +2. [Reporters](#reporters) +3. [Setting Thresholds](#setting-thresholds) +4. [How to exclude files from code coverage](#how-to-exclude-files-from-code-coverage) +5. [Best Practices](#best-practices) +6. [Limitations](#limitations) +7. [FAQ](#faq) + +### Enabling Code Coverage + +Start by Adding the following profile to your `~/.m2/settings.xml` file + +```xml + + pscoe-testing + + true + text,html,clover,cobertura,lcovonly + + +``` + +Activate the profile by adding it to the ``. + +```xml + + pscoe-testing + +``` + +### Reporters + +The toolchain supports many different code coverage reporters. Internally we use a tool called IstanbulJS, so the supported reporters and their documentation can be found here: [Using Alternative Reporters](https://istanbul.js.org/docs/advanced/alternative-reporters/). + +After enabling a reporter and running `mvn clean test`, you can see the output files in: `/target/vro-tests/coverage/` + +### Setting Thresholds + +When setting the thresholds for code coverage if you set the ``, if the percentage is not met when running the tests, the tests will be considered as failed. Including such thresholds into your CI/CD pipeline will introduce hard limits that developers must follow when writing code. This way you can introduce a very good quality gate. It is suggested to start with a lower threshold for older projects and higher threshold for new projects. A good example of setting an error threshold would be around 60-70 and a possible warning threshold in the 80s. + +Individual overwrites for thresholds can be set for branches, lines, functions and statements. These individually overwrite the default ones (`test.coverage.thrsholds.error|warn`). + +#### Per-file + +Code coverage per file bases. Set custom --coverage-thresholds, if any file in the project drops below those thresholds, the build will fail. + +Enable by setting `true` in your `~/.m2/settings.xml` testing profile. + +Refer to InstanbulJS documentation for more information: [https://github.com/istanbuljs/nyc](https://github.com/istanbuljs/nyc). + +```xml + + pscoe-testing + + true + text,html,clover,cobertura,lcovonly + + + 70 + 80 + + 60 + 70 + 60 + 70 + 60 + 70 + 60 + 70 + true + + +``` + +### How to exclude files from code coverage + +Files can be excluded from code coverage by naming them following the pattern: `*.helper.[tj]s`. + +During testing, you will be able to use these files by specifying them normally (`import testHelper from "./testHelper.helper";`). + +### Best Practices + +> **Naming convention** + +```txt +"**/?(*.)+(spec|test).[j|t]s(x)" + +//example names for javascript file +MyTests.test.js +MyTests.spec.js + +//example names for typescript file +MyTest.test.ts +MyTest.spec.ts +``` + +### Limitations + +> **actions-package** + +For actions-package projects, all test must be placed under `src/test` folder in order to be compiled and executed and packaged correctly. + +### FAQ + +#### Can I use Jasmine Helpers? + +Jasmine helpers are not supported. We are injecting the vRO Runtime with a helper tho. + +#### Can I test workflows? + +This is currently not supported. As a general rule of thumb, keep your Workflows as minimal as possible. Abstract the logic away from the workflows and put it in an Action that is easily testable. diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Dependecy Injection.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Dependecy Injection.md new file mode 100644 index 000000000..e33350e8b --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Dependecy Injection.md @@ -0,0 +1,88 @@ +# Dependecy Injection + +Example on how to test Dependency Injection + +## Overview + +Dependency injection is providing the objects that an object needs (its dependencies) instead of having it construct them itself. It's a very useful technique for testing, since it allows dependencies to be mocked or stubbed out. + +Dependencies can be injected into objects by constructor injection or setter injection. + +## Table Of Contents + +1. [Example](#example) + +### Example + +Test + +```typescript +export class NoDependencyInjection { + protected restHost: RESTHost; + + // We can retrieve the RESTHost from a config element, but we have no way of creating mocks/spies/expectations + init() { + const restHostConfig = new ConfigElementAccessor('ing/testing/dependencyInjectionRestHost'); + this.restHost = restHostConfig.get('restHost'); + } + + doApiCall() { + const request = this.restHost.createRequest("GET", "/ping", ""); + + return request.execute(); + } +} + +// To test this, create a mock for restHostConfig +export class SomeDependencyInjection { + private restHost: RESTHost; + + // Retrieve the RESTHost from a config element + constructor(restHostConfig: ConfigElementAccessor) { + this.restHost = restHostConfig.get('restHost'); + } + + doApiCall() { + const request = this.restHost.createRequest("GET", "/ping", ""); + + return request.execute(); + } +} + +// Even Better, we can test this by creating a mock for restHost directly, always delegate logic to the parent, not the child! +// Let the action/workflow that needs this class, fetch everything that is needed. +export class GoodDependencyInjection { + constructor(private restHost: RESTHost) { + } + + doApiCall() { + const request = this.restHost.createRequest("GET", "/ping", ""); + + return request.execute(); + } +} + +// Test oriented dependency injection. Useful in a LOT of cases. In your normal execution, you want to retrieve the value +// from some config element, but in test cases, you have an out +export class TestRelatedDependencyInjection { + // When we create this class in our workflows or actions, do not pass a parameter, but when writing tests, create a mocked restHost + constructor(private restHost?: RESTHost) { + if (!restHost) { + const restHostConfig = new ConfigElementAccessor('ing/testing/dependencyInjectionRestHost'); + this.restHost = restHostConfig.get('restHost'); + } + } + + doApiCall() { + const request = this.restHost.createRequest("GET", "/ping", ""); + + return request.execute(); + } +} + +export class NoDependencyInjectionTestDouble extends NoDependencyInjection { + // @ts-ignore + constructor(protected restHost: RESTHost) { + } +} +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Global-Classes.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Global-Classes.md new file mode 100644 index 000000000..c13b67170 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Global-Classes.md @@ -0,0 +1,52 @@ +# Global Classes + +Example on how to test global classes + +## Overview + +When it comes to Static Global Classes (like vCACCAFEFilterParam for example), they need to be defined before each test, with the methods that you want to use inside your test. + +## Table Of Contents + +1. [Example](#example) + +### Example + +Example Class: + +```typescript +export default function ( date: string): string { + Server.log( "Getting date" ); + return vCACCAFEFilterParam.date( date ); +} +``` + +Example test: + +```typescript +import testOne from "./testOne"; + +describe('', function () { + beforeEach(()=>{ + ( vCACCAFEFilterParam) = { + date: function ( date: string ) { + throw new Error( "Not Supported" ); + } + }; + }); + + afterEach(() => { + ( vCACCAFEFilterParam) = undefined; + }); + + it('should ', function () { + spyOn( Server, "log" ).and.callFake( () => {} ); + spyOn( vCACCAFEFilterParam, "date" ).and.returnValue( "spy" ); + + expect( testOne( 'test' ) ).toBe( "spy" ); + + expect( vCACCAFEFilterParam.date ).toHaveBeenCalledTimes( 1 ); + expect( Server.log ).toHaveBeenCalledTimes( 1 ); + }); +}); +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Native-Actions.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Native-Actions.md new file mode 100644 index 000000000..1025a88a3 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/Native-Actions.md @@ -0,0 +1,33 @@ +# Native Actions + +Example on how to test native actions + +## Overview + +When it comes to native actions items, using the old syntax of creating actions allow us to call the actions directly when needed. Mapping inputs and outputs according to the documentation/arguments. + +## Table Of Contents + +1. [Example](#example) + +### Example + +Test: + +```typescript +const sumAction = System.getModule("com.vmware.pscoe.actions").sumAction; + +describe("Sum Action test", () => { + it("should add two numbers", () => { + expect( sumAction( 1,5 ) ).toBe( 6 ); + }); +}) +``` + +Code To Test: + +```typescript +(function ( numberOne: number, numberTwo: number ):number { + return numberOne + numberTwo; +}); +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/RestHost.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/RestHost.md new file mode 100644 index 000000000..685be7bd1 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Examples/RestHost.md @@ -0,0 +1,51 @@ +# RestHost + +Example on how to test RestHost + +## Overview + +## Table Of Contents + +1. [Example](#example) + +### Example + +Test: + +```typescript +describe("ApiCall", () => { + it('should do an api call', function () { + const restHostTestDouble = jasmine.createSpyObj("RESTHost", ["createRequest"]); + const restRequestTestDouble = jasmine.createSpyObj("RESTRequest", ["execute"]); + const restResponseTestDouble = jasmine.createSpyObj("RESTResponse", [], {contentAsString: JSON.stringify({test: 2})}); + + restHostTestDouble.createRequest.and.returnValue(restRequestTestDouble); + restRequestTestDouble.execute.and.returnValue(restResponseTestDouble); + + const restHostExample = new RestHostExample(restHostTestDouble); + + const response = restHostExample.doApiCall(); + + expect(response.test).toBe(2); + expect(restHostTestDouble.createRequest).toHaveBeenCalledTimes(1); + expect(restHostTestDouble.createRequest).toHaveBeenCalledWith("GET", "/api/v1/test", ""); + expect(restRequestTestDouble.execute).toHaveBeenCalledTimes(1); + }); +}) + +``` + +Code To Test: + +```typescript +export default class RestHostExample { + constructor(private restHost: RESTHost) { + } + + doApiCall() { + const restRequest: RESTRequest = this.restHost.createRequest("GET", "/api/v1/test", ""); + const restResponse: RESTResponse = restRequest.execute() + return JSON.parse(restResponse.contentAsString); + } +} +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Getting Started.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Getting Started.md new file mode 100644 index 000000000..1f5343b0b --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Getting Started.md @@ -0,0 +1,85 @@ +# Getting Started + +## Overview + +After code has been compiled to javascript ( from typescript ), a testbed is created. A VRO Runtime is inserted so you can use some modules natively (things like Workflow, Properties, LockingSystem, Server, System, etc.). After the test bed is created, jasmine is run either through IstanbulJS or directly( depending if code coverage is enabled or not ). + +> **Jasmine version: 4.0.2** + +## Table Of Contents + +1. [Limitations](#limitations) +2. [Best Practices](#best-practices) +3. [FAQ](#faq) + +### Limitations + +> ***actions-package*** + +For actions-package projects, all test must be placed under `src/test` folder in order to be compiled and executed and packaged correctly. + +> ***What types of files can I test*** + +Only file types that can be tested are Actions - filename.ts. Workflows can't be tested as well as config files. As a general rule of thumb, keep your Workflows as minimal as possible. Abstract the logic away from the workflows and put it in an Action that is easily testable. + +### Best Practices + +> ***Unit testing*** + +Testing individual components of software. A unit test should test one thing. + +Label your test suites (describe blocks) and specs (it blocks) in a way that clearly conveys the intention of each unit test. Note that the name of each test is the title of its it preceded by all its parent describe names. Favor assertive verbs and avoid ones like "should." + +Test file contains one describe() block containing multiple describes with common functionality. Each describe() must have a meaningful name. Do not include logic or mocks in describe blocks. + +> ***beforeEach()*** + +We can execute some pieces of code before execution of each spec. For example you can create new instances here. Don't use any logic in the describe() block, only in beforeEach(). Use "this" to share variables between it and before/after blocks. + +```typescript +beforeEach(() => { + this.someClass = new SomeClass(); +}); + +describe("Different Methods of Expect Block",function() { + it("Returns even or optional ", function() { + expect(this.someClass.evenOrOdd()).toBe("even"); + }); +}); +``` + +> ***Write Minimum Passable Tests*** + +If appropriate, use Jasmine's built-in matchers (such as toContain, jasmine.any, jasmine.stringMatching, ...etc) to compare arguments and results. You can also create your own matcher via the asymmetricMatch function. + +```typescript +describe('Array.prototype', function() { + describe('.push(x)', function() { + beforeEach(function() { + this.initialArray = []; + + this.initialArray.push(1); + }); + + it('appends x to the Array', function() { + expect(this.initialArray).toContain(1); + }); + }); +}); +``` + +> ***Naming convention*** + +```txt +"**/?(*.)+(spec|test).[j|t]s(x)" + +//example names for javascript file +MyTests.test.js +MyTests.spec.js + +//example names for typescript file +MyTest.test.ts +MyTest.spec.ts +``` + +### FAQ diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Jasmine Spies.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Jasmine Spies.md new file mode 100644 index 000000000..1ab5a14f5 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Jasmine Spies.md @@ -0,0 +1,51 @@ +# Jasmine Spies + +## Overview + +A Spy is a feature that allows you to simulate the behavior of existing code and track calls to it back. It’s used to mock a function or an object. + +## Table Of Contents + +1. [createSpy()](#createspy) +2. [createSpyObj()](#createspyobj) + +### createSpy() + +Can be used when there is no function to spy on. Takes two arguments - name of the Service, method we want to mock + +```typescript +let testDouble = jasmine.createSpy("Name holder.", "method"); +``` + +### createSpyObj() + +createSpyObj() creates a mock object that will spy on one or more methods. It returns an object that has a property for each string that is a spy. It takes as first argument the name of a Service and as a second an array of strings of all the methods that we want to mock. + +```typescript +let testDouble = jasmine.createSpyObj("Name holder. Same as the type, in this case T", ["Array of strings with all functions that will be overwritten"]); +``` + +```typescript +describe("ApiCall", () => { + it('should do an api call', function () { + const restHostTestDouble = jasmine.createSpyObj("RESTHost", ["createRequest"]); + + const restRequestTestDouble = jasmine.createSpyObj("RESTRequest", ["execute"]); + + // Properties mock + const restResponseTestDouble = jasmine.createSpyObj("RESTResponse", [], {contentAsString: JSON.stringify({test: 2})}); + + restHostTestDouble.createRequest.and.returnValue(restRequestTestDouble); + restRequestTestDouble.execute.and.returnValue(restResponseTestDouble); + + const restHostExample = new RestHostExample(restHostTestDouble); + + const response = restHostExample.doApiCall(); + + expect(response.test).toBe(2); + expect(restHostTestDouble.createRequest).toHaveBeenCalledTimes(1); + expect(restHostTestDouble.createRequest).toHaveBeenCalledWith("GET", "/api/v1/test", ""); + expect(restRequestTestDouble.execute).toHaveBeenCalledTimes(1); + }); +}) +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Test Helpers.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Test Helpers.md new file mode 100644 index 000000000..698d15d94 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/General/Testing/Test Helpers.md @@ -0,0 +1,13 @@ +# Test Helpers + +## Overview + +Helpers are testing files. Naming convention is - filename.helper.ts . They are compiled, can be used in testing, no code coverage and will not be pushed to vRO. Mocks are defined in Helper files. + +## Table Of Contents + +1. [Known Issues](#known-issues) + +### Known Issues + +Helper files must be located in any folder under `src/`, recommended place is `src/tests/helpers`. diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Operations/Building.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/Operations/Building.md new file mode 100644 index 000000000..69df68c24 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/Operations/Building.md @@ -0,0 +1,30 @@ +[//]: # (DEFAULT TEMPLATE, Used if no others match) + +[//]: # (Remove Comments when you are done) +[//]: # (What is this?) + +# Title + +[//]: # (Additional Information on the topic goes here) + +[//]: # (What will you learn) +[//]: # (Optional) + +## Overview + +[//]: # (Internal navigation) +[//]: # (Navigational links may have a short description after them separated by a `-`) + +## Table Of Contents + +1. [Section](#section) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section + +[//]: # (Optional Section) +[//]: # (## Previous:) + +[//]: # (Optional Section) +[//]: # (## Next:) diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/Operations/Pushing.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/Operations/Pushing.md new file mode 100644 index 000000000..69df68c24 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/Operations/Pushing.md @@ -0,0 +1,30 @@ +[//]: # (DEFAULT TEMPLATE, Used if no others match) + +[//]: # (Remove Comments when you are done) +[//]: # (What is this?) + +# Title + +[//]: # (Additional Information on the topic goes here) + +[//]: # (What will you learn) +[//]: # (Optional) + +## Overview + +[//]: # (Internal navigation) +[//]: # (Navigational links may have a short description after them separated by a `-`) + +## Table Of Contents + +1. [Section](#section) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section + +[//]: # (Optional Section) +[//]: # (## Previous:) + +[//]: # (Optional Section) +[//]: # (## Next:) diff --git a/docs/versions/v3.0.0/Components/Archetypes/typescript/README.md b/docs/versions/v3.0.0/Components/Archetypes/typescript/README.md new file mode 100644 index 000000000..f08947010 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/typescript/README.md @@ -0,0 +1,24 @@ +# Typescript Archetype + +Typescript archetype used to compile and push typescript code to vRO. + +## Overview + +This archetype is used when you want to push code to vRO. It supports configuration elements, resource elements, workflows, +actions, policy templates, native content, types, etc. + +It allows you to write unit tests and has embedded code coverage + +## Navigation + +1. [Getting Started](General/Getting%20Started.md) +2. [Core Concepts](General/Core%20Concepts.md) +3. Operations + * [Building](Operations/Building.md) + * [Pushing](Operations/Pushing.md) +4. Components + * [Config](Components/Config.md) + * [Policies](Components/Policy.md) +5. Testing + * [Code Coverage](General/Testing/Code%20Coverage.md) +6. [Known Issues](General/Known%20Issues.md) diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Blueprints.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Blueprints.md new file mode 100644 index 000000000..ff9267cdd --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Blueprints.md @@ -0,0 +1,63 @@ +# Blueprints + +Blueprint (aka `Cloud Templates`) architects build Software components, machine blueprints, and custom XaaS blueprints and assemble those components into the blueprints that define the items users request from the catalog. + +## Table Of Contents + +1. [Structure](#structure) - how are blueprints exported and what does each file mean? +2. Operations + 1. [Importing](#importing) blueprints to vRA +3. [Known Issues](#known-issues) + +### Structure + +Below is an example structure of a blueprint export. + +Example `content.yaml` + +```yaml +blueprint: + - Example Blueprint +# ... +``` + +Structure + +```ascii +src/ +├─ main/ +│ ├─ resources/ +│ │ ├─ blueprints/ +│ │ │ ├─ Example Blueprint/ +│ │ │ │ ├─ content.yaml +│ │ │ │ ├─ details.json +│ │ │ │ ├─ versions.json +``` + +Each blueprint will be placed in a different folder. + +- `content.yaml` contains the exported code from the blueprint's canvas. +- `details.json` contains metadata information +- `versions.json` contains version information. Note that this is just the metadata, for now [the version history is not preserved](#version-history-gets-lost). + +### Importing + +When importing a blueprint, it is matched by its `name`. If there is a blueprint with the same name on the server, an update will be performed. Otherwise, the blueprint will be created instead. + +Also when importing an already existing blueprint, we will check for any differences between local copy and server copy. If there are differences, a new version will be released. New version is determined by the already existing versions. If a patter of MAJOR.MINOR.PATCH is detected, vRBT will try to continue the numbering, otherwise a date formatted version is released. + +#### Version Management + +By default all versions that are not the latest one will be unreleased. + +To control this behavior you can set: + +```xml +false +``` + +### Known Issues + +#### Version history gets lost + +This is known and currently there is no workaround for this. diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Content Policies.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Content Policies.md new file mode 100644 index 000000000..7f000b570 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Content Policies.md @@ -0,0 +1,200 @@ +# Content Policies + +There are 6 types of content policies: + +- Approval +- Content Sharing +- Day 2 Actions +- Deployment Limit +- Lease +- Resource Quota + +## Table Of Contents + +1. [Structure](#structure) +2. [Operations](#operations) + 1. [Exporting](#exporting) - how are policies exported from a vRa + 2. [Importing](#importing) importing policies to vRA +3. [Known Issues](#known-issues) + +### Structure + +Below is an example structure of content policies export. + +Example `content.yaml` + +```yaml +policy: + approval: + - example policy + content-sharing: + - example policy + day2-actions: + - example policy + deployment-limit: + - example policy + lease: + - example policy + resource-quota: + - example policy + +# ... +``` + +Structure + +```ascii +src/ +├─ main/ +│ ├─ resources/ +│ │ ├─ policies/ +│ │ │ ├─ approval/ +│ │ │ │ ├─ examplePolicy.json +│ │ │ ├─ content-sharing/ +│ │ │ │ ├─ examplePolicy.json +│ │ │ ├─ day2-actions/ +│ │ │ │ ├─ examplePolicy.json +│ │ │ ├─ deployment-limit/ +│ │ │ │ ├─ examplePolicy.json +│ │ │ ├─ lease/ +│ │ │ │ ├─ examplePolicy.json +│ │ │ ├─ resource-quota/ +│ │ │ │ ├─ examplePolicy.json +``` + +### Operations + +Operations are invoked on policies based on filtering from content.yml file, according to the following rules: + +- Empty array [] - nothing is imported/exported. +- List of items - the given items are imported/exported. If they are not present on the server an Exception is thrown. +- Null (nothing given) - everything is being imported/exported. + +#### Importing + +When importing policies, files are read form the filesystem, and the content.yml filter is by filename. All non-hidden files are read from the folder, and if the name of the file, without the extension matches the list in content.yml, the policy will be imported. The filename is only important for filtering. Actual policy fields are read from the file contents. If there is a policy with the same id on the server, an update will be performed. Otherwise, the policy will be created instead, using the same id, that is found in the file. + +##### Content Sharing Polices Import + +If project name is is defined as a *scope* proprty in the content sharing JSON file it will be used as a project scope during push , hence allowing more granular content sharing across different projects. If the *scope* property is not defined then the project id defined in the settings.xml configuration file will be used. + +If a organization name is defined as *organization* property in the content sharing JSON file then it will be used as organization of the content sharing policy, otherwise the organization defined in the settings.xml file will be used. The following policy types can be used during import: + +1. Content source policies. +2. Catalog item policies. +3. Combined policies (that contain catalog items and content sources). + +The name of the content source(s) and catalog item(s) in the file are stored in the JSON file, hence if they are present on the target system the policy can be imported correctly during subsequent push. + +#### Exporting + +When exporting a policy, a json file will be created on the filesystem. The filename will be the policyName[-index].json. +Index will be added only if there are multiple policies with the same name. + +##### Content Sharing Polices Export + +The scope and organization of the content sharing policy will be exported as *scope* and *organization* properties in the output JSON file(s). The project name will be used as as *scope* parameter and organization name will be used as a *organization* parameter. The following policy types can be created on the target system and they will be exported as well: + +1. Content source policies. +2. Catalog item policies. +3. Combined policies (that contain catalog items and content sources). + +The catalog items and content source policies will be stored with their names in the output JSON file. + +#### Content Sharing Polices Examples + +Example content sharing policy JSON file with scope / organization parameters. + +```JSON +{ + "id": "1", + "name": "contentSharingPolicy", + "typeId": "com.vmware.policy.catalog.entitlement", + "projectId": "1", + "scope": "projectId1", + "organization": "organization1", + "enforcementType": "HARD", + "description": "TEST", + "definition": { + "entitledUsers": [ + { + "items": [ + { + "name": "Content Source 1", + "type": "CATALOG_SOURCE_IDENTIFIER" + }, + { + "name": "Content Source 2", + "type": "CATALOG_SOURCE_IDENTIFIER" + }, + { + "name": "Catalog Item 1", + "type": "CATALOG_ITEM_IDENTIFIER" + }, + ], + "userType": "USER", + "principals": [ + { + "type": "PROJECT", + "referenceId": "" + } + ] + } + ] + } +} +``` + +Example content sharing policy JSON file without scope / organization parameters. + +```JSON +{ + "id": "1", + "name": "contentSharingPolicy", + "typeId": "com.vmware.policy.catalog.entitlement", + "projectId": "1", + "orgId": "1", + "enforcementType": "HARD", + "description": "TEST", + "definition": { + "entitledUsers": [ + { + "items": [ + { + "name": "Content Source 2", + "type": "CATALOG_SOURCE_IDENTIFIER" + }, + { + "name": "Content Source 3", + "type": "CATALOG_SOURCE_IDENTIFIER" + }, + { + "name": "Catalog Item 4", + "type": "CATALOG_ITEM_IDENTIFIER" + }, + ], + "userType": "USER", + "principals": [ + { + "type": "PROJECT", + "referenceId": "" + } + ] + } + ] + } +} +``` + +### Known Issues + +Re-Creating Deleted policy. +If you delete a policy, and then try to re-import it immediately, the import command will not fail, however, the policy will not be created. +After a certain delay, the policy can be re-created again via vrealize:push. +"Open bug: [VRAE-61849]" + +Here are two approaches to prevent this from happening: + +- **Do not delete policies before re-importing them.** This approach will only work if you do not need to change some properties like projectId. + +- **Remove policy ids from JSON files.** After successful import, do a export to get the new policyIds in the JSON files again. This approach will only work if you are exporting and importing from a single site. If you are exporting from SiteA to SiteB regularly, this may lead to policy duplicates. diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Custom Resources.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Custom Resources.md new file mode 100644 index 000000000..8d0dff59c --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Components/Custom Resources.md @@ -0,0 +1,17 @@ +# Custom Resources + +They are items that can be used in the Blueprints/Cloud Templates when the existing Resource Types are not enough. + +## Overview + +Custom Resources are items that are defined inside of Cloud Assembly. They extend the capabilities of Cloud Templates by giving you the ability to define your own Resource, that calls either a vRO Workflow or an ABX Action (in the latest version of vRA). Custom Resources are defined in the `content.yaml` file under `custom-resource` ([See content.yaml](../General/Content.md)). + +## Table Of Contents + +1. [Known Issues](#known-issues) + +### Known Issues + +#### Updating A Custom Resource When In Use By Deployment + +When we try to update a CR that is in use by a deployment and if the deletion fails, now we will attempt to update the CR by pre-fetching it's ID. Once we have the ID, we would remove it from the CR and re-assigned it again before the importing process is initiated. This would allow us to create an updated CR that would be imported to vRA no matter if it is used by a deployment. However, update capabilities are limited and may not allow you to update all fields. diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Content.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Content.md new file mode 100644 index 000000000..f948e0e5b --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Content.md @@ -0,0 +1,91 @@ + +# Content + +## Overview + +The vRA 8.x elements that you want to work with are described in the `content.yaml` + +## Table Of Contents + +1. [Content.yaml](#contentyaml) + +### Content.yaml + +By default the `content.yaml` looks like this. + +```yaml +blueprint: +subscription: +custom-resource: +resource-action: +catalog-entitlement: +catalog-item: +content-sources: +property-group: +``` + +#### Content Filtering + +Contents are exported by different rules. + +#### Import Rules for content types + +- Empty array [] - nothing is imported +- List of items - the given items are imported. If they are not present on the server an Exception is thrown. +- Null (nothing given) - everything is being imported + - blueprints + - catalog-item + - content-source + - custom-resource + - catalog-entitlement + - property-group + - subscription + - policies + +#### Export Rules for content types + +- Empty array [] - nothing is exported +- List of items - the given items are exported. If they are not present on the server an Exception is thrown. +- Null (nothing given) - everything is being exported + - blueprints + - catalog-item + - content-source + - custom-resource + - catalog-entitlement + - property-group + - subscription + - policies + +#### Examples + +Example of `content.yaml` file. + +```yaml +blueprint: # will export all +subscription: # will export all +catalog-item: # export according to filter + - Project Blueprints__WindowsVM + - Project Blueprints__LinuxVm + - Main Workflows__ConfigureVM +custom-resource: # will export all +resource-action: # will export all +property-group: # export according to filter + - memory +catalog-entitlement: # export according to filter + - Content source entitlement +content-source: # export according to filter + - Project Blueprints + - Main Workflows + - Utility Workflows + - Project Abx Actions + - Project Code Stream pipelines +policy: # export according to filter + approval: [] + content-sharing: + - cs policy 1 + - cs policy 2 + day2-actions: [] + deployment-limit: [] + lease: [] + resource-quota: [] +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Core Concepts.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Core Concepts.md new file mode 100644 index 000000000..07576d0da --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Core Concepts.md @@ -0,0 +1,72 @@ +# Core Concepts + +Laid out are some Core Concepts to follow when working with vRA 8.x ( vRA-NG ) archetype. + +## Overview + +vRA-NG archetype uses a pull and push approach to handling data. + +## Table Of Contents + +1. [Data Handling](#data-handling) +2. [ID handling](#id-handling) +3. [Single Project And Organization](#single-project-and-single-organization) +4. [Blueprint Versioning](#blueprint-versioning) + +### Data Handling + +All data that needs to be exported from vRA is defined in the `content.yaml` file ([read more here](Content.md)). The tool respects configuration in manifest when doing `vra-ng:pull` for the given objects: + +- blueprints +- catalog-item +- content-source +- custom-resource +- catalog-entitlement +- property-group +- subscription +- policies + - approval + - content-sharing + - day2-actions + - deployment-limit + - lease + - resource-quota + +It will throw an error if the given entities are not on the server. + +All the data exported will be imported when running `vrealize:push`! Keep in mind that the `content.yaml` will not be taken into consideration. + +### ID handling + +Relying on ids exported by Build Tools for VMware Aria should not happen. Build Tools for VMware Aria will remove where needed such ids or in some cases data will be fetched from the remote server, modified in flight and pushed to the server ( in cases where an import is needed ). + +### Single Project And Single Organization + +When working with vRA-NG archetype, each generated archetype is intended to work with **only one project and one organization**. In a case where more are needed, you must generate multiple archetypes. + +### Blueprint Versioning + +When pushing a blueprint to a vRA server that contains previously released blueprint with the same name as the one being pushed, a new version will be created and released in order to maintain the intended state. A new version will *not* be created if the content of the blueprint has not been modified since the latest released version in order to avoid unnecessary versioning. + +If there's a custom form associated with the blueprint being imported and there's no previously released version, an initial blueprint version (1) will be created and released in order to import the custom form. + +When creating a new version in the above-described cases, the new version will be auto-generated based on the latest version of the blueprint. The following version formats are supported with their respective incrementing rules: + +| Latest version | New version | Incrementing rules | +|----------------|---------------------|------------------------------------------------------------| +| 1 | 2 | Increment major version | +| 1.0 | 1.1 | Major and minor version - increment the minor | +| 1.0.0 | 1.0.1 | Major, minor and patch version - incrementing the patch | +| 1.0.0-alpha | 2020-05-27-10-10-43 | Arbitrary version - generate a new date-time based version | + +### Catalog Items Custom Forms + +The catalog items in the vRA Service Broker consists of different type of content sources - Blueprint, Extensibility Actions, Pipelines, Workflows and AWS CloudFormation Template. As with the 8.12 release, the catalog items custom forms can be versioned. For all types, the same concepts replies - *only current versions for custom forms are de-serializing/serializing.* + +Blueprint type catalog items have different versions that corelate to the released versions of the Blueprints. Only the current version of the latest blueprint version is targeted. + +[//]: # (Optional Section) +[//]: # (## Previous:) + +[//]: # (Optional Section) +[//]: # (## Next:) diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Getting Started.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Getting Started.md new file mode 100644 index 000000000..73320977d --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Getting Started.md @@ -0,0 +1,130 @@ +# Getting Started + +## Overview + +vRA 8.x projects are called vRA NG (New Generation) projects in **Build Tools for VMware Aria**. The new Maven Archetype that supports vRA 8.x content is *com.vmware.pscoe.vra-ng.archetypes*. It is a representation of vRA 8.x content into human friendly YAML and/or JSON format.The project consist of content descriptor and content container. + +- *Content Descriptor* defines what part vRA 8.x content will be part of this project - `content.yaml` +- *Content Container* holds the actual content representation -`./src` folder + +## Table Of Contents + +1. [Maven Archetype](#maven-archetype) +2. [Configuring settings xml](#configuring-m2settingsxml-to-work-with-vra-ng) + +### Maven Archetype + +**Build Tools for VMware Aria** provides ready to use project templates (*maven archetypes*). + +To create a new vRA 8.x project from archetype use the following command: + +```Bash +mvn archetype:generate \ + -DinteractiveMode=false \ + -DarchetypeGroupId=com.vmware.pscoe.vra-ng.archetypes \ + -DarchetypeArtifactId=package-vra-ng-archetype \ + -DarchetypeVersion= \ + -DgroupId=local.corp.it.cloud \ + -DartifactId=catalog +``` + +**Note**: *The specified should be minimum 2.4.11* + +#### Content Structure + +The result of this command will produce the following project file structure: + +```ascii +catalog +├── README.md +├── content.yaml +├── pom.xml +├── release.sh +└── src + └── main + └── blueprints + └── blueprint.yaml + └── content.yaml + └── versions.yaml + └── content-sources + └── source.json + └── property-group + └── property_group_name.json + └── catalog-items + └── forms + └── source name__workflow one name with custom form.json + └── source name__workflow one name with custom form__FormData.json + └── source name__workflow three name with custom icon and form.json + └── source name__workflow three name with custom icon and form__FormData.json + └── icons + └── source name__workflow two name with custom icon.png + └── source name__workflow three name with custom icon and form.png + └── source name__workflow one name with custom form.json + └── source name__workflow two name with custom icon.json + └── source name__workflow three name with custom icon and form.json + └── entitlements + └── Blueprint.yaml + └── Workflow.yaml + └── ABX Action.yaml + └── subscriptions + └── subscription.json + └── custom-resources + └── customResource.json + └── resource-actions + └── resourceAction.json + └── policy: + └── approval: + └── aprovalPolicy1.json + └── content-sharing: + └── contentSharingPolicy1.json + └── day2-actions: + └── day2ActionsPolicy1.json + └── deployment-limit: + └── deploymentLimitPolicy1.json + └── lease: + └── leasePolicy1.json + └── resource-quota: + └── resourceQuotaPolicy1.json + + +``` + +Content Descriptor is implemented by content.yaml file with the following defaults. + +**Note**: *vRA NG Project supports only content types outlined into content descriptor.* + +### Configuring ~/.m2/settings.xml to work with vRA-NG + +The following need to be added to the profile that you intend to use: + +```xml + + + + example.vra.url.com + console.cloud.vmware.com + http://proxy.host:80 + 443 + administrator + someSecurePassword + {tenant} + {project+name} + {org+name} + {refresh+token} + true|false + {vro+integration+name} + +``` + +- `vrang.refresh.token` - will use the given refresh token instead of credentials. + + **Note:** this will take precedence over +credentials. + +- `vrang.bp.unrelease.versions` - Defaults to `true`. Controls whether old versions of a blueprint sould be unreleased. + +- `vrang.data.collection.delay.seconds` - Delay in seconds to wait for vRA data collection to pass before importing data. Can also be passed as an interactive parameter `-Dvrang.data.collection.delay.seconds=600`. useful when Dynamic types and custom resources are used in the projects and vRO content is imported, however vRA needs to then retrieve it in order to be able to create the custom Resource and use the Create/Delete Workflows. This only happens after a short delay and the vRA data collector scrapes vRO. Defaults to no delay. + +#### Organizations + +`vrang.org.name` needs to be specified. The `vra-ng` project is scoped to a single organization. diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Known Issues.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Known Issues.md new file mode 100644 index 000000000..b718f04e2 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/General/Known Issues.md @@ -0,0 +1,14 @@ +# Known Issues + +A list of known vRA 8.x archetype issues + +## Table Of Contents + +1. [All Local Data Is Pushed](#all-local-data-is-pushed-to-vra) + +### All local data is pushed to vRA + +This is not a bug, but a feature. Reference: [1][1] | [2][2] + +[1]: Core%20Concepts.md#data-handling "Data Handling" +[2]: ../Operations/Pushing.md#usage "Pushing" diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Operations/Pulling.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Operations/Pulling.md new file mode 100644 index 000000000..5b746b137 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Operations/Pulling.md @@ -0,0 +1,19 @@ +# Pulling + +Maven command for pulling vRA 8.x Content + +## Overview + +When working on a vRA 8.x project, you mainly make changes on a live server using the vRA Portal (Service Broker, Cloud Assembly, etc.) and then you need to capture those changes in the maven project on your filesystem to be able to store the content, track changes, collaborate, etc. + +## Table Of Contents + +1. [Usage](#usage) + +### Usage + +To support this use case, the toolchain comes with a custom goal `vra-ng:pull`. The following command will `pull` the content outlined into *Content Descriptor* file to the current project from a specified server and expand its content in the local filesystem overriding any local content: + +```bash +mvn vra-ng:pull -P{profile} +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Operations/Pushing.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Operations/Pushing.md new file mode 100644 index 000000000..4b0ae4987 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/Operations/Pushing.md @@ -0,0 +1,21 @@ +# Pushing + +Maven command for pushing vRA 8.x Content + +## Overview + +This will push all local content from `./src` folder to the remote vRA Server for the given profile. + +## Table Of Contents + +1. [Usage](#usage) + +### Usage + +To deploy the code developed in the local project or checked out from source control to a live server, you can use the `vrealize:push` command. + +> **Note**: This ignores `content.yaml` + +```bash +mvn package vrealize:push -P{profile} +``` diff --git a/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/README.md b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/README.md new file mode 100644 index 000000000..b198c8a2c --- /dev/null +++ b/docs/versions/v3.0.0/Components/Archetypes/vRA 8.x/README.md @@ -0,0 +1,32 @@ +# vRA 8.x Archetype + +vRA 8.x archetype used to pull and push content from/to vRA. + +## Overview + +This archetype is used when you want to pull and push content to vRA. The content you want to pull is defined in `content.yaml`. All exported content goes to `./src`. + +Supported content: + +- `blueprint` +- `subscription` +- `custom-resource` +- `catalog-entitlement` +- `catalog-item` +- `content-sources` +- `property-group` + +This Archetype is also known as `vRA-NG` (which stands for **vR**ealize **A**utomation-**N**ew **G**eneration). + +## Navigation + +1. [Getting Started](General/Getting%20Started.md) +2. [Core Concepts](General/Core%20Concepts.md) +3. Operations + - [Pulling](Operations/Pulling.md) + - [Pushing](Operations/Pushing.md) +4. [Content](General/Content.md) +5. Components + - [Custom Resources](Components/Custom%20Resources.md) + - [Blueprints](Components/Blueprints.md) +6. [Known Issues](General/Known%20Issues.md) diff --git a/docs/versions/v3.0.0/Components/Local/Common/Artifact Manager/Components/vRA 8.x/README.md b/docs/versions/v3.0.0/Components/Local/Common/Artifact Manager/Components/vRA 8.x/README.md new file mode 100644 index 000000000..18367b4e3 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Common/Artifact Manager/Components/vRA 8.x/README.md @@ -0,0 +1,16 @@ +[//]: # (Used just for navigation, should not have any information beside very basic one) +[//]: # (If you need to add information to an entry it needs to be moved outside to a different folder) +[//]: # (Change the title) + +# Entry + +[//]: # (Additional Information on the entry goes here) + +[//]: # (What will you learn) + +## Overview + +[//]: # (External navigation) +[//]: # (Navigational links may have a short description after them separated by a `-`) + +## Navigation diff --git a/docs/versions/v3.0.0/Components/Local/Common/Artifact Manager/README.md b/docs/versions/v3.0.0/Components/Local/Common/Artifact Manager/README.md new file mode 100644 index 000000000..156b4e97d --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Common/Artifact Manager/README.md @@ -0,0 +1,18 @@ +[//]: # (Used just for navigation, should not have any information beside very basic one) +[//]: # (If you need to add information to an entry it needs to be moved outside to a different folder) +[//]: # (Change the title) + +# Entry + +[//]: # (Additional Information on the entry goes here) + +[//]: # (What will you learn) + +## Overview + +[//]: # (External navigation) +[//]: # (Navigational links may have a short description after them separated by a `-`) + +## Navigation + +1. [vRA 8.X](Components/vRA%208.x) diff --git a/docs/versions/v3.0.0/Components/Local/Installer/.gitkeep b/docs/versions/v3.0.0/Components/Local/Installer/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/Components/Local/Installer/Components/Install Workflow.md b/docs/versions/v3.0.0/Components/Local/Installer/Components/Install Workflow.md new file mode 100644 index 000000000..be3673dd9 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Installer/Components/Install Workflow.md @@ -0,0 +1,47 @@ +# Install workflow + +Most common case of today is to use Install workflow from PsCoE installer library. + +## Overview + +We can run Install workflow automatically and pass to this workflow all necessary parameters: + +- jsonString +- tags +- blacklist + +## Table Of Contents + +1. [vRO workflow run configuration](#vro-workflow-run-configuration) +2. [Installation/configuration values](#installationconfiguration-values) +3. [Installation/configuration file example](#installjson-example) + +### vRO workflow run configuration + +```ts +vro_run_workflow=true +vro_run_workflow_id=1490692845582937823496790834565483423 +vro_run_workflow_input_file_path=./install.json +vro_run_workflow_output_file_path=./output.json +vro_run_workflow_timeout=300 +``` + +### Installation/configuration values + +The installation/configuration values are passed as a json file (or yaml). Each root property of this file should have the name of an input value of the targeted workflow. + +### install.json example + +```JSON +{ + "tags": [ + "conn" + ], + "jsonString": { + "conn": { + "username": "admin", + "password": "p@$$w0rd" + } + } +} +``` diff --git a/docs/versions/v3.0.0/Components/Local/Installer/General/Core Concepts.md b/docs/versions/v3.0.0/Components/Local/Installer/General/Core Concepts.md new file mode 100644 index 000000000..28d86d651 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Installer/General/Core Concepts.md @@ -0,0 +1,17 @@ +# Core Concepts + +## Overview + +We can run any existing workflow automatically at the end of the installation process and pass to the workflow all necessary parameters of different types. Supported types are: + +- string +- number +- boolean +- Array/string + +All other types except mentioned bellow will be send as parameter of type `string`. The most common case of today is to use this feature for running `Install` workflow. + +## Navigation + +1. Components + - [Example of using Install workflow](../Components/Install%20Workflow.md). diff --git a/docs/versions/v3.0.0/Components/Local/Installer/README.md b/docs/versions/v3.0.0/Components/Local/Installer/README.md new file mode 100644 index 000000000..31e8d89c0 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Installer/README.md @@ -0,0 +1,12 @@ +# Installer + +## Overview + +We can run any existing workflow automatically at the end of the installation process and pass to the workflow all necessary parameters. + +## Navigation + +1. General + - [Core Concepts](General/Core%20Concepts.md) +2. Components + - [Example of using Install workflow](Components/Install%20Workflow.md) diff --git a/docs/versions/v3.0.0/Components/Local/Maven/.gitkeep b/docs/versions/v3.0.0/Components/Local/Maven/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/Components/Local/Packages/.gitkeep b/docs/versions/v3.0.0/Components/Local/Packages/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/Components/Local/Types/.gitkeep b/docs/versions/v3.0.0/Components/Local/Types/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/polyglotpkg/.gitkeep b/docs/versions/v3.0.0/Components/Local/Typescript/polyglotpkg/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vro-scripting-api/.gitkeep b/docs/versions/v3.0.0/Components/Local/Typescript/vro-scripting-api/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vropkg/.gitkeep b/docs/versions/v3.0.0/Components/Local/Typescript/vropkg/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vropkg/README.md b/docs/versions/v3.0.0/Components/Local/Typescript/vropkg/README.md new file mode 100644 index 000000000..7fa5ce41c --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Typescript/vropkg/README.md @@ -0,0 +1,27 @@ +[//]: # (Remove Comments when you are done) +[//]: # (What is this?) + +# vropkg + +Compiles javascript code to vRO native. + +[//]: # (What will you learn) +[//]: # (Optional) + +## Overview + +[//]: # (Internal navigation) + +## Table Of Contents + +1. [Section](#section) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section + +[//]: # (Optional Section) +[//]: # (## Previous:) + +[//]: # (Optional Section) +[//]: # (## Next:) diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/General/How Does It Work.md b/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/General/How Does It Work.md new file mode 100644 index 000000000..e6c68252c --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/General/How Does It Work.md @@ -0,0 +1,42 @@ +# How does it work + +Maintainer specific details on how vrotest works + +## Overview + +`vrotest` gets executed by different Maven Mojos depending on the project archetype. The Mojos of interest are: `maven/plugins/typescript/src/main/java/com/vmware/pscoe/maven/plugins/TypescriptTestMojo.java` + +## Table Of Contents + +1. [Process](#process) +2. [Where is the test bed created](#where-is-the-test-bed-created) +3. [How is testing configured](#how-is-testing-configured) +4. [How is the vRO Runtime injected](#how-is-the-vro-runtime-injected) +5. [How are test helpers used?](#how-are-test-helpers-used) +6. [Where are the code coverage files](#where-are-the-code-coverage-files) + +### Process + +When `mvn clean test` or other maven lifecycle command that calls `test`, the `TypescriptTestMojo` is going to get called. The mojo will execute vrotest with `build` and then with `run`. + +### Where is the test bed created? + +The testbed is created under `PROJECT_ROOT/target/vro-tests` + +### How is testing configured? + +Testing is configured by adding `.nycrc` file in the `vro-tests` folder to configure code coverage and `jasmine.json` to configure the jasmine test runner. + +### How is the vRO Runtime injected? + +The vRO Scripting Api/vRO Runtime is injected as a jasmine helper in the `vro-tests/helpers` folder. The runtime injects a bunch of intrinsic classes as globals. + +More information on Jasmine Helpers, read the official documentation [here](https://jasmine.github.io/pages/docs_home.html) + +### How are test helpers used? + +Test helpers are put in the same folder as the actions, giving you the ability to import them directly. vrotsc gives us the ability to specify the location, and even tho while packaging, they go to a different folder, during testing they go to the same folder + +### Where are the code coverage files? + +THe code coverage are located under `PROJECT_ROOT/target/vro-tests/coverage`. diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/General/Usage.md b/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/General/Usage.md new file mode 100644 index 000000000..43e14726f --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/General/Usage.md @@ -0,0 +1,87 @@ +# Usage + +Provides detailed instructions on how to use vrotest + +## Overview + +The usage is divided in 2 steps + +1. `build` -> Builds the test bed +2. `run` -> Runs the unit tests + +If `mvn clean test` is run inside of the created project, build will be executed after which run will be called. + +## Table Of Contents + +1. [Building](#building) - how to build the testbed +2. [Running](#running) - how to run the tests + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Building + +#### Usage + +`vrotest build [options]` + +#### CLI options + +The following commandline options are accepted when building: + +```txt + --actions Path to the vRO JavaScript folder. + --testHelpers Path to the vRO JavaScript test helpers folder. + --tests Path to the folder containing all tests. + --maps Path to the folder containing source maps when using TypeScript. + --resources Path to the folder containing vRO resources. + --configurations Path to the folder containing vRO configurations. + --dependencies Path to the folder containing dependent vRO packages. + --helpers Path to the folder containing vRO scripting API. + --ts-src Path to the original TypeScript code. + --ts-namespace Namespace for the TypeScript project e.g. com.example.myproject + --output Folder where testbed will be created. + --coverage-thresholds Defines the threshold (in %) for the test coverage. Tests will fail if coverage is below the threshold. + Format: :: + Types: + * all + * branches + * lines + * functions + * statements + --coverage-reports Specify test coverage reports to use. + Availale values: + * text + * html + * json + * clover + * cobertura + * lcov + * lcovonly + --per-file Code coverage per file bases. Set custom --coverage-thresholds, if any file in the project drops below those thresholds, the build will fail +``` + +#### Examples + +```bash +vrotest build --actions src --testHelpers src --tests test --output target/vro-test --coverage-thresholds 50:60:all,65:70:statements --coverage-reports text,html,lcovonly +``` + +### Running + +#### Usage + +```bash +vrotest run [testbed path] [options] +``` + +#### CLI options + +The following commandline options are accepted when running tests: + +```plaintext + --instrument Instrument code and generate code coverage reports. +``` + +#### Examples + +`vrotest run target/vro-test --instrument` diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/README.md b/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/README.md new file mode 100644 index 000000000..a3a9647a5 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Typescript/vrotest/README.md @@ -0,0 +1,12 @@ +# vrotest + +`vrotest` is a utility that is used to run jasmine tests on the client machine. + +## Overview + +`vrotest` is responsible for building a test bed, instrumenting it if needed, and running jasmine tests. It enables code coverage using istanbuljs. + +## Navigation + +1. [Usage](General/Usage.md) - how to use vrotest +2. [How does it work](General/How%20Does%20It%20Work.md) diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/Components/Test Helpers.md b/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/Components/Test Helpers.md new file mode 100644 index 000000000..581b7c5cb --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/Components/Test Helpers.md @@ -0,0 +1,50 @@ +# Test Helpers + +Test helpers are compiled to a different directory than the one specified for actions. + +## Overview + +`vrotsc` gives you the ability to specify a different directory for the test helpers. Usually these files need to be excluded from vRO packaging since they are used only for testing purposes. + +## Table Of Contents + +1. [How is a test helper defined?](#how-is-a-test-helper-defined) +2. [How is a test helper compiled?](#how-is-a-test-helper-compiled) +3. [Why is there no transformer file for a testHelper](#why-is-there-no-transformer-file-for-a-testhelper) +4. [How to import a test helper](#how-to-import-a-test-helper) + +### How is a test helper defined? + +A test helper is defined by following the pattern: `*.helper.[tj]s`. + +### How is a test helper compiled? + +Due to VROES limitations, during compilation, the file name is changed from : `example.helper.ts` to `example_helper.js`. VROES works in a way where all dots AFTER the final slash will be replaced with underscores (e.g. `com.vmware.pscoe.vrotsc.actions/test.helper` gets compiled to `com.vmware.pscoe.vrotsc.actions.test_helper` ). + +### Why is there no transformer file for a testHelper? + +A Test Helper is essentially an action. Where the test helper is put is decided inside the action transformer. + +### How to import a test helper? + +The same way you would another action. + +#### Example + +`test.helper.ts`: + +```typescript +export default function (){ + return Math.random(); +} +``` + +`example.ts`: + +```typescript +import testHelper from "./test.helper"; + +export default function () { + return testHelper(); +} +``` diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/General/Usage.md b/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/General/Usage.md new file mode 100644 index 000000000..fb513751f --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/General/Usage.md @@ -0,0 +1,58 @@ +# Usage + +Provides detailed instructions on how to use vrotsc + +## Overview + +`vrotsc` has only one command to run, with different options. Detailed instructions can be found below on the possible options as well as an example. + +## Table Of Contents + +1. [Running](#running) + +### Running + +#### Usage + +```bash +vrotsc [SRC_DIR] [OPTIONS] +``` + +#### CLI options + +The following commandline options are accepted: + +```plaintext + -h, --help Print this message. + -v, --version Print the compiler's version. + -p, --project Path to the tsconfig.json file to use. + --emitHeader Emit auto-generated header on top of each file. + --actionsOut Specify the output directory for actions. + --testHelpersOut Specify the output directory for test helpers. + --workflowsOut Specify the output directory for workflows. + --configsOut Specify the output directory for configuration elements. + --resourcesOut Specify the output directory for resource elements. + --testsOut Specify the output directory for tests. + --typesOut Specify the output directory for types. + --mapsOut Specify the output directory for source maps. + --actionsNamespace Specify actions namespace. + --workflowsNamespace Specify workflows namespace. +``` + +#### Examples + +```bash +vrotsc src \ + --actionsNamespace com.vmware.pscoe.example \ + --workflowsNamespace example \ + --files \ + --typesOut target/vro-types \ + --testsOut target/vro-sources/test/com/vmware/pscoe/example \ + --mapsOut target/vro-sources/map/com/vmware/pscoe/example \ + --actionsOut target/vro-sources/js/src/main/resources/com/vmware/pscoe/example \ + --testHelpersOut target/vro-sources/testHelpers/src/main/resources/com/vmware/pscoe/example \ + --workflowsOut target/vro-sources/xml/src/main/resources/Workflow \ + --policiesOut target/vro-sources/xml/src/main/resources/PolicyTemplate \ + --resourcesOut target/vro-sources/xml/src/main/resources/ResourceElement \ + --configsOut target/vro-sources/xml/src/main/resources/ConfigurationElement +``` diff --git a/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/README.md b/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/README.md new file mode 100644 index 000000000..4784eabb9 --- /dev/null +++ b/docs/versions/v3.0.0/Components/Local/Typescript/vrotsc/README.md @@ -0,0 +1,16 @@ +# vrotsc + +`vrotsc` is a utility used to transpile typescript/other code to vRO native code. + +## Overview + +`vrotsc` is responsible for transpiling all sorts of code to native vRO code. It works with actions, workflows, configurations, resource elements, native, declarations, policy templates and tests + +[//]: # (External navigation) +[//]: # (Navigational links may have a short description after them separated by a `-`) + +## Navigation + +1. [Usage](General/Usage.md) - how to use vrotsc +2. Components + - [Test Helpers](Components/Test%20Helpers.md) - Information on test Helpers diff --git a/docs/versions/v3.0.0/Components/README.md b/docs/versions/v3.0.0/Components/README.md new file mode 100644 index 000000000..6100c925b --- /dev/null +++ b/docs/versions/v3.0.0/Components/README.md @@ -0,0 +1,23 @@ +# Build Tools for VMware Aria Components + +Navigation to different components of the Toolchain + +## Overview + +The Components are divided in 2 types. + +1. Archetypes -> Project Archetype that Build Tools for VMware Aria can generate +2. Local -> Local developer-centric documentation on how different Components of Build Tools for VMware Aria work + +[//]: # (External navigation) + +## Navigation + +1. Archetypes + * [Typescript](./Archetypes/typescript) +2. Local + * [vrotsc](./Local/Typescript/vrotsc) + * [vrotest](./Local/Typescript/vrotest) + * [vropkg](./Local/Typescript/vropkg) + * [vro-scripting-api](./Local/Typescript/vro-scripting-api) + * [polyglotpkg](./Local/Typescript/polyglotpkg) diff --git a/docs/versions/v3.0.0/General/Cheatsheets/.gitkeep b/docs/versions/v3.0.0/General/Cheatsheets/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/General/Cheatsheets/abx-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/abx-plugin-arguments.md new file mode 100644 index 000000000..c4ff113de --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/abx-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'abx-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:abx-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:abx-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/actions-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/actions-plugin-arguments.md new file mode 100644 index 000000000..fbc60bd43 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/actions-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'o11n-actions-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-actions-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-actions-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/bsc-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/bsc-plugin-arguments.md new file mode 100644 index 000000000..fe6a03249 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/bsc-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'bsc-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:bsc-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:bsc-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/cs-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/cs-plugin-arguments.md new file mode 100644 index 000000000..ff53a5aa3 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/cs-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'cs-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:cs-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:cs-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/polyglot-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/polyglot-plugin-arguments.md new file mode 100644 index 000000000..dcfc39cd9 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/polyglot-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'o11n-polyglot-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-polyglot-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-polyglot-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/ssh-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/ssh-plugin-arguments.md new file mode 100644 index 000000000..9de0360bd --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/ssh-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'ssh-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:ssh-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:ssh-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/typescript-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/typescript-plugin-arguments.md new file mode 100644 index 000000000..7d7cb629f --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/typescript-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'o11n-typescript-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-typescript-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-typescript-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/vcd-ng-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/vcd-ng-plugin-arguments.md new file mode 100644 index 000000000..d9640e860 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/vcd-ng-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'vcd-ng-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vcd-ng-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vcd-ng-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/vra-ng-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/vra-ng-plugin-arguments.md new file mode 100644 index 000000000..cf5cf1e01 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/vra-ng-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'vra-ng-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vra-ng-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vra-ng-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/vra-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/vra-plugin-arguments.md new file mode 100644 index 000000000..913df5090 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/vra-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'vra-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vra-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vra-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/vrealize-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/vrealize-plugin-arguments.md new file mode 100644 index 000000000..212e00853 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/vrealize-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'vrealize-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrealize-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrealize-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/vrli-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/vrli-plugin-arguments.md new file mode 100644 index 000000000..b675c9642 --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/vrli-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'vrli-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrli-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrli-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/vrops-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/vrops-plugin-arguments.md new file mode 100644 index 000000000..c685f806e --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/vrops-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'vrops-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:vrops-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:vrops-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Cheatsheets/xml-plugin-arguments.md b/docs/versions/v3.0.0/General/Cheatsheets/xml-plugin-arguments.md new file mode 100644 index 000000000..b9e4017aa --- /dev/null +++ b/docs/versions/v3.0.0/General/Cheatsheets/xml-plugin-arguments.md @@ -0,0 +1,11 @@ +[ERROR] +[ERROR] groupId: 'com.vmware.pscoe.maven.plugins' +[ERROR] artifactId: 'o11n-xml-package-maven-plugin' +[ERROR] version: '2.43.1-SNAPSHOT': Plugin com.vmware.pscoe.maven.plugins:o11n-xml-package-maven-plugin:2.43.1-SNAPSHOT or one of its dependencies could not be resolved: Could not find artifact com.vmware.pscoe.maven.plugins:o11n-xml-package-maven-plugin:jar:2.43.1-SNAPSHOT +[ERROR] -> [Help 1] +[ERROR] +[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. +[ERROR] Re-run Maven using the -X switch to enable full debug logging. +[ERROR] +[ERROR] For more information about the errors and possible solutions, please read the following articles: +[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException diff --git a/docs/versions/v3.0.0/General/Core Concepts.md b/docs/versions/v3.0.0/General/Core Concepts.md new file mode 100644 index 000000000..205e90d9a --- /dev/null +++ b/docs/versions/v3.0.0/General/Core Concepts.md @@ -0,0 +1,23 @@ +# Core Concepts + +[//]: # (Additional Information on the topic goes here) + +[//]: # (What will you learn) + +## Overview + +[//]: # (Internal navigation) + +## Table Of Contents + +1. [Section](#section) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section + +[//]: # (Optional Section) +[//]: # (## Previous) + +[//]: # (Optional Section) +[//]: # (## What's Next) diff --git a/docs/versions/v3.0.0/General/Examples/.gitkeep b/docs/versions/v3.0.0/General/Examples/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/General/Examples/README.md b/docs/versions/v3.0.0/General/Examples/README.md new file mode 100644 index 000000000..391157e9b --- /dev/null +++ b/docs/versions/v3.0.0/General/Examples/README.md @@ -0,0 +1,21 @@ +# Examples + +[//]: # (Additional Information on the topic goes here) + +[//]: # (What will you learn) +[//]: # (Optional) + +## Overview + +[//]: # (Internal navigation) + +## Table Of Contents + +1. [Section](#section) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section + +[//]: # (Optional Section) +[//]: # (## Read Next:) diff --git a/docs/versions/v3.0.0/General/FAQ.md b/docs/versions/v3.0.0/General/FAQ.md new file mode 100644 index 000000000..a84596cd1 --- /dev/null +++ b/docs/versions/v3.0.0/General/FAQ.md @@ -0,0 +1,17 @@ +# Frequently Asked Questions + +[//]: # (Internal navigation) + +## Table Of Contents + +1. [Section](#section-one) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section One + +[//]: # (Optional Section) +[//]: # (## Previous) + +[//]: # (Optional Section) +[//]: # (## What's Next) diff --git a/docs/versions/v3.0.0/General/Getting Started.md b/docs/versions/v3.0.0/General/Getting Started.md new file mode 100644 index 000000000..d670e4942 --- /dev/null +++ b/docs/versions/v3.0.0/General/Getting Started.md @@ -0,0 +1,19 @@ +# Getting Started + +Here you will find information on how to easily get onboarded working with Build Tools for VMware Aria. + +## Overview + +Build Tools for VMware Aria relies on a private artifact manager like JFrog Artifactory OSS ( no limitation to it being public, but possibly not desirable ). Here you will find instructions on how to setup such an environment. + +Build Tools for VMware Aria also has some local dependencies that need to be configured and we will talk about them as well. + +## Table Of Contents + +- [Prerequisites](./Getting%20Started/Prerequisites.md) +- [Setting Up Artifactory](./Getting%20Started/Setting%20Up%20Artifactory.md) +- [Setting Up Local Environment](./Getting%20Started/Setting%20Up%20Local%20Environment.md) + +## What's Next + +See [Prerequisites](./Getting Started/Prerequisites.md). diff --git a/docs/versions/v3.0.0/General/Getting Started/Prerequisites.md b/docs/versions/v3.0.0/General/Getting Started/Prerequisites.md new file mode 100644 index 000000000..937684dc4 --- /dev/null +++ b/docs/versions/v3.0.0/General/Getting Started/Prerequisites.md @@ -0,0 +1,50 @@ +# Prerequisites + +[//]: # (TODO: Update the links in the Use section after the files are moved) +[//]: # (TODO: More in Installation section?) +[//]: # (TODO: Replace all references of the setup-workstation.md to point to Prerequisites.md) + +## Overview + +Prerequisites for installation of Build Tools for VMware Aria. + +## Table Of Contents + +1. [Prerequisites](#prerequisites) +2. [Installation and Configuration](#installation-and-configuration) +3. [Usage](#usage) + +### Prerequisites + +- [vRealize Developer Tools](https://github.com/vmware/vrealize-developer-tools) (Optional) +- Java 17 +- Maven 3.5+ ([official installation guide](https://maven.apache.org/install.html)) +- NodeJS 16.x.x (use `nvm` if possible) [official downloads](https://nodejs.org/en/download/releases/) +- Development vRealize Automation Tenant configured with development vRealize Orchestrator + - Tenant administrator user + - Workstation can access vRA server on port 443 +- Development vRealize Orchestrator + - vRO administrator user + - vRO appliance root user + - Workstation can access vRO server on ports [443 or 8281], 8283 +- Powershell Core for Linux/MacOS if working with the polyglot powershell archetype. + - [MacOS]( https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-macos ) + - [Linux]( https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-linux ) + +### Installation and Configuration + +#### Configuration + +- [Build Tools for VMware Aria Build System](Setting%20Up%20Artifactory.md) + +### Usage + +- [vRO Projects](use-workstation-vro-project.md) +- [vRA Projects](use-workstation-vra-project.md) +- [vRA NG Projects](use-workstation-vra-ng-project.md) +- [ABX Projects](use-workstation-abx-project.md) +- [vROps Projects](use-workstation-vrops-project.md) + +## What's Next + +See [Setting Up Artifactory](./Setting%20Up%20Artifactory.md). diff --git a/docs/versions/v3.0.0/General/Getting Started/Setting Up Artifactory.md b/docs/versions/v3.0.0/General/Getting Started/Setting Up Artifactory.md new file mode 100644 index 000000000..b61006669 --- /dev/null +++ b/docs/versions/v3.0.0/General/Getting Started/Setting Up Artifactory.md @@ -0,0 +1,107 @@ +# Setting Up Artifactory + +[//]: # (TODO: Modernize - validate or adapt content) +[//]: # (TODO: Replace all references of the setup-platform.md to point to Setting Up Artifactory.md) + +Here you will learn the needed steps on how to configure the artifactory + +## Overview + +## Table Of Contents + +1. [Configuring Artifactory](#configuring-artifactory) +2. [Configure permissions for local cache for the Anonymous user](#configure-permissions-for-local-cache-for-the-anonymous-user) +3. [Uploading toolchain artifacts to Artifactory](#uploading-toolchain-artifacts-to-artifactory) +4. [Upload vRO artifacts to Artifactory (if needed)](#upload-vro-artifacts-to-artifactory-if-needed) + +### Configuring Artifactory + +Note that the libs-release, libs-snapshot etc. are the default Maven repositories created by JFrog's **Quick Setup** shown at first login. This guide assumes that this **Quick Setup** has been executed. + +1. Create a local repository in artifactory to contain the toolchain artifacts, e.g. **vrealize-build-tools** and add it to the virtual release repository (e.g. **libs-release**) +2. Create a remote repository and configure the maven central public repository ([https://repo1.maven.org/maven2/](https://repo1.maven.org/maven2/)). Add it to the virtual release repository (e.g. **libs-release**). This is needed so any public dependencies can be downloaded as well. + +### Configure permissions for local cache for the Anonymous user + +1. Login into Artifactory with admin privileges +2. Navigate to **Admin > Permissions** +3. Click the **New** button +4. Add a name for the permissions (for example: Anonymous Cache) +5. Add all repositories into the **Selected Repositories** list view +6. Skip the groups section +7. On the **Users** section add **Anonymous** user +8. Give **Deploy/Cache, Annotate, Read** permissions +9. Click **Save & Finish** + +### Uploading toolchain artifacts to Artifactory + +#### Via Cli + +1. Unzip **iac-maven-repository.zip** found at **artifacts/maven/** path relative to the root of the toolchain bundle to a folder, e.g. **import/** +2. Go to the directory where you have unzipped the archive. Your working directory should contain the "com" folder and the **archetype-catalog.xml** file, e.g.: + + ```bash + root@photon-G6H8GzV2j [ ~/toolchain/import ]# ls + archetype-catalog.xml com + ``` + +3. Run `jfrog config add` to configure your local environment with the artifactory server. +4. Then, run the following command + + ```jfrog rt u --recursive=true --flat=false ./* vrealize-build-tools``` + + where **vrealize-build-tools** should be the name of the repository you've created at step #1 in [Configuring Artifactory](#configuring-artifactory). + +5. Examine the output of the command. It should look something similar to this: + + ```bash + Uploading artifact: /path/to/artifact/some-artifact.jar + { + "status": "success", + "totals": { + "success": 1, + "failure": 0 + } + } + ``` + + **Note:** There is a chance that not all of the artifacts will be uploaded (you will be getting a lot of errors). If this happens, you can re-run the command. + +#### Via UI + +> **FINISH** + +### Upload vRO artifacts to Artifactory (if needed) + +First you need access to a supported version of vRO appliance to get the vRO dependencies for the toolchain in your artifactory. + +1. Get all vRO artifacts on the local machine. Run: + + ```bash + wget --no-check-certificate --recursive --no-parent --reject "index.html*" https://:/vco-repo/com/ + wget --no-check-certificate --recursive --no-parent --reject "index.html*" https://:/vco-repo/com/vmware/o11n/mojo/pkg/ + wget --no-check-certificate --recursive --no-parent --reject "index.html*" https://:/vco-repo/com/vmware/o11n/pkg + ``` + +2. Create a new local repository (e.g. **vro-local**) and add it to the virtual release repository (e.g. **libs-release**). + +3. Navigate to the root folder of the downloaded repository on the local filesystem - at the same level as the **com** directory. E.g.: + + ```bash + root@photon-G6H8GzV2j [ ~/192.168.71.1/vco-repo ]# ls + com + ``` + +4. Import the vro artifacts to the selected repository, for example: + + ```bash + jfrog rt u --recursive true --flat false ./* vro-local + ``` + +## Previous + +See [Prerequisites](./Prerequisites.md). + +## What's Next + +See [Setting Up Local Environment](./Setting%20Up%20Local%20Environment.md). diff --git a/docs/versions/v3.0.0/General/Getting Started/Setting Up Local Environment.md b/docs/versions/v3.0.0/General/Getting Started/Setting Up Local Environment.md new file mode 100644 index 000000000..96cd79f00 --- /dev/null +++ b/docs/versions/v3.0.0/General/Getting Started/Setting Up Local Environment.md @@ -0,0 +1,305 @@ +# Setting Up Local Environment + +[//]: # (TODO: Modernize - validate or adapt content) + +[//]: # (TODO: Replace all references of the setup-workstation-maven.md to point to Setting Up Local Environment.md) + +Here you will learn the needed steps on how to configure your environment + +## Overview + +**Build Tools for VMware Aria** are built on top of the Maven build automation ecosystem. vRealize Automation and vRealize Orchestrator content are described as Maven Project Object Models which enable huge amount of options like automated build going through phases like validate, compile, test, package, verify, install and deploy; dependency management, versioning, etc. + +## Table Of Contents + +1. [Installation](#installation) +2. [Configuration](#configuration) + 1. [Java Keystore](#java-keystore) + 2. [Global Configuration](#global-configuration-settingsxml) + 3. [Signing](#signing) + 4. [Bundling](#bundling) + 5. [Security](#security) + 6. [Timeouts](#timeouts) + 7. [Delays](#delays) + 8. [Checksums](#checksums) + +### Installation + +#### Prerequisites + +- Build Tools for VMware Aria Platform + - [Build Tools for VMware Aria Platform](Setting%20Up%20Artifactory.md) ready to use + - Workstation can access Build Tools for VMware Aria Platform services +- Java 17 +- Maven 3.5+ ([official installation guide](https://maven.apache.org/install.html)) + +### Configuration + +There are several things that need to be in place before you can use the Build Tools for VMware Aria to work with vRO content. + +#### Java Keystore + +Java keystore is used for signing packages build time. + +#### Create private key and certificate + +The process creates an archive called **archetype.keystore-1.0.0** (artifact name + version) containing the generated files (**archetype.keystore**, **cert.pem**, **private_key.pem** ). The archive needs to be deployed on the artifact manager. + +```sh +mkdir -p ~/cert/archetype.keystore-1.0.0 +cd ~/cert/archetype.keystore-1.0.0 + +## Create the certificates and fill in the required country,state,location,organization details ... +openssl req -newkey rsa:2048 -new -x509 -days 3650 -keyout private_key.pem -out cert.pem +keytool -genkey -v -keystore archetype.keystore -alias _dunesrsa_alias_ -keyalg RSA -keysize 2048 -validity 10000 + +cd ~/cert +zip archetype.keystore-1.0.0.zip -r archetype.keystore-1.0.0 +``` +`Note:` Its very important to note that "Email" field should be EMPTY, otherwise the vRO import will break with 400 OK error + +`Note:` JKS is a propriatary format specific to the particular JVM provider. When running above commands, ensure the keytool used is the one under the JVM that Maven would use (check with `mvn -v`). + +#### Deploy the keystore artifact + +The artifact should be deployed to any path as long as the **settings.xml** file points to it. + +Example: +- artifact group ID: com.clientname.build +- artifact ID: archetype.keystore +- artifact version: 1.0.0 +- **keystorePassword** and **vroKeyPass** passwords need to be replaced with the values used during the key generation process above +- settings section: +```xml + + com.clientname.build + archetype.keystore + target/${keystoreArtifactId}-${keystoreVersion}/archetype.keystore + 1.0.0 + {{keystorePassword}} + target/${keystoreArtifactId}-${keystoreVersion}/private_key.pem + target/${keystoreArtifactId}-${keystoreVersion}/cert.pem + {{vroKeyPass}} + +``` + +#### Global Configuration (*settings.xml*) + +Firstly, you will need to configure Maven. + +There are a number of properties that must be set through profiles in the settings.xml file, as they are environment specific: + +- keystorePassword - Required. This is the password for the keystore used for signing vRO packages. +- keystoreLocation - Required. This is the location of the keystore. You can either hardcode a location on the machine executing the build. +- snapshotRepositoryUrl - Required. This is the url of the snapshot maven repository. +- releaseRepositoryUrl - Required. This is the url of the release maven repository. Could be the same as snapshotRepositoryUrl. + +The recommended approach is to keep a settings XML file under SCM to be used by developers and a modified version with credentials for the Artifactory deployed on the CI server directly (i.e. not accessible by everyone). + +Furthermore, in the example, bundling (i.e. should the bundle.zip be produced upon build) is moved to a separate profile and developers/CI can choose whether to create the bundle or not by including the "-Pbundle" command line argument to the maven invocation. + +```xml + + + + + {vro_username} + {native+maven+encrypted+pass} + corp-dev-vro + + + {vra_username} + {native+maven+encrypted+pass} + corp-dev-vra + + + + + packaging + + + + + com.vmware.pscoe.build + archetype.keystore + 2.0.0 + target/${keystoreArtifactId}-${keystoreVersion}/private_key.pem + target/${keystoreArtifactId}-${keystoreVersion}/cert.pem + VMware1! + + + + bundle + + false + + + + artifactory + + + false + central + central + http://{artifactory-hostname}/artifactory/{release_repository} + + + true + central-snapshots + central-snapshots + http://{artifactory-hostname}/artifactory/{snapshot_repository} + + + + + false + central + central + http://{artifactory-hostname}/artifactory/{release_repository} + + + true + central-snapshots + central-snapshots + http://{artifactory-hostname}/artifactory/{snapshot_repository} + + + + http://{artifactory-hostname}/artifactory/{release_repository} + http://{artifactory-hostname}/artifactory/{snapshot_repository} + + + + + corp-dev + + + {vro_host} + {vro_port} + {vro_username} + {vro_password} + corp-dev-vro + {basic|vra} + {auth_host} + {auth_port} + {refresh_token} + http://proxy.host:80 + {vro_tenant} + + {vra_host} + {vra_port} + {vra_tenant} + corp-dev-vra + {vra_username} + {vra_password} + + + + + artifactory + packaging + + +``` + +> **Note**: {vro_username} is usually taking the form of `username@domain`. For vRO8 embedded in vRA8 with BASIC for {vro_auth} it will be required that only `username` part is specified for successful authentication. + +#### Signing + +vRO packages are signed. In order to be able to use the toolchain, you have to have a keystore and configure it in the settings.xml file both for the developers and the CI. + +##### Keystore located on the building machine + +You must have the keystore file accessible on the machine and set the **keystoreLocation** and **keystorePassword** properties through the settings.xml. + +#### Bundling + +There is a built-in bundling capabilities that are described in a Maven profile. You can decide to not only package a vRO/vRA project, but also to create a `*-bundle.zip` with all its dependencies. This will create an archive with the following structure: + +```sh +vro/ # all vRO packages. If the current project is vRO, its package will be here as well. +vra/ # all vRA packages. IF the current project is vRA, its package will be here as well. +repo/ # JARs that comprise the bundle installer - a CLI tool that is capable of importing the whole bundle to a target environment. +bin/ # shells for invoking the bundle installer CLI. + installer # Bash executable version of the installer for Linux/Unix/macOS + intasller.bat # Batch exectable version of the installer for Windows +``` + +The bundle is produced as a separate artifact during `mvn package`. To produce it, you need to add the `-Pbundle-with-installer` profile: + +```bash +mvn clean deploy -Pbundle-with-installer +``` + +To learn more about the bundle installer, check [Build Tools for VMware Aria - Bundle Installer](use-bundle-installer.md) for more information. + +#### Security + +All API calls from the toolchain (i.e. the client) verify the SSL certificate returned by vRO/vRA (i.e. the server). If you are using self-signed or third-party signed certificates, you may need to add those certificates or their CA certificates to the default JAVA keystore, i.e. `JAVA_HOME/lib/security/cacerts`. **This is the recommended approach.** + +The other option, **applicable ONLY for development environments**, is to ignore certificate checks by passing a flag. + +#### Timeouts + +Controlling timeouts is done through the following System Properties: + +- the Connection Timeout ("vrealize.connection.timeout") – the time to establish the connection with the remote host (Defaults to 360 seconds (6 minutes)) +- the Socket Timeout ("vrealize.socket.timeout") – the time waiting for data – after establishing the connection maximum time of inactivity between two data packets (Defaults to 360 seconds(6 minutes)) +- the vra 8.x content import timeout ("vrang.import.timeout") – (in miliseconds) the time out waiting for import of custom forms / content sources to complete (Defaults to 6 seconds) + +#### Delays + +- the vra 8.x data collection delay ("vrang.data.collection.delay.seconds") – (in seconds) the amount of time to way before running the import job. The vRA data collection usually takes around 10 minutes ( 600 seconds ) to complete. Defaults to no delay. + + You can set these as JVM Options as specified [here](https://maven.apache.org/configure.html) + +- Timeouts can be set up to be used by the installer too using the following settings (in the environment properties file): + - http_connection_timeout - for the connection timeout (in seconds), default is 360 seconds (6 minutes) + - http_socket_timeout - for the socket timeout (in seconds), default is 360 seconds (6 minutes) + - vrang_import_timeout - for the vra 8.x content import timeout (custom forms, content sources). + +#### Checksums + +Checksums are supported for the following project types - vRO JS, TS, XML and vRA 7/8. By defaults the target folder will also contain .sha1 checksums for the different file types, e.g. js.sha1, ts.sha1, xml.sha1, content.sha1 and packages.sha1. These are specified per project type in the base pom.xml using following definition: + +```xml + + ... + js,packages + ... + +``` + +To add more checksum definitions for your project, just redefine this property in your pom.xml. For example, add the "docs" checksum to the build: + +```xml + + ... + js,packages,docs + ... + +``` + +With the "docs" prefix you can now specify if the phase is enabled, readmes location directory, files glob filter and as well list of excludes RegExp patterns of files to ommit. For example like this: + +```xml + + ... + js,packages,docs + + true + docs/markdown + *.md + \.docx$,\.pdf$ + ... + +``` + +## Previous + +See [Setting Up Artifactory](./Setting%20Up%20Artifactory.md). diff --git a/docs/versions/v3.0.0/General/Guides/.gitkeep b/docs/versions/v3.0.0/General/Guides/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/General/Installation.md b/docs/versions/v3.0.0/General/Installation.md new file mode 100644 index 000000000..49e3e90ff --- /dev/null +++ b/docs/versions/v3.0.0/General/Installation.md @@ -0,0 +1,24 @@ +# Installation + +[//]: # (Additional Information on the topic goes here) + +[//]: # (What will you learn) +[//]: # (Optional but highly recommended) + +## Overview + +[//]: # (Internal navigation) + +## Table Of Contents + +1. [Secion](#section) + +[//]: # (Fill As many of these as you need. Use h4 and further here, do not include h1s, h2s or h3s.) + +### Section + +[//]: # (Optional Section) +[//]: # (## Previous) + +[//]: # (Optional Section) +[//]: # (## What's Next) diff --git a/docs/versions/v3.0.0/General/Known Issues/.gitkeep b/docs/versions/v3.0.0/General/Known Issues/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/General/Use Cases/.gitkeep b/docs/versions/v3.0.0/General/Use Cases/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/docs/versions/v3.0.0/README.md b/docs/versions/v3.0.0/README.md new file mode 100644 index 000000000..cad2557dc --- /dev/null +++ b/docs/versions/v3.0.0/README.md @@ -0,0 +1,22 @@ +# v3.0.0 + +Build Tools for VMware Aria is a tool that helps enterprises adhere to Infrastructure-as-Code principles in a wide variety +of VMware tools. + +## Navigation + +- [Core Concepts](./General/Core%20Concepts.md) +- [Getting Started](./General/Getting%20Started.md) +- [Installation](./General/Installation.md) +- [Use Cases](./General/Use%20Cases) +- What's next + - [Examples](./General/Examples) + - [Cheatsheets](./General/Cheatsheets) + - [Guides](./General/Guides) + - [Known Issues](./General/Known%20Issues) +- [Components](./Components) +- [FAQ](./General/FAQ.md) + +## What's Next + +See [Release](./Release.md). diff --git a/docs/versions/v3.0.0/Release.md b/docs/versions/v3.0.0/Release.md new file mode 100644 index 000000000..f1f9a81e4 --- /dev/null +++ b/docs/versions/v3.0.0/Release.md @@ -0,0 +1,149 @@ +# v3.0.0 + +## Breaking Changes + + +### *`vrang.project.id` has been removed in favor of `vrang.project.name`* + +Moving forward, `vrang.project.id` will not be accepted as part of the configuration. Instead, use `vrang.project.name`. + +`project.name` is more flexible as it will automatically find out the `project.id`. + +### *`vrang.org.id` has been removed in favor of `vrang.org.name`* + +Moving forward, `vrang.org.id` will not be accepted as part of the configuration. Instead, use `vrang.org.name`. + +`org.name` is more flexible as it will automatically find out the `org.id`. + +### *Polyglot projects will not try to fix mistakes due to issues with the manifest* + +Before, the `polyglot.json` could be defined like this: + +```json5 +{ + "platform": { + "runtime": "nodejs", // Here, this makes sense only for `ABX` projects, but not `vro` ones, which this is, looking 5 rows down + "action": "auto", + "tags": [], + "entrypoint": "out/handler.handler" + }, + "vro": { + "module": "com.vmware.pscoe.templates.buildtoolsforvmwareariasamples", + "inputs": { + "limit": "number", + "vraEndpoint": "CompositeType(host:string,base:string):VraEndpointType" + }, + "outputType": "Array/string" + }, + "files": ["%out", "!**/package.json", "!**/polyglot.json", "!**/tsconfig.json"] +} +``` +That would result the build tools to compile this correctly and default to using `node:12`. + +Now, however, you have to define the `runtime` correctly as `node:12` if you want this to work. + +This applies for automatic fixes for `vro` and `abx` types. + +### *Policy Templates's `templateVersion` is now mandatory* + +`@PolicyTemplate` decorators now **must** specify a `templateVersion`. + +The possible options are `v1` and `v2` (you can also see this in the definitions). + +```ts +@PolicyTemplate({ + name: "Sample Policy", + path: "MyOrg/MyProject", + templateVersion: "v2", // This is now mandatory + variables: { /* ... */ }, + elements: { /* ... */} +}) +``` + +## Deprecations + + +### *Deprecation of vRA 7 archetype* + +The vRA 7 Archetype and all related plugins/mojos/code are removed due to the fact that vRA 7 is Out Of Support. + +The suggested alternative is to use version 2.44.0 of the toolchain. That is the last version that supports vRA7 + +### *Deprecation of vRA 7 types* + +The `o11n-plugin-vcac` and `o11n-plugin-vcacafe` types are also removed. + +### *Deprecated Regional Content* + +The Regional content supported in previous versions of Build Tools for Aria has been removed. Unfortunately that part of the build tools never functioned the way we wanted it to, and managing the "infrastructure" tab in Assembler is no longer something we want to do as it contradicts the principles behind the `vra-ng` archetype. + +As an alternative, we suggest you use some sort of install workflow to manage them. + +## Features + + +### *Added a health check script* + +To check if the dependencies are met, you can now run: + +```sh +curl -o- https://raw.githubusercontent.com/vmware/build-tools-for-vmware-aria/main/health.sh | bash +``` + +Works for Linux,Mac and Windows with Git Bash + + + +## Improvements + +### *Flexible unit tests setup* +It is now possible to configure how the unit tests are being bootstrapped and executed. +#### Previous Behavior +Unit tests were locked to a specific version of Jasmine. +#### New Behavior +There are two out-of-the-box options for test frameworks: Jasmine and Jest. +The default behavior will be fully backwards compatible. Optionally the user is able to specify which +framework should be used as well as its version or even completely override how the unit tests are being ran. +#### Relevant Documentation +More in-depth documentation is available in the [vrotest](./../../../typescript/vrotest/) component. + + +## Upgrade procedure + +### *Polyglot projects using `nodejs` as a runtime for a `vro` project need to be migrated* + +1. Look for all of your polyglot projects made for `vro`. +2. Look for `nodejs` runtimes and change them to `node:12`. +3. Look for `powershell` runtimes and change them to `powercli:11-powershell-6.2` +4. Look for `python` runtimes and change them to `python:3.7` + +Note: + +You don't need to migrate projects if they are `abx` based. `nodejs` is the correct value for `abx` projects. + +### *Polyglot projects using vro runtimes for abx projects need to be migrated* + +1. Take a look at the documentation for the available runtimes +2. Correctly set the `vro` runtime you want to use instead of the `abx` +3. `nodejs`, `powershell` or `python` only + +### *Migrate PolicyTemplates* + +Search your projects that use `@PolicyTemplate` decorator. The `templateVersion` property is now required. Check on top for possible values + +### *Migrate away from `vrang.project.id`* + +1. Open your `settings.xml`. +2. Search for `vrang.project.id`. +3. If found, replace it with the name of the project as seen in Aria + +### *Migrate away from `vrang.org.id`* + +1. Open your `settings.xml`. +2. Search for `vrang.org.id`. +3. If found, replace it with the name of the organization as seen in Aria + +### *Modify your `environment.properties` files if in use (installer)* + +1. If you have `environment.properties` that rely on `vrang_project_id`, they should be modified to use the `vrang_project_name` +2. If you have `environment.properties` that rely on `vrang_org_id`, they should be modified to use the `vrang_org_name` diff --git a/pom.xml b/pom.xml index 487327812..24a864684 100644 --- a/pom.xml +++ b/pom.xml @@ -23,7 +23,7 @@ ${project.basedir} - 2.44.1-SNAPSHOT + 3.0.0 17 diff --git a/typescript/npmconv/package-lock.json b/typescript/npmconv/package-lock.json index ad2639af4..ae2b1ba46 100644 --- a/typescript/npmconv/package-lock.json +++ b/typescript/npmconv/package-lock.json @@ -1,12 +1,12 @@ { "name": "@vmware-pscoe/npmconv", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@vmware-pscoe/npmconv", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "license": "VMware Confidential", "dependencies": { "command-line-args": "^5.1.1", diff --git a/typescript/npmconv/package.json b/typescript/npmconv/package.json index 820c91192..eb34e1a4d 100644 --- a/typescript/npmconv/package.json +++ b/typescript/npmconv/package.json @@ -1,6 +1,6 @@ { "name": "@vmware-pscoe/npmconv", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "description": "Used for converting pure-typescript npm package to vRO project", "author": "VMware PSCoE", "license": "VMware Confidential", diff --git a/typescript/polyglotpkg/package-lock.json b/typescript/polyglotpkg/package-lock.json index 3954ddea1..85fe4b995 100644 --- a/typescript/polyglotpkg/package-lock.json +++ b/typescript/polyglotpkg/package-lock.json @@ -1,12 +1,12 @@ { "name": "@vmware-pscoe/polyglotpkg", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@vmware-pscoe/polyglotpkg", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "license": "VMware Confidential", "dependencies": { "adm-zip": "^0.4.14", diff --git a/typescript/polyglotpkg/package.json b/typescript/polyglotpkg/package.json index 5291fafd4..cb6a7c9c1 100644 --- a/typescript/polyglotpkg/package.json +++ b/typescript/polyglotpkg/package.json @@ -1,6 +1,6 @@ { "name": "@vmware-pscoe/polyglotpkg", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "description": "Create a vRO Polyglot or serverless package", "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/typescript/vro-scripting-api/package-lock.json b/typescript/vro-scripting-api/package-lock.json index 1dc4c2a2e..757b8ee34 100644 --- a/typescript/vro-scripting-api/package-lock.json +++ b/typescript/vro-scripting-api/package-lock.json @@ -1,12 +1,12 @@ { "name": "@vmware-pscoe/vro-scripting-api", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@vmware-pscoe/vro-scripting-api", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "license": "VMware Confidential", "devDependencies": { "@rollup/plugin-commonjs": "28.0.0", diff --git a/typescript/vro-scripting-api/package.json b/typescript/vro-scripting-api/package.json index 04bd23175..1307c50e0 100644 --- a/typescript/vro-scripting-api/package.json +++ b/typescript/vro-scripting-api/package.json @@ -1,6 +1,6 @@ { "name": "@vmware-pscoe/vro-scripting-api", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "VMware Confidential", "description": "vRO script API for NodeJS", diff --git a/typescript/vropkg/package-lock.json b/typescript/vropkg/package-lock.json index 4fa7b5219..d2ee286e8 100644 --- a/typescript/vropkg/package-lock.json +++ b/typescript/vropkg/package-lock.json @@ -1,12 +1,12 @@ { "name": "@vmware-pscoe/vropkg", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@vmware-pscoe/vropkg", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "bundleDependencies": [ "abstract-syntax-tree", "archiver", diff --git a/typescript/vropkg/package.json b/typescript/vropkg/package.json index 675d0f797..27338366d 100644 --- a/typescript/vropkg/package.json +++ b/typescript/vropkg/package.json @@ -1,6 +1,6 @@ { "name": "@vmware-pscoe/vropkg", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "description": "Used to build vRealize Orchestrator signed package out of it source code (expand to package XML)", "author": "VMware PSCoE", "license": "VMware Confidential", diff --git a/typescript/vrotest/package-lock.json b/typescript/vrotest/package-lock.json index bad13af53..3fe29cf07 100644 --- a/typescript/vrotest/package-lock.json +++ b/typescript/vrotest/package-lock.json @@ -1,12 +1,12 @@ { "name": "@vmware-pscoe/vrotest", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@vmware-pscoe/vrotest", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "bundleDependencies": [ "iconv-lite", "jasmine", diff --git a/typescript/vrotest/package.json b/typescript/vrotest/package.json index a3f06bc92..d72d88c1e 100644 --- a/typescript/vrotest/package.json +++ b/typescript/vrotest/package.json @@ -1,6 +1,6 @@ { "name": "@vmware-pscoe/vrotest", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "VMware Confidential", "description": "vRO Test Suite for NodeJS", diff --git a/typescript/vrotsc/package-lock.json b/typescript/vrotsc/package-lock.json index 95ac170bb..6b40655f8 100644 --- a/typescript/vrotsc/package-lock.json +++ b/typescript/vrotsc/package-lock.json @@ -1,12 +1,12 @@ { "name": "@vmware-pscoe/vrotsc", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@vmware-pscoe/vrotsc", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "license": "VMware Confidential", "bin": { "vrotsc": "bin/vrotsc" diff --git a/typescript/vrotsc/package.json b/typescript/vrotsc/package.json index e46123e97..6975f6348 100644 --- a/typescript/vrotsc/package.json +++ b/typescript/vrotsc/package.json @@ -1,6 +1,6 @@ { "name": "@vmware-pscoe/vrotsc", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "VMware Confidential", "description": "vRO TypeScript to JavaScript transpiler", diff --git a/vro-types/ecmascript/package.json b/vro-types/ecmascript/package.json index 247acda6e..878c92a99 100644 --- a/vro-types/ecmascript/package.json +++ b/vro-types/ecmascript/package.json @@ -1,5 +1,5 @@ { "name": "@types/ecmascript", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "private": true } diff --git a/vro-types/jasmine/package.json b/vro-types/jasmine/package.json index af09f67e8..54cd2d37a 100644 --- a/vro-types/jasmine/package.json +++ b/vro-types/jasmine/package.json @@ -1,5 +1,5 @@ { "name": "@types/jasmine", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "private": true } diff --git a/vro-types/node/package.json b/vro-types/node/package.json index 233bafbee..2033a4c26 100644 --- a/vro-types/node/package.json +++ b/vro-types/node/package.json @@ -1,5 +1,5 @@ { "name": "@types/node", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "private": true } diff --git a/vro-types/o11n-core/package.json b/vro-types/o11n-core/package.json index 96496167d..deab07992 100644 --- a/vro-types/o11n-core/package.json +++ b/vro-types/o11n-core/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-core", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-activedirectory/package.json b/vro-types/o11n-plugin-activedirectory/package.json index bdf0326d5..18997a6d4 100644 --- a/vro-types/o11n-plugin-activedirectory/package.json +++ b/vro-types/o11n-plugin-activedirectory/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-activedirectory", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-amqp/package.json b/vro-types/o11n-plugin-amqp/package.json index d4003e864..f0ddb770d 100644 --- a/vro-types/o11n-plugin-amqp/package.json +++ b/vro-types/o11n-plugin-amqp/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-amqp", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-apic/package.json b/vro-types/o11n-plugin-apic/package.json index 653973b2f..23a39e658 100644 --- a/vro-types/o11n-plugin-apic/package.json +++ b/vro-types/o11n-plugin-apic/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-apic", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-aria/package.json b/vro-types/o11n-plugin-aria/package.json index d0343e0a0..74e8d7e30 100644 --- a/vro-types/o11n-plugin-aria/package.json +++ b/vro-types/o11n-plugin-aria/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-aria", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-azure/package.json b/vro-types/o11n-plugin-azure/package.json index 0768a795b..a7a38a4af 100644 --- a/vro-types/o11n-plugin-azure/package.json +++ b/vro-types/o11n-plugin-azure/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-azure", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-dynamictypes/package.json b/vro-types/o11n-plugin-dynamictypes/package.json index 369d07a80..3bfb2341f 100644 --- a/vro-types/o11n-plugin-dynamictypes/package.json +++ b/vro-types/o11n-plugin-dynamictypes/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-dynamictypes", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-mail/package.json b/vro-types/o11n-plugin-mail/package.json index 0b00b07df..55394328a 100644 --- a/vro-types/o11n-plugin-mail/package.json +++ b/vro-types/o11n-plugin-mail/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-mail", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-mqtt/package.json b/vro-types/o11n-plugin-mqtt/package.json index 9492e381e..55cfe480e 100644 --- a/vro-types/o11n-plugin-mqtt/package.json +++ b/vro-types/o11n-plugin-mqtt/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-mqtt", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-net/package.json b/vro-types/o11n-plugin-net/package.json index 3c6ba75cb..67b9450e4 100644 --- a/vro-types/o11n-plugin-net/package.json +++ b/vro-types/o11n-plugin-net/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-net", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-nsx/package.json b/vro-types/o11n-plugin-nsx/package.json index a41d71dbb..f70afc946 100644 --- a/vro-types/o11n-plugin-nsx/package.json +++ b/vro-types/o11n-plugin-nsx/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-nsx", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-powershell/package.json b/vro-types/o11n-plugin-powershell/package.json index a4b7cd254..9e2c76db9 100644 --- a/vro-types/o11n-plugin-powershell/package.json +++ b/vro-types/o11n-plugin-powershell/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-powershell", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-rest/package.json b/vro-types/o11n-plugin-rest/package.json index 65a74bc7d..c253983e5 100644 --- a/vro-types/o11n-plugin-rest/package.json +++ b/vro-types/o11n-plugin-rest/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-rest", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-snmp/package.json b/vro-types/o11n-plugin-snmp/package.json index d375a6a03..6d5f42985 100644 --- a/vro-types/o11n-plugin-snmp/package.json +++ b/vro-types/o11n-plugin-snmp/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-snmp", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-soap/package.json b/vro-types/o11n-plugin-soap/package.json index a57e7033d..8a5f47323 100644 --- a/vro-types/o11n-plugin-soap/package.json +++ b/vro-types/o11n-plugin-soap/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-soap", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-sql/package.json b/vro-types/o11n-plugin-sql/package.json index 35a5b249a..5c6cc73b5 100644 --- a/vro-types/o11n-plugin-sql/package.json +++ b/vro-types/o11n-plugin-sql/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-sql", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-ssh/package.json b/vro-types/o11n-plugin-ssh/package.json index 45abaf7e4..51bf00253 100644 --- a/vro-types/o11n-plugin-ssh/package.json +++ b/vro-types/o11n-plugin-ssh/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-ssh", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-vapi/package.json b/vro-types/o11n-plugin-vapi/package.json index a6a61e97f..932d40a9f 100644 --- a/vro-types/o11n-plugin-vapi/package.json +++ b/vro-types/o11n-plugin-vapi/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-vapi", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-vc/package.json b/vro-types/o11n-plugin-vc/package.json index 7ecdbdce1..3f0fadaa9 100644 --- a/vro-types/o11n-plugin-vc/package.json +++ b/vro-types/o11n-plugin-vc/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-vc", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-vcloud/package.json b/vro-types/o11n-plugin-vcloud/package.json index cde4910cc..e8a69f165 100644 --- a/vro-types/o11n-plugin-vcloud/package.json +++ b/vro-types/o11n-plugin-vcloud/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-vcloud", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-vco/package.json b/vro-types/o11n-plugin-vco/package.json index 3e5c9c046..9bfdc2d5d 100644 --- a/vro-types/o11n-plugin-vco/package.json +++ b/vro-types/o11n-plugin-vco/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-vco", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/o11n-plugin-xml/package.json b/vro-types/o11n-plugin-xml/package.json index bda0faee6..bb4566263 100644 --- a/vro-types/o11n-plugin-xml/package.json +++ b/vro-types/o11n-plugin-xml/package.json @@ -1,6 +1,6 @@ { "name": "@types/o11n-plugin-xml", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true diff --git a/vro-types/tslib/package.json b/vro-types/tslib/package.json index 7d6cff003..b7829647b 100644 --- a/vro-types/tslib/package.json +++ b/vro-types/tslib/package.json @@ -1,6 +1,6 @@ { "name": "tslib", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "description": "TypeScript compiler requires that tslib library is installed as a NodeJS module. VRO is using separate implementation for tslib, so this library will just provide the types.", "license": "ISC", diff --git a/vro-types/vrotsc-annotations/package.json b/vro-types/vrotsc-annotations/package.json index c9786a4d4..20a25157a 100644 --- a/vro-types/vrotsc-annotations/package.json +++ b/vro-types/vrotsc-annotations/package.json @@ -1,6 +1,6 @@ { "name": "@types/vrotsc-annotations", - "version": "2.44.1-SNAPSHOT", + "version": "3.0.0", "author": "VMware PSCoE", "license": "ISC", "private": true