Create-Federation

The create-federation command accepts the same flags as the create-app command, and follows mostly the same behavior. The key difference is that this command accepts multiple project names following the services flag, and will generate a project (with the specified profile and features) for each name supplied. The [NAME] argument will be used to create the top-level multi-project build for the federation.

Table 5. Create-Federation Flags
FlagDescriptionExample

-s, —services

Comma-separated list of services (applications) to create

—services users,inventory,billing

-b, —build

Build tool (one of gradle, maven - default is gradle)

—build maven

-p, —profile

Profile to use for all projects in the federation (default is service)

—profile function-aws

-f, —features

Features to use for all projects in the federation, comma-separated

  1. features security-jwt,mongo-gorm

or

  1. -f security-jwt -f mongo-gorm

-i, —inplace

If present, generates the project in the current directory (project name is optional if this flag is set)

—inplace

When creating a federation, a top-level project file will be generated (using the chosen build tool), and subprojects/modules will be created for each service in the federation.