Annotation Interface ComponentId


@Target({FIELD,PARAMETER}) @Retention(RUNTIME) @Documented @MinMuleVersion("4.5.0") public @interface ComponentId
Marks a Component's ParameterModel as the Component ID. Being a Component ID means that the value associated to the annotated parameter can be used to reference the component in a mule application uniquely across all the instances of the same ComponentModel. When used on a global element of the application, then this Component ID serves as a global ID in the application.

An example of a ComponentModel ID is the name parameter of a config element.

Restrictions apply in order for a ParameterModel to be a ComponentModel ID:

  • Only one parameter can be ComponentId for any given ComponentModel
  • Only required parameters serve as Component ID
  • The parameter's type has to be String
  • The parameter's expression support will be ExpressionSupport#NOT_SUPPORTED, so no dynamic values are allowed
  • Content qualifier is not allowed for a Component ID
  • Text qualifier is not allowed for a Component ID
  • Query qualifier is not allowed for a Component ID
  • Defaulting to a ConfigOverride is not allowed for a Component ID since it describes the ID of each individual component and no common global value should be used as ID
Since:
1.0