Class Component
java.lang.Object
com.microservices.starter.core.environment.Component
- All Implemented Interfaces:
DomainAware
,EnabledAware
,Identifiable
,Serializable
- Direct Known Subclasses:
FlexComponent
,LibraryComponent
Represents a component in the Broadleaf microservice ecosystem. In the manifest structure, it is
used to represent flexpackages, and individual service library components.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
boolean
An alternative name used to identify the component.Identifies information based on the type of datasource leveraged by the service library component.Domain (DNS) information used at runtime for dynamic application configuration to negotiate gateway routing and interservice communication appropriately based on the deployed environment.Whether or not the component is enabled.getName()
The name used to identify the component.Name to use for this component when creating packages for the Java classpath during code directory and project generation.getPorts()
The ports exposed and supported by the component.int
hashCode()
void
setAltName
(String altName) void
setDataSource
(DataSource dataSource) Identifies information based on the type of datasource leveraged by the service library component.void
Domain (DNS) information used at runtime for dynamic application configuration to negotiate gateway routing and interservice communication appropriately based on the deployed environment.void
setEnabled
(Boolean enabled) void
void
setPackageIdentifier
(String packageIdentifier) Name to use for this component when creating packages for the Java classpath during code directory and project generation.void
toString()
-
Constructor Details
-
Component
public Component()
-
-
Method Details
-
getName
Description copied from interface:Identifiable
The name used to identify the component. Required.- Specified by:
getName
in interfaceDomainAware
- Specified by:
getName
in interfaceEnabledAware
- Specified by:
getName
in interfaceIdentifiable
-
getAltName
Description copied from interface:Identifiable
An alternative name used to identify the component. Generally the longer version of the name for those components with long or descriptive names. Optional.- Specified by:
getAltName
in interfaceIdentifiable
-
getDataSource
Identifies information based on the type of datasource leveraged by the service library component. This is a special case setting that allows a service to forgo data routing in favor of a single, non-routed datasource. Requires the service is not deployed to a composite flexpackage (granular only). This generally only applies to auth. Optional. Composite datasource assumed by default. -
getPackageIdentifier
Name to use for this component when creating packages for the Java classpath during code directory and project generation. Generally used to workaround component names that are Java reserved words (like `import`). By default, the component name is used (or the altName, if specified). However, care should be taken when using altName, as by convention, various other artifacts depend on that value for naming. Optional. -
getDomain
Description copied from interface:Identifiable
Domain (DNS) information used at runtime for dynamic application configuration to negotiate gateway routing and interservice communication appropriately based on the deployed environment. Required.- Specified by:
getDomain
in interfaceDomainAware
- Specified by:
getDomain
in interfaceIdentifiable
-
getEnabled
Description copied from interface:Identifiable
Whether or not the component is enabled. Disabled flexpackage components are not included in docker-compose and are not included in generated project structure, disabled service library components are not included in generated project structure (in which case it is assumed Broadleaf's out-of-the-box version is used), and disabled "other" components are not included in docker-compose. Required.- Specified by:
getEnabled
in interfaceEnabledAware
- Specified by:
getEnabled
in interfaceIdentifiable
-
getPorts
Description copied from interface:Identifiable
The ports exposed and supported by the component. Required.- Specified by:
getPorts
in interfaceIdentifiable
-
setName
-
setAltName
-
setDataSource
Identifies information based on the type of datasource leveraged by the service library component. This is a special case setting that allows a service to forgo data routing in favor of a single, non-routed datasource. Requires the service is not deployed to a composite flexpackage (granular only). This generally only applies to auth. Optional. Composite datasource assumed by default. -
setPackageIdentifier
Name to use for this component when creating packages for the Java classpath during code directory and project generation. Generally used to workaround component names that are Java reserved words (like `import`). By default, the component name is used (or the altName, if specified). However, care should be taken when using altName, as by convention, various other artifacts depend on that value for naming. Optional. -
setDomain
Description copied from interface:DomainAware
Domain (DNS) information used at runtime for dynamic application configuration to negotiate gateway routing and interservice communication appropriately based on the deployed environment. Required.- Specified by:
setDomain
in interfaceDomainAware
-
setEnabled
- Specified by:
setEnabled
in interfaceEnabledAware
-
setPorts
-
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-