Search in sources :

Example 1 with AttributeDefinition

use of org.mule.runtime.dsl.api.component.AttributeDefinition in project mule by mulesoft.

the class BeanDefinitionFactory method getWrapperIdentifierAndTypeMap.

private <T> Map<String, WrapperElementType> getWrapperIdentifierAndTypeMap(ComponentBuildingDefinition<T> buildingDefinition) {
    final Map<String, WrapperElementType> wrapperIdentifierAndTypeMap = new HashMap<>();
    AbstractAttributeDefinitionVisitor wrapperIdentifiersCollector = new AbstractAttributeDefinitionVisitor() {

        @Override
        public void onComplexChildCollection(Class<?> type, Optional<String> wrapperIdentifierOptional) {
            wrapperIdentifierOptional.ifPresent(wrapperIdentifier -> wrapperIdentifierAndTypeMap.put(wrapperIdentifier, COLLECTION));
        }

        @Override
        public void onComplexChild(Class<?> type, Optional<String> wrapperIdentifierOptional, Optional<String> childIdentifier) {
            wrapperIdentifierOptional.ifPresent(wrapperIdentifier -> wrapperIdentifierAndTypeMap.put(wrapperIdentifier, SINGLE));
        }

        @Override
        public void onComplexChildMap(Class<?> keyType, Class<?> valueType, String wrapperIdentifier) {
            wrapperIdentifierAndTypeMap.put(wrapperIdentifier, MAP);
        }

        @Override
        public void onMultipleValues(KeyAttributeDefinitionPair[] definitions) {
            for (KeyAttributeDefinitionPair attributeDefinition : definitions) {
                attributeDefinition.getAttributeDefinition().accept(this);
            }
        }
    };
    Consumer<AttributeDefinition> collectWrappersConsumer = attributeDefinition -> attributeDefinition.accept(wrapperIdentifiersCollector);
    buildingDefinition.getSetterParameterDefinitions().stream().map(setterAttributeDefinition -> setterAttributeDefinition.getAttributeDefinition()).forEach(collectWrappersConsumer);
    buildingDefinition.getConstructorAttributeDefinition().stream().forEach(collectWrappersConsumer);
    return wrapperIdentifierAndTypeMap;
}
Also used : KeyAttributeDefinitionPair(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair) CORE_PREFIX(org.mule.runtime.internal.dsl.DslConstants.CORE_PREFIX) BeanReference(org.springframework.beans.factory.config.BeanReference) Optional.of(java.util.Optional.of) BiFunction(java.util.function.BiFunction) ErrorTypeRepository(org.mule.runtime.api.exception.ErrorTypeRepository) DESCRIPTION_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.DESCRIPTION_IDENTIFIER) BeanDefinitionRegistry(org.springframework.beans.factory.support.BeanDefinitionRegistry) SECURITY_MANAGER_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.SECURITY_MANAGER_IDENTIFIER) MULE_PROPERTY_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.MULE_PROPERTY_IDENTIFIER) SingleErrorTypeMatcher(org.mule.runtime.core.api.exception.SingleErrorTypeMatcher) MVELExpressionLanguage(org.mule.runtime.core.internal.el.mvel.MVELExpressionLanguage) Map(java.util.Map) MULE_EE_DOMAIN_IDENTIFIER(org.mule.runtime.config.api.dsl.CoreDslConstants.MULE_EE_DOMAIN_IDENTIFIER) DEFAULT_OBJECT_SERIALIZER_NAME(org.mule.runtime.api.serialization.ObjectSerializer.DEFAULT_OBJECT_SERIALIZER_NAME) RAISE_ERROR_IDENTIFIER(org.mule.runtime.config.api.dsl.CoreDslConstants.RAISE_ERROR_IDENTIFIER) MULE_DOMAIN_IDENTIFIER(org.mule.runtime.config.api.dsl.CoreDslConstants.MULE_DOMAIN_IDENTIFIER) ANNOTATIONS_ELEMENT_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.ANNOTATIONS_ELEMENT_IDENTIFIER) ERROR_MAPPING_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.ERROR_MAPPING_IDENTIFIER) ImmutableSet(com.google.common.collect.ImmutableSet) SpringConfigurationComponentLocator(org.mule.runtime.config.internal.SpringConfigurationComponentLocator) Set(java.util.Set) MuleRuntimeException(org.mule.runtime.api.exception.MuleRuntimeException) ServiceLoader(java.util.ServiceLoader) CommonBeanDefinitionCreator.areMatchingTypes(org.mule.runtime.config.internal.dsl.spring.CommonBeanDefinitionCreator.areMatchingTypes) String.format(java.lang.String.format) ComponentBuildingDefinition(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition) List(java.util.List) ErrorType(org.mule.runtime.api.message.ErrorType) Optional(java.util.Optional) ANNOTATION_NAME(org.mule.runtime.core.internal.component.ComponentAnnotations.ANNOTATION_NAME) SpringComponentModel(org.mule.runtime.config.internal.dsl.model.SpringComponentModel) ANNOTATION_PARAMETERS(org.mule.runtime.core.internal.component.ComponentAnnotations.ANNOTATION_PARAMETERS) DOC_DESCRIPTION_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.DOC_DESCRIPTION_IDENTIFIER) RetryPolicyTemplate(org.mule.runtime.core.api.retry.policy.RetryPolicyTemplate) ComponentBuildingDefinitionRegistry(org.mule.runtime.config.api.dsl.model.ComponentBuildingDefinitionRegistry) OBJECT_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.OBJECT_IDENTIFIER) ErrorMapping(org.mule.runtime.core.internal.exception.ErrorMapping) ComponentIdentifier.buildFromStringRepresentation(org.mule.runtime.api.component.ComponentIdentifier.buildFromStringRepresentation) OBJECT_EXPRESSION_LANGUAGE(org.mule.runtime.core.api.config.MuleProperties.OBJECT_EXPRESSION_LANGUAGE) HashMap(java.util.HashMap) AtomicReference(java.util.concurrent.atomic.AtomicReference) HashSet(java.util.HashSet) MAP(org.mule.runtime.config.internal.dsl.spring.WrapperElementType.MAP) MULE_IDENTIFIER(org.mule.runtime.config.api.dsl.CoreDslConstants.MULE_IDENTIFIER) SINGLE(org.mule.runtime.config.internal.dsl.spring.WrapperElementType.SINGLE) COLLECTION(org.mule.runtime.config.internal.dsl.spring.WrapperElementType.COLLECTION) Component(org.mule.runtime.api.component.Component) BiConsumer(java.util.function.BiConsumer) ComponentModelHelper.addAnnotation(org.mule.runtime.config.internal.dsl.spring.ComponentModelHelper.addAnnotation) BeanDefinition(org.springframework.beans.factory.config.BeanDefinition) OBJECT_DEFAULT_RETRY_POLICY_TEMPLATE(org.mule.runtime.core.api.config.MuleProperties.OBJECT_DEFAULT_RETRY_POLICY_TEMPLATE) LOCATION_KEY(org.mule.runtime.api.component.AbstractComponent.LOCATION_KEY) MULE_PROPERTIES_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.MULE_PROPERTIES_IDENTIFIER) GLOBAL_PROPERTY_IDENTIFIER(org.mule.runtime.config.internal.model.ApplicationModel.GLOBAL_PROPERTY_IDENTIFIER) I18nMessageFactory.createStaticMessage(org.mule.runtime.api.i18n.I18nMessageFactory.createStaticMessage) AttributeDefinition(org.mule.runtime.dsl.api.component.AttributeDefinition) AbstractAttributeDefinitionVisitor(org.mule.runtime.config.api.dsl.processor.AbstractAttributeDefinitionVisitor) ErrorTypeMatcher(org.mule.runtime.core.api.exception.ErrorTypeMatcher) Consumer(java.util.function.Consumer) Either(org.mule.runtime.core.api.functional.Either) Collectors.toList(java.util.stream.Collectors.toList) ConfigurationPropertiesProviderFactory(org.mule.runtime.config.api.dsl.model.properties.ConfigurationPropertiesProviderFactory) Element(org.w3c.dom.Element) ComponentModel(org.mule.runtime.config.internal.model.ComponentModel) CONFIGURATION_IDENTIFIER(org.mule.runtime.config.api.dsl.CoreDslConstants.CONFIGURATION_IDENTIFIER) ANNOTATION_ERROR_MAPPINGS(org.mule.runtime.core.internal.exception.ErrorMapping.ANNOTATION_ERROR_MAPPINGS) ComponentIdentifier(org.mule.runtime.api.component.ComponentIdentifier) Optional(java.util.Optional) HashMap(java.util.HashMap) KeyAttributeDefinitionPair(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair) AbstractAttributeDefinitionVisitor(org.mule.runtime.config.api.dsl.processor.AbstractAttributeDefinitionVisitor) AttributeDefinition(org.mule.runtime.dsl.api.component.AttributeDefinition)

Example 2 with AttributeDefinition

use of org.mule.runtime.dsl.api.component.AttributeDefinition in project mule by mulesoft.

the class ComponentConfigurationBuilder method processConfiguration.

public void processConfiguration() {
    componentBuildingDefinition.getIgnoredConfigurationParameters().stream().forEach(simpleParameters::remove);
    for (SetterAttributeDefinition setterAttributeDefinition : componentBuildingDefinition.getSetterParameterDefinitions()) {
        AttributeDefinition attributeDefinition = setterAttributeDefinition.getAttributeDefinition();
        attributeDefinition.accept(setterVisitor(setterAttributeDefinition.getAttributeName(), attributeDefinition));
    }
    for (AttributeDefinition attributeDefinition : componentBuildingDefinition.getConstructorAttributeDefinition()) {
        attributeDefinition.accept(constructorVisitor());
    }
}
Also used : SetterAttributeDefinition(org.mule.runtime.dsl.api.component.SetterAttributeDefinition) AttributeDefinition(org.mule.runtime.dsl.api.component.AttributeDefinition) SetterAttributeDefinition(org.mule.runtime.dsl.api.component.SetterAttributeDefinition)

Example 3 with AttributeDefinition

use of org.mule.runtime.dsl.api.component.AttributeDefinition in project mule by mulesoft.

the class ExtensionDefinitionParser method parse.

/**
 * Creates a list of {@link ComponentBuildingDefinition} built on copies of {@link #baseDefinitionBuilder}. It also sets the
 * parsed parsed parameters on the backing {@link AbstractExtensionObjectFactory}
 *
 * @return a list with the generated {@link ComponentBuildingDefinition}
 * @throws ConfigurationException if a parsing error occurs
 */
public final List<ComponentBuildingDefinition> parse() throws ConfigurationException {
    Builder builder = baseDefinitionBuilder;
    builder = doParse(builder);
    AttributeDefinition parametersDefinition = fromFixedValue(new HashMap<>()).build();
    if (!parameters.isEmpty()) {
        KeyAttributeDefinitionPair[] attributeDefinitions = parameters.entrySet().stream().map(entry -> newBuilder().withAttributeDefinition(entry.getValue().build()).withKey(entry.getKey()).build()).toArray(KeyAttributeDefinitionPair[]::new);
        parametersDefinition = fromMultipleDefinitions(attributeDefinitions).build();
    }
    builder = builder.withSetterParameterDefinition("parameters", parametersDefinition);
    addDefinition(builder.build());
    return parsedDefinitions;
}
Also used : InfrastructureTypeMapping.getNameMap(org.mule.runtime.module.extension.internal.loader.java.type.InfrastructureTypeMapping.getNameMap) ExpressionBasedParameterResolverValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.ExpressionBasedParameterResolverValueResolver) StaticValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.StaticValueResolver) KeyAttributeDefinitionPair(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair) InfrastructureParameterModelProperty(org.mule.runtime.extension.api.property.InfrastructureParameterModelProperty) BEHAVIOUR(org.mule.runtime.api.meta.model.parameter.ParameterRole.BEHAVIOUR) ParameterRole(org.mule.runtime.api.meta.model.parameter.ParameterRole) DateTimeType(org.mule.metadata.api.model.DateTimeType) RequiredParameterValueResolverWrapper(org.mule.runtime.module.extension.internal.runtime.resolver.RequiredParameterValueResolverWrapper) Builder.fromSimpleParameter(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromSimpleParameter) QueryParameterModelProperty(org.mule.runtime.module.extension.internal.loader.java.property.QueryParameterModelProperty) Instant.ofEpochMilli(java.time.Instant.ofEpochMilli) ArrayType(org.mule.metadata.api.model.ArrayType) Map(java.util.Map) NestableElementModelVisitor(org.mule.runtime.api.meta.model.nested.NestableElementModelVisitor) ExpressionTypedValueValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.ExpressionTypedValueValueResolver) ClassTypeLoader(org.mule.metadata.api.ClassTypeLoader) ModelProperty(org.mule.runtime.api.meta.model.ModelProperty) NestableElementModel(org.mule.runtime.api.meta.model.nested.NestableElementModel) ExtensionModelUtils.isContent(org.mule.runtime.extension.api.util.ExtensionModelUtils.isContent) SchedulingStrategyParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.SchedulingStrategyParsingDelegate) ExtensionMetadataTypeUtils.isMap(org.mule.runtime.extension.api.util.ExtensionMetadataTypeUtils.isMap) IntrospectionUtils.isTargetParameter(org.mule.runtime.module.extension.internal.util.IntrospectionUtils.isTargetParameter) ObjectType(org.mule.metadata.api.model.ObjectType) ParameterGroupDescriptor(org.mule.runtime.module.extension.internal.loader.ParameterGroupDescriptor) Set(java.util.Set) MuleRuntimeException(org.mule.runtime.api.exception.MuleRuntimeException) DateType(org.mule.metadata.api.model.DateType) MetadataTypeVisitor(org.mule.metadata.api.visitor.MetadataTypeVisitor) ZoneId(java.time.ZoneId) ComponentBuildingDefinition(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition) DefaultValueResolverParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.DefaultValueResolverParsingDelegate) DateTimeParseException(java.time.format.DateTimeParseException) ObjectFieldType(org.mule.metadata.api.model.ObjectFieldType) StringType(org.mule.metadata.api.model.StringType) MetadataType(org.mule.metadata.api.model.MetadataType) DslSyntaxResolver(org.mule.runtime.extension.api.dsl.syntax.resolver.DslSyntaxResolver) IntrospectionUtils.getContainerName(org.mule.runtime.module.extension.internal.util.IntrospectionUtils.getContainerName) ParameterResolverValueResolverWrapper(org.mule.runtime.module.extension.internal.runtime.resolver.ParameterResolverValueResolverWrapper) DefaultConversionService(org.springframework.core.convert.support.DefaultConversionService) StackedTypesModelProperty.getStackedTypesModelProperty(org.mule.runtime.module.extension.internal.loader.java.property.stackabletypes.StackedTypesModelProperty.getStackedTypesModelProperty) NativeQueryParameterValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.NativeQueryParameterValueResolver) MetadataTypeUtils.getDefaultValue(org.mule.metadata.api.utils.MetadataTypeUtils.getDefaultValue) ExtensionsTypeLoaderFactory(org.mule.runtime.extension.api.declaration.type.ExtensionsTypeLoaderFactory) StackedTypesModelProperty(org.mule.runtime.module.extension.internal.loader.java.property.stackabletypes.StackedTypesModelProperty) LocalDateTime(java.time.LocalDateTime) Builder.fromChildMapConfiguration(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildMapConfiguration) VALUE_ATTRIBUTE_NAME(org.mule.runtime.internal.dsl.DslConstants.VALUE_ATTRIBUTE_NAME) Supplier(java.util.function.Supplier) ObjectTypeParameterParser(org.mule.runtime.module.extension.internal.config.dsl.parameter.ObjectTypeParameterParser) ArrayList(java.util.ArrayList) TypeSafeValueResolverWrapper(org.mule.runtime.module.extension.internal.runtime.resolver.TypeSafeValueResolverWrapper) LinkedHashMap(java.util.LinkedHashMap) Calendar(java.util.Calendar) ExtensionMetadataTypeUtils.getExpressionSupport(org.mule.runtime.extension.api.util.ExtensionMetadataTypeUtils.getExpressionSupport) TypedInlineParameterGroupParser(org.mule.runtime.module.extension.internal.config.dsl.parameter.TypedInlineParameterGroupParser) MediaTypeValueResolverParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.MediaTypeValueResolverParsingDelegate) ConversionService(org.springframework.core.convert.ConversionService) TypeDefinition.fromType(org.mule.runtime.dsl.api.component.TypeDefinition.fromType) MuleExtensionUtils.isExpression(org.mule.runtime.module.extension.internal.util.MuleExtensionUtils.isExpression) ParameterizedModel(org.mule.runtime.api.meta.model.parameter.ParameterizedModel) ValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.ValueResolver) ConfigurationException(org.mule.runtime.core.api.config.ConfigurationException) I18nMessageFactory.createStaticMessage(org.mule.runtime.api.i18n.I18nMessageFactory.createStaticMessage) ParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.ParsingDelegate) Builder.fromMultipleDefinitions(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromMultipleDefinitions) ExtensionModel(org.mule.runtime.api.meta.model.ExtensionModel) Reference(org.mule.runtime.api.util.Reference) DefaultObjectParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.DefaultObjectParsingDelegate) NOT_SUPPORTED(org.mule.runtime.api.meta.ExpressionSupport.NOT_SUPPORTED) JavaTypeUtils.getType(org.mule.metadata.java.api.utils.JavaTypeUtils.getType) ExtensionMetadataTypeUtils.getId(org.mule.runtime.extension.api.util.ExtensionMetadataTypeUtils.getId) TemplateParser(org.mule.runtime.core.privileged.util.TemplateParser) IntrospectionUtils.getMemberName(org.mule.runtime.module.extension.internal.util.IntrospectionUtils.getMemberName) Date(java.util.Date) Builder.fromChildConfiguration(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildConfiguration) TypeConverter(org.mule.runtime.dsl.api.component.TypeConverter) IntrospectionUtils.isLiteral(org.mule.runtime.module.extension.internal.util.IntrospectionUtils.isLiteral) TypeDefinition.fromMapEntryType(org.mule.runtime.dsl.api.component.TypeDefinition.fromMapEntryType) ProcessorChainValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.ProcessorChainValueResolver) IntrospectionUtils.isTypedValue(org.mule.runtime.module.extension.internal.util.IntrospectionUtils.isTypedValue) TypedValueValueResolverWrapper(org.mule.runtime.module.extension.internal.runtime.resolver.TypedValueValueResolverWrapper) PoolingProfile(org.mule.runtime.api.config.PoolingProfile) ParameterGroupModel(org.mule.runtime.api.meta.model.parameter.ParameterGroupModel) Builder.fromChildCollectionConfiguration(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildCollectionConfiguration) ISODateTimeFormat(org.joda.time.format.ISODateTimeFormat) ObjectParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.ObjectParsingDelegate) Collection(java.util.Collection) REQUIRED(org.mule.runtime.api.meta.ExpressionSupport.REQUIRED) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) Instant(java.time.Instant) String.format(java.lang.String.format) NestedRouteModel(org.mule.runtime.api.meta.model.nested.NestedRouteModel) List(java.util.List) DslElementSyntax(org.mule.runtime.extension.api.dsl.syntax.DslElementSyntax) LocalDate(java.time.LocalDate) Optional(java.util.Optional) Builder(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition.Builder) CharsetValueResolverParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.CharsetValueResolverParsingDelegate) TlsContextFactory(org.mule.runtime.api.tls.TlsContextFactory) ParameterModel(org.mule.runtime.api.meta.model.parameter.ParameterModel) RetryPolicyTemplate(org.mule.runtime.core.api.retry.policy.RetryPolicyTemplate) TypeSafeExpressionValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.TypeSafeExpressionValueResolver) KeyAttributeDefinitionPair.newBuilder(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair.newBuilder) Builder.fromSimpleReferenceParameter(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromSimpleReferenceParameter) HashMap(java.util.HashMap) Processor(org.mule.runtime.core.api.processor.Processor) Builder.fromFixedValue(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromFixedValue) ConcurrentMap(java.util.concurrent.ConcurrentMap) ValueResolverParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.ValueResolverParsingDelegate) HashSet(java.util.HashSet) ExtensionMetadataTypeUtils.isFlattenedParameterGroup(org.mule.runtime.extension.api.util.ExtensionMetadataTypeUtils.isFlattenedParameterGroup) ImmutableList(com.google.common.collect.ImmutableList) Literal(org.mule.runtime.extension.api.runtime.parameter.Literal) BasicTypeMetadataVisitor(org.mule.metadata.api.visitor.BasicTypeMetadataVisitor) ParameterGroupModelProperty(org.mule.runtime.module.extension.internal.loader.java.property.ParameterGroupModelProperty) ExclusiveOptionalModelProperty(org.mule.runtime.module.extension.internal.loader.java.property.ExclusiveOptionalModelProperty) Collections.emptyMap(java.util.Collections.emptyMap) Collections.emptySet(java.util.Collections.emptySet) NameUtils.hyphenize(org.mule.runtime.extension.api.util.NameUtils.hyphenize) IntrospectionUtils.isParameterResolver(org.mule.runtime.module.extension.internal.util.IntrospectionUtils.isParameterResolver) ExpressionSupport(org.mule.runtime.api.meta.ExpressionSupport) NestedChainModel(org.mule.runtime.api.meta.model.nested.NestedChainModel) DateTime(org.joda.time.DateTime) AttributeDefinition(org.mule.runtime.dsl.api.component.AttributeDefinition) AnonymousInlineParameterGroupParser(org.mule.runtime.module.extension.internal.config.dsl.parameter.AnonymousInlineParameterGroupParser) Collectors.toList(java.util.stream.Collectors.toList) ExtensionMetadataTypeUtils(org.mule.runtime.extension.api.util.ExtensionMetadataTypeUtils) RouteComponentParser(org.mule.runtime.module.extension.internal.config.dsl.construct.RouteComponentParser) FixedTypeParsingDelegate(org.mule.runtime.module.extension.internal.config.dsl.object.FixedTypeParsingDelegate) NestedComponentModel(org.mule.runtime.api.meta.model.nested.NestedComponentModel) TopLevelParameterObjectFactory(org.mule.runtime.module.extension.internal.config.dsl.parameter.TopLevelParameterObjectFactory) ImplementingTypeModelProperty(org.mule.runtime.module.extension.internal.loader.java.property.ImplementingTypeModelProperty) StaticLiteralValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.StaticLiteralValueResolver) LinkedHashMap(java.util.LinkedHashMap) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) HashMap(java.util.HashMap) Builder(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition.Builder) KeyAttributeDefinitionPair.newBuilder(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair.newBuilder) KeyAttributeDefinitionPair(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair) AttributeDefinition(org.mule.runtime.dsl.api.component.AttributeDefinition)

Example 4 with AttributeDefinition

use of org.mule.runtime.dsl.api.component.AttributeDefinition in project mule by mulesoft.

the class CoreComponentBuildingDefinitionProvider method getComponentBuildingDefinitions.

@Override
public List<ComponentBuildingDefinition> getComponentBuildingDefinitions() {
    LinkedList<ComponentBuildingDefinition> componentBuildingDefinitions = new LinkedList<>();
    AttributeDefinition messageProcessorListAttributeDefinition = fromChildCollectionConfiguration(Processor.class).build();
    ComponentBuildingDefinition.Builder onErrorBaseBuilder = baseDefinition.withSetterParameterDefinition(MESSAGE_PROCESSORS, messageProcessorListAttributeDefinition).withSetterParameterDefinition(WHEN, fromSimpleParameter(WHEN).build()).withSetterParameterDefinition(ERROR_TYPE, fromSimpleParameter(TYPE).build()).withSetterParameterDefinition(LOG_EXCEPTION, fromSimpleParameter(LOG_EXCEPTION).withDefaultValue("true").build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(ON_ERROR).withTypeDefinition(fromType(TemplateOnErrorHandler.class)).withObjectFactoryType(OnErrorFactoryBean.class).withConstructorParameterDefinition(fromSimpleReferenceParameter("ref").build()).build());
    componentBuildingDefinitions.add(onErrorBaseBuilder.withIdentifier(ON_ERROR_CONTINUE).withTypeDefinition(fromType(OnErrorContinueHandler.class)).asPrototype().build());
    componentBuildingDefinitions.add(onErrorBaseBuilder.withIdentifier(ON_ERROR_PROPAGATE).withTypeDefinition(fromType(OnErrorPropagateHandler.class)).asPrototype().build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(ERROR_HANDLER).withTypeDefinition(fromType(ErrorHandler.class)).withObjectFactoryType(ErrorHandlerFactoryBean.class).withSetterParameterDefinition("delegate", fromSimpleReferenceParameter("ref").build()).withSetterParameterDefinition(NAME, fromSimpleParameter(NAME).build()).withSetterParameterDefinition("exceptionListeners", fromChildCollectionConfiguration(FlowExceptionHandler.class).build()).asPrototype().build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(SET_PAYLOAD).withTypeDefinition(fromType(SetPayloadMessageProcessor.class)).withSetterParameterDefinition("value", fromSimpleParameter("value").build()).withSetterParameterDefinition("mimeType", fromSimpleParameter("mimeType").build()).withSetterParameterDefinition("encoding", fromSimpleParameter("encoding").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(LOGGER).withTypeDefinition(fromType(LoggerMessageProcessor.class)).withSetterParameterDefinition("message", fromSimpleParameter("message").build()).withSetterParameterDefinition("category", fromSimpleParameter("category").build()).withSetterParameterDefinition("level", fromSimpleParameter("level").build()).build());
    componentBuildingDefinitions.add(getSetVariablePropertyBaseBuilder(getAddVariableTransformerInstanceFactory(AddFlowVariableProcessor.class), AddFlowVariableProcessor.class, newBuilder().withKey("identifier").withAttributeDefinition(fromSimpleParameter("variableName").build()).build(), newBuilder().withKey("value").withAttributeDefinition(fromSimpleParameter("value").build()).build()).withIdentifier("set-variable").withTypeDefinition(fromType(AddFlowVariableProcessor.class)).build());
    componentBuildingDefinitions.add(getCoreMuleMessageTransformerBaseBuilder().withIdentifier("remove-variable").withTypeDefinition(fromType(RemoveFlowVariableProcessor.class)).withSetterParameterDefinition("identifier", fromSimpleParameter("variableName").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("global-property").withTypeDefinition(fromType(String.class)).withConstructorParameterDefinition(fromSimpleParameter("value").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(TRANSFORMER).withTypeDefinition(fromType(Transformer.class)).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(CUSTOM_PROCESSOR).withTypeDefinition(fromConfigurationAttribute(CLASS_ATTRIBUTE).checkingThatIsClassOrInheritsFrom(MESSAGE_PROCESSOR_CLASS)).asPrototype().build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(PROCESSOR_CHAIN).withTypeDefinition(fromType(AnnotatedProcessor.class)).withObjectFactoryType(MessageProcessorChainObjectFactory.class).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).asPrototype().build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(ROUTE).withTypeDefinition(fromType(MessageProcessorChain.class)).withObjectFactoryType(MessageProcessorChainFactoryBean.class).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).asPrototype().build());
    addModuleOperationChainParser(componentBuildingDefinitions);
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(SUB_FLOW).withTypeDefinition(fromType(MessageProcessorChain.class)).withObjectFactoryType(SubflowMessageProcessorChainFactoryBean.class).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).withSetterParameterDefinition(NAME, fromSimpleParameter(NAME).build()).asPrototype().build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(RESPONSE).withTypeDefinition(fromType(ResponseMessageProcessorAdapter.class)).withObjectFactoryType(ResponseMessageProcessorsFactoryBean.class).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(FLOW).withTypeDefinition(fromType(Flow.class)).withObjectFactoryType(DefaultFlowFactoryBean.class).withSetterParameterDefinition(NAME, fromSimpleParameter(NAME).build()).withSetterParameterDefinition("muleContext", fromReferenceObject(MuleContext.class).build()).withSetterParameterDefinition("initialState", fromSimpleParameter("initialState").withDefaultValue(INITIAL_STATE_STARTED).build()).withSetterParameterDefinition("messageSource", fromChildConfiguration(MessageSource.class).build()).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).withSetterParameterDefinition(EXCEPTION_LISTENER_ATTRIBUTE, fromChildConfiguration(FlowExceptionHandler.class).build()).withSetterParameterDefinition("maxConcurrency", fromSimpleParameter("maxConcurrency").build()).build());
    Builder processorRefBuilder = baseDefinition.withTypeDefinition(fromType(AnnotatedProcessor.class)).withObjectFactoryType(FlowRefFactoryBean.class).withSetterParameterDefinition("muleContext", fromReferenceObject(MuleContext.class).build());
    componentBuildingDefinitions.add(processorRefBuilder.withIdentifier(FLOW_REF).withSetterParameterDefinition("name", fromSimpleParameter("name").build()).withSetterParameterDefinition("target", fromSimpleParameter("target").build()).withSetterParameterDefinition("targetValue", fromSimpleParameter("targetValue").withDefaultValue("#[payload]").build()).build());
    componentBuildingDefinitions.add(processorRefBuilder.withIdentifier(PROCESSOR).withSetterParameterDefinition("name", fromSimpleParameter("ref").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(COLLECT_LIST).withTypeDefinition(fromType(CollectListForkJoinStrategyFactory.class)).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(SCATTER_GATHER).withTypeDefinition(fromType(ScatterGatherRouter.class)).withSetterParameterDefinition("timeout", fromSimpleParameter("timeout").build()).withSetterParameterDefinition("maxConcurrency", fromSimpleParameter("maxConcurrency").build()).withSetterParameterDefinition("target", fromSimpleParameter("target").build()).withSetterParameterDefinition("targetValue", fromSimpleParameter("targetValue").withDefaultValue("#[payload]").build()).withSetterParameterDefinition(ROUTES, fromChildCollectionConfiguration(MessageProcessorChain.class).build()).withSetterParameterDefinition(FORK_JOIN_STRATEGY, fromChildConfiguration(ForkJoinStrategyFactory.class).build()).asScope().build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(SPLIT_AGGREGATE).withTypeDefinition(fromType(SplitAggregateScope.class)).withSetterParameterDefinition("collectionExpression", fromChildConfiguration(String.class).withIdentifier("collection").build()).withSetterParameterDefinition("timeout", fromSimpleParameter("timeout").build()).withSetterParameterDefinition("maxConcurrency", fromSimpleParameter("maxConcurrency").build()).withSetterParameterDefinition("target", fromSimpleParameter("target").build()).withSetterParameterDefinition("targetValue", fromSimpleParameter("targetValue").withDefaultValue("#[payload]").build()).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).asScope().build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("collection").withTypeDefinition(fromType(String.class)).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(ENRICHER).withObjectFactoryType(MessageEnricherObjectFactory.class).withTypeDefinition(fromType(MessageEnricher.class)).withSetterParameterDefinition("messageProcessor", fromChildConfiguration(Processor.class).build()).withSetterParameterDefinition("enrichExpressionPairs", fromChildCollectionConfiguration(MessageEnricher.EnrichExpressionPair.class).build()).withSetterParameterDefinition("source", fromSimpleParameter("source").build()).withSetterParameterDefinition("target", fromSimpleParameter("target").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("enrich").withTypeDefinition(fromType(MessageEnricher.EnrichExpressionPair.class)).withConstructorParameterDefinition(fromSimpleParameter("source").build()).withConstructorParameterDefinition(fromSimpleParameter("target").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(ASYNC).withTypeDefinition(fromType(AsyncDelegateMessageProcessor.class)).withObjectFactoryType(AsyncMessageProcessorsFactoryBean.class).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).withSetterParameterDefinition(NAME, fromSimpleParameter(NAME).build()).withSetterParameterDefinition("maxConcurrency", fromSimpleParameter("maxConcurrency").build()).build());
    // TODO MULE-12726 Remove TryProcessorFactoryBean
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(TRY).withTypeDefinition(fromType(TryScope.class)).withObjectFactoryType(TryProcessorFactoryBean.class).withSetterParameterDefinition("exceptionListener", fromChildConfiguration(FlowExceptionHandler.class).build()).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).withSetterParameterDefinition(TX_ACTION, fromSimpleParameter(TX_ACTION).withDefaultValue(ACTION_INDIFFERENT_STRING).build()).withSetterParameterDefinition(TX_TYPE, fromSimpleParameter(TX_TYPE, getTransactionTypeConverter()).withDefaultValue(LOCAL.name()).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(UNTIL_SUCCESSFUL).withTypeDefinition(fromType(UntilSuccessful.class)).withSetterParameterDefinition("maxRetries", fromSimpleParameter("maxRetries").withDefaultValue(5).build()).withSetterParameterDefinition("millisBetweenRetries", fromSimpleParameter("millisBetweenRetries").withDefaultValue(60000).build()).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(FOREACH).withTypeDefinition(fromType(Foreach.class)).withSetterParameterDefinition("collectionExpression", fromSimpleParameter("collection").build()).withSetterParameterDefinition("batchSize", fromSimpleParameter("batchSize").build()).withSetterParameterDefinition("rootMessageVariableName", fromSimpleParameter("rootMessageVariableName").build()).withSetterParameterDefinition("counterVariableName", fromSimpleParameter("counterVariableName").build()).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(FIRST_SUCCESSFUL).withTypeDefinition(fromType(FirstSuccessful.class)).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(MessageProcessorChain.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(ROUND_ROBIN).withTypeDefinition(fromType(RoundRobin.class)).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(MessageProcessorChain.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(CHOICE).withTypeDefinition(fromType(ChoiceRouter.class)).withObjectFactoryType(ChoiceRouterObjectFactory.class).withSetterParameterDefinition("routes", fromChildCollectionConfiguration(MessageProcessorExpressionPair.class).build()).withSetterParameterDefinition("defaultRoute", fromChildConfiguration(MessageProcessorExpressionPair.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(WHEN).withTypeDefinition(fromType(MessageProcessorExpressionPair.class)).withObjectFactoryType(MessageProcessorFilterPairFactoryBean.class).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).withSetterParameterDefinition("expression", fromSimpleParameter("expression").withDefaultValue("true").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(OTHERWISE).withTypeDefinition(fromType(MessageProcessorExpressionPair.class)).withObjectFactoryType(MessageProcessorFilterPairFactoryBean.class).withSetterParameterDefinition(MESSAGE_PROCESSORS, fromChildCollectionConfiguration(Processor.class).build()).withSetterParameterDefinition("expression", fromFixedValue("true").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("message-chunk-splitter").withTypeDefinition(fromType(MessageChunkSplitter.class)).withSetterParameterDefinition("messageSize", fromSimpleParameter("messageSize").build()).build());
    ComponentBuildingDefinition.Builder baseAggregatorDefinition = baseDefinition.withSetterParameterDefinition("timeout", fromSimpleParameter("timeout").build()).withSetterParameterDefinition("failOnTimeout", fromSimpleParameter("failOnTimeout").build()).withSetterParameterDefinition("processedGroupsObjectStore", fromSimpleReferenceParameter("processed-groups-object-store").build()).withSetterParameterDefinition("eventGroupsObjectStore", fromSimpleReferenceParameter("event-groups-object-store").build()).withSetterParameterDefinition("persistentStores", fromSimpleParameter("persistentStores").build()).withSetterParameterDefinition("storePrefix", fromSimpleParameter("storePrefix").build());
    componentBuildingDefinitions.add(baseAggregatorDefinition.withIdentifier("message-chunk-aggregator").withTypeDefinition(fromType(MessageChunkAggregator.class)).build());
    componentBuildingDefinitions.add(baseAggregatorDefinition.withIdentifier("collection-aggregator").withTypeDefinition(fromType(SimpleCollectionAggregator.class)).build());
    componentBuildingDefinitions.add(baseAggregatorDefinition.withIdentifier("resequencer").withTypeDefinition(fromType(Resequencer.class)).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("splitter").withTypeDefinition(fromType(Splitter.class)).withSetterParameterDefinition("expression", fromSimpleParameter("expression").build()).withSetterParameterDefinition("filterOnErrorType", fromSimpleParameter("filterOnErrorType").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(REQUEST_REPLY).withTypeDefinition(fromType(SimpleAsyncRequestReplyRequester.class)).withSetterParameterDefinition("messageProcessor", fromChildConfiguration(Processor.class).build()).withSetterParameterDefinition("messageSource", fromChildConfiguration(MessageSource.class).build()).withSetterParameterDefinition("timeout", fromSimpleParameter("timeout").build()).withSetterParameterDefinition("storePrefix", fromSimpleParameter("storePrefix").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(SCHEDULER).withTypeDefinition(fromType(DefaultSchedulerMessageSource.class)).withObjectFactoryType(SchedulingMessageSourceFactoryBean.class).withSetterParameterDefinition("disallowConcurrentExecution", fromSimpleParameter("disallowConcurrentExecution").withDefaultValue(true).build()).withSetterParameterDefinition("scheduler", fromChildConfiguration(PeriodicScheduler.class).withWrapperIdentifier(SCHEDULING_STRATEGY_ELEMENT_IDENTIFIER).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(FIXED_FREQUENCY_STRATEGY_ELEMENT_IDENTIFIER).withTypeDefinition(fromType(FixedFrequencyScheduler.class)).withSetterParameterDefinition("frequency", fromSimpleParameter("frequency").build()).withSetterParameterDefinition("startDelay", fromSimpleParameter("startDelay").build()).withSetterParameterDefinition("timeUnit", fromSimpleParameter("timeUnit").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(CRON_STRATEGY_ELEMENT_IDENTIFIER).withTypeDefinition(fromType(CronScheduler.class)).withSetterParameterDefinition("expression", fromSimpleParameter("expression").build()).withSetterParameterDefinition("timeZone", fromSimpleParameter("timeZone").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("configuration").withTypeDefinition(fromType(MuleConfiguration.class)).withObjectFactoryType(MuleConfigurationConfigurator.class).withSetterParameterDefinition("defaultErrorHandlerName", fromSimpleParameter("defaultErrorHandler-ref").build()).withSetterParameterDefinition("defaultResponseTimeout", fromSimpleParameter("defaultResponseTimeout").build()).withSetterParameterDefinition("maxQueueTransactionFilesSize", fromSimpleParameter("maxQueueTransactionFilesSize").build()).withSetterParameterDefinition("defaultTransactionTimeout", fromSimpleParameter("defaultTransactionTimeout").build()).withSetterParameterDefinition("shutdownTimeout", fromSimpleParameter("shutdownTimeout").build()).withSetterParameterDefinition("defaultTransactionTimeout", fromSimpleParameter("defaultTransactionTimeout").build()).withSetterParameterDefinition("useExtendedTransformations", fromSimpleParameter("useExtendedTransformations").build()).withSetterParameterDefinition("flowEndingWithOneWayEndpointReturnsNull", fromSimpleParameter("flowEndingWithOneWayEndpointReturnsNull").build()).withSetterParameterDefinition("enricherPropagatesSessionVariableChanges", fromSimpleParameter("enricherPropagatesSessionVariableChanges").build()).withSetterParameterDefinition("defaultObjectSerializer", fromSimpleReferenceParameter("defaultObjectSerializer-ref").build()).withSetterParameterDefinition("extensions", fromChildCollectionConfiguration(ConfigurationExtension.class).build()).withSetterParameterDefinition("dynamicConfigExpiration", fromChildConfiguration(DynamicConfigExpiration.class).build()).withSetterParameterDefinition("extensions", fromChildCollectionConfiguration(Object.class).build()).alwaysEnabled(true).withRegistrationName(OBJECT_MULE_CONFIGURATION).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("dynamic-config-expiration").withTypeDefinition(fromType(DynamicConfigExpiration.class)).withObjectFactoryType(DynamicConfigExpirationObjectFactory.class).withConstructorParameterDefinition(fromSimpleParameter("frequency").withDefaultValue(DYNAMIC_CONFIG_EXPIRATION_FREQUENCY.getTime()).build()).withConstructorParameterDefinition(fromSimpleParameter("timeUnit", value -> TimeUnit.valueOf((String) value)).withDefaultValue(DYNAMIC_CONFIG_EXPIRATION_FREQUENCY.getUnit()).build()).withSetterParameterDefinition("expirationPolicy", fromChildConfiguration(ExpirationPolicy.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("expiration-policy").withTypeDefinition(fromType(ExpirationPolicy.class)).withObjectFactoryType(ExpirationPolicyObjectFactory.class).withSetterParameterDefinition("maxIdleTime", fromSimpleParameter("maxIdleTime").withDefaultValue(DYNAMIC_CONFIG_EXPIRATION_FREQUENCY.getTime()).build()).withSetterParameterDefinition("timeUnit", fromSimpleParameter("timeUnit", value -> TimeUnit.valueOf((String) value)).withDefaultValue(DYNAMIC_CONFIG_EXPIRATION_FREQUENCY.getUnit()).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("notifications").withTypeDefinition(fromType(ServerNotificationManagerConfigurator.class)).withSetterParameterDefinition("notificationDynamic", fromSimpleParameter("dynamic").build()).withSetterParameterDefinition("enabledNotifications", fromChildCollectionConfiguration(NotificationConfig.EnabledNotificationConfig.class).build()).withSetterParameterDefinition("disabledNotifications", fromChildCollectionConfiguration(NotificationConfig.DisabledNotificationConfig.class).build()).withSetterParameterDefinition("notificationListeners", fromChildCollectionConfiguration(ListenerSubscriptionPair.class).build()).build());
    ComponentBuildingDefinition.Builder baseNotificationDefinition = baseDefinition.withSetterParameterDefinition("interfaceName", fromSimpleParameter("interface").build()).withSetterParameterDefinition("eventName", fromSimpleParameter("event").build()).withSetterParameterDefinition("interfaceClass", fromSimpleParameter("interface-class").build()).withSetterParameterDefinition("eventClass", fromSimpleParameter("event-class").build());
    componentBuildingDefinitions.add(baseNotificationDefinition.withTypeDefinition(fromType(NotificationConfig.EnabledNotificationConfig.class)).withIdentifier("notification").build());
    componentBuildingDefinitions.add(baseNotificationDefinition.withTypeDefinition(fromType(NotificationConfig.DisabledNotificationConfig.class)).withIdentifier("disable-notification").build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("notification-listener").withTypeDefinition(fromType(ListenerSubscriptionPair.class)).withConstructorParameterDefinition(fromSimpleReferenceParameter("ref").build()).withConstructorParameterDefinition(fromSimpleParameter("subscription", getNotificationSubscriptionConverter()).withDefaultValue(ANY_SELECTOR_STRING).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("username-password-filter").withTypeDefinition(fromType(UsernamePasswordAuthenticationFilter.class)).withSetterParameterDefinition("username", fromSimpleParameter("username").build()).withSetterParameterDefinition("password", fromSimpleParameter("password").build()).withIgnoredConfigurationParameter(NAME).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("custom-security-filter").withTypeDefinition(fromType(Processor.class)).withObjectFactoryType(CustomSecurityFilterObjectFactory.class).withConstructorParameterDefinition(fromSimpleReferenceParameter("ref").build()).withIgnoredConfigurationParameter(NAME).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("encryption-security-filter").withTypeDefinition(fromType(MuleEncryptionEndpointSecurityFilter.class)).withConstructorParameterDefinition(fromSimpleReferenceParameter("strategy-ref").build()).withIgnoredConfigurationParameter(NAME).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("security-manager").withTypeDefinition(fromType(SecurityManager.class)).withObjectFactoryType(MuleSecurityManagerConfigurator.class).withSetterParameterDefinition("muleContext", fromReferenceObject(MuleContext.class).build()).withSetterParameterDefinition("name", fromSimpleParameter("name").build()).withSetterParameterDefinition("providers", fromChildCollectionConfiguration(SecurityProvider.class).build()).withSetterParameterDefinition("encryptionStrategies", fromChildCollectionConfiguration(EncryptionStrategy.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("custom-security-provider").withTypeDefinition(fromType(CustomSecurityProviderDelegate.class)).withConstructorParameterDefinition(fromSimpleReferenceParameter("provider-ref").build()).withConstructorParameterDefinition(fromSimpleParameter("name").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("custom-encryption-strategy").withTypeDefinition(fromType(CustomEncryptionStrategyDelegate.class)).withConstructorParameterDefinition(fromSimpleReferenceParameter("strategy-ref").build()).withConstructorParameterDefinition(fromSimpleParameter("name").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("secret-key-encryption-strategy").withTypeDefinition(fromType(SecretKeyEncryptionStrategy.class)).withSetterParameterDefinition("name", fromSimpleParameter("name").build()).withSetterParameterDefinition("key", fromSimpleParameter("key").build()).withSetterParameterDefinition("keyFactory", fromSimpleReferenceParameter("keyFactory-ref").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("password-encryption-strategy").withTypeDefinition(fromType(PasswordBasedEncryptionStrategy.class)).withSetterParameterDefinition("name", fromSimpleParameter("name").build()).withSetterParameterDefinition("iterationCount", fromSimpleParameter("iterationCount").build()).withSetterParameterDefinition("password", fromSimpleParameter("password").build()).withSetterParameterDefinition("salt", fromSimpleParameter("salt").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(REDELIVERY_POLICY_ELEMENT_IDENTIFIER).withTypeDefinition(fromType(IdempotentRedeliveryPolicy.class)).withSetterParameterDefinition("maxRedeliveryCount", fromSimpleParameter("maxRedeliveryCount").build()).withSetterParameterDefinition("useSecureHash", fromSimpleParameter("useSecureHash").build()).withSetterParameterDefinition("messageDigestAlgorithm", fromSimpleParameter("messageDigestAlgorithm").build()).withSetterParameterDefinition("idExpression", fromSimpleParameter("idExpression").build()).withSetterParameterDefinition("objectStore", fromSimpleReferenceParameter("objectStore").build()).withSetterParameterDefinition("privateObjectStore", fromChildConfiguration(ValueResolver.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("pooling-profile").withTypeDefinition(fromType(PoolingProfile.class)).withSetterParameterDefinition("maxActive", fromSimpleParameter("maxActive").build()).withSetterParameterDefinition("maxIdle", fromSimpleParameter("maxIdle").build()).withSetterParameterDefinition("exhaustedAction", fromSimpleParameter("exhaustedAction", PoolingProfile.POOL_EXHAUSTED_ACTIONS::get).build()).withSetterParameterDefinition("maxWait", fromSimpleParameter("maxWait").build()).withSetterParameterDefinition("evictionCheckIntervalMillis", fromSimpleParameter("evictionCheckIntervalMillis").build()).withSetterParameterDefinition("minEvictionMillis", fromSimpleParameter("minEvictionMillis").build()).withSetterParameterDefinition("disabled", fromSimpleParameter("disabled").build()).withSetterParameterDefinition("initialisationPolicy", fromSimpleParameter("initialisationPolicy", PoolingProfile.POOL_INITIALISATION_POLICIES::get).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("expression-component").withTypeDefinition(fromType(ExpressionLanguageComponent.class)).withSetterParameterDefinition("expression", fromTextContent().build()).withSetterParameterDefinition("expressionFile", fromSimpleParameter("file").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("invoke").withTypeDefinition(fromType(InvokerMessageProcessor.class)).withSetterParameterDefinition("name", fromSimpleParameter("name").build()).withSetterParameterDefinition("methodName", fromSimpleParameter("method").build()).withSetterParameterDefinition("argumentExpressionsString", fromSimpleParameter("methodArguments").build()).withSetterParameterDefinition("object", fromSimpleReferenceParameter("object-ref").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("expression-language").withTypeDefinition(fromType(MVELExpressionLanguage.class)).withObjectFactoryType(MVELExpressionLanguageObjectFactory.class).withSetterParameterDefinition("autoResolveVariables", fromSimpleParameter("autoResolveVariables").build()).withSetterParameterDefinition("globalFunctions", fromChildConfiguration(MVELGlobalFunctionsConfig.class).build()).withSetterParameterDefinition("imports", fromChildCollectionConfiguration(ImportEntry.class).build()).withSetterParameterDefinition("aliases", fromChildCollectionConfiguration(AliasEntry.class).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("import").withTypeDefinition(fromType(ImportEntry.class)).withSetterParameterDefinition("key", fromSimpleParameter("name").build()).withSetterParameterDefinition("value", fromSimpleParameter("class", stringToClassConverter()).build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("alias").withTypeDefinition(fromType(AliasEntry.class)).withSetterParameterDefinition("key", fromSimpleParameter("name").build()).withSetterParameterDefinition("value", fromSimpleParameter("expression").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier("global-functions").withTypeDefinition(fromType(MVELGlobalFunctionsConfig.class)).withSetterParameterDefinition("file", fromSimpleParameter("file").build()).withSetterParameterDefinition("inlineScript", fromTextContent().build()).build());
    componentBuildingDefinitions.addAll(getTransformersBuildingDefinitions());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(POOLING_PROFILE_ELEMENT_IDENTIFIER).withTypeDefinition(fromType(PoolingProfile.class)).withConstructorParameterDefinition(fromSimpleParameter("maxActive").withDefaultValue(DEFAULT_MAX_POOL_ACTIVE).build()).withConstructorParameterDefinition(fromSimpleParameter("maxIdle").withDefaultValue(DEFAULT_MAX_POOL_IDLE).build()).withConstructorParameterDefinition(fromSimpleParameter("maxWait", value -> Long.valueOf((String) value)).withDefaultValue(valueOf(DEFAULT_MAX_POOL_WAIT)).build()).withConstructorParameterDefinition(fromSimpleParameter("exhaustedAction", POOL_EXHAUSTED_ACTIONS::get).withDefaultValue(valueOf(DEFAULT_POOL_EXHAUSTED_ACTION)).build()).withConstructorParameterDefinition(fromSimpleParameter("initialisationPolicy", POOL_INITIALISATION_POLICIES::get).withDefaultValue(valueOf(DEFAULT_POOL_INITIALISATION_POLICY)).build()).withSetterParameterDefinition("disabled", fromSimpleParameter("disabled").build()).build());
    componentBuildingDefinitions.add(baseDefinition.withIdentifier(RAISE_ERROR).withTypeDefinition(fromType(RaiseErrorProcessor.class)).withSetterParameterDefinition("type", fromSimpleParameter("type").build()).withSetterParameterDefinition("description", fromSimpleParameter("description").build()).build());
    componentBuildingDefinitions.addAll(getStreamingDefinitions());
    componentBuildingDefinitions.addAll(getIdempotentValidatorsDefinitions());
    componentBuildingDefinitions.addAll(getReconnectionDefinitions());
    componentBuildingDefinitions.addAll(getTransactionDefinitions());
    return componentBuildingDefinitions;
}
Also used : MessageEnricher(org.mule.runtime.core.internal.enricher.MessageEnricher) DYNAMIC_CONFIG_EXPIRATION_FREQUENCY(org.mule.runtime.extension.api.ExtensionConstants.DYNAMIC_CONFIG_EXPIRATION_FREQUENCY) KeyAttributeDefinitionPair(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair) DEFAULT_BYTE_STREAMING_BUFFER_SIZE(org.mule.runtime.extension.api.ExtensionConstants.DEFAULT_BYTE_STREAMING_BUFFER_SIZE) ExpirationPolicy(org.mule.runtime.extension.api.runtime.ExpirationPolicy) REDELIVERY_POLICY_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.REDELIVERY_POLICY_ELEMENT_IDENTIFIER) Arrays.asList(java.util.Arrays.asList) Map(java.util.Map) DynamicConfigExpirationObjectFactory(org.mule.runtime.config.internal.factories.DynamicConfigExpirationObjectFactory) DEFAULT_POOL_INITIALISATION_POLICY(org.mule.runtime.api.config.PoolingProfile.DEFAULT_POOL_INITIALISATION_POLICY) ComponentBuildingDefinitionProviderUtils.createNewInstance(org.mule.runtime.config.api.dsl.model.ComponentBuildingDefinitionProviderUtils.createNewInstance) ObjectToByteArray(org.mule.runtime.core.internal.transformer.simple.ObjectToByteArray) TemplateOnErrorHandler(org.mule.runtime.core.privileged.exception.TemplateOnErrorHandler) RECONNECT_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.RECONNECT_ELEMENT_IDENTIFIER) StringAppendTransformer(org.mule.runtime.core.internal.transformer.simple.StringAppendTransformer) Transformer(org.mule.runtime.core.api.transformer.Transformer) MessageProcessorExpressionPair(org.mule.runtime.core.internal.routing.MessageProcessorExpressionPair) HexStringToByteArray(org.mule.runtime.core.internal.transformer.simple.HexStringToByteArray) NON_REPEATABLE_OBJECTS_STREAM_ALIAS(org.mule.runtime.extension.api.declaration.type.StreamingStrategyTypeBuilder.NON_REPEATABLE_OBJECTS_STREAM_ALIAS) SubflowMessageProcessorChainFactoryBean(org.mule.runtime.config.internal.factories.SubflowMessageProcessorChainFactoryBean) MessageEnricherObjectFactory(org.mule.runtime.config.internal.dsl.processor.factory.MessageEnricherObjectFactory) EncryptionTransformer(org.mule.runtime.core.internal.transformer.encryption.EncryptionTransformer) ArrayUtils.addAll(org.apache.commons.lang3.ArrayUtils.addAll) MVELExpressionLanguageObjectFactory(org.mule.runtime.core.internal.el.mvel.configuration.MVELExpressionLanguageObjectFactory) Builder.fromChildMapConfiguration(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildMapConfiguration) SimpleCollectionAggregator(org.mule.runtime.core.internal.routing.SimpleCollectionAggregator) LoggerMessageProcessor(org.mule.runtime.core.internal.processor.LoggerMessageProcessor) DecryptionTransformer(org.mule.runtime.core.internal.transformer.encryption.DecryptionTransformer) DEFAULT_BYTE_STREAMING_BUFFER_DATA_UNIT(org.mule.runtime.extension.api.ExtensionConstants.DEFAULT_BYTE_STREAMING_BUFFER_DATA_UNIT) ErrorHandler(org.mule.runtime.core.internal.exception.ErrorHandler) GZipCompressTransformer(org.mule.runtime.core.internal.transformer.compression.GZipCompressTransformer) ValueResolver(org.mule.runtime.module.extension.internal.runtime.resolver.ValueResolver) ApplicationModel(org.mule.runtime.config.internal.model.ApplicationModel) Boolean.parseBoolean(java.lang.Boolean.parseBoolean) TreeMap(java.util.TreeMap) CommonTypeConverters.stringToClassConverter(org.mule.runtime.dsl.api.component.CommonTypeConverters.stringToClassConverter) MuleEncryptionEndpointSecurityFilter(org.mule.runtime.core.internal.security.filter.MuleEncryptionEndpointSecurityFilter) DEFAULT_OBJECT_STREAMING_MAX_BUFFER_SIZE(org.mule.runtime.extension.api.ExtensionConstants.DEFAULT_OBJECT_STREAMING_MAX_BUFFER_SIZE) MuleConfiguration(org.mule.runtime.core.api.config.MuleConfiguration) DEFAULT_MAX_POOL_ACTIVE(org.mule.runtime.api.config.PoolingProfile.DEFAULT_MAX_POOL_ACTIVE) SCHEDULING_STRATEGY_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.SCHEDULING_STRATEGY_ELEMENT_IDENTIFIER) SecurityManager(org.mule.runtime.core.api.security.SecurityManager) RECONNECT_FOREVER_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.RECONNECT_FOREVER_ELEMENT_IDENTIFIER) AbstractAddVariablePropertyProcessor(org.mule.runtime.core.privileged.processor.simple.AbstractAddVariablePropertyProcessor) Builder.fromChildConfiguration(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildConfiguration) NotificationConfig(org.mule.runtime.config.internal.NotificationConfig) AddVariablePropertyConfigurator(org.mule.runtime.config.privileged.dsl.processor.AddVariablePropertyConfigurator) OnErrorFactoryBean(org.mule.runtime.config.internal.factories.OnErrorFactoryBean) ScatterGatherRouter(org.mule.runtime.core.internal.routing.ScatterGatherRouter) TypeConverter(org.mule.runtime.dsl.api.component.TypeConverter) TypeDefinition.fromMapEntryType(org.mule.runtime.dsl.api.component.TypeDefinition.fromMapEntryType) MVELExpressionLanguage(org.mule.runtime.core.internal.el.mvel.MVELExpressionLanguage) ConfigurableObjectFactory(org.mule.runtime.config.api.dsl.ConfigurableObjectFactory) REPEATABLE_IN_MEMORY_BYTES_STREAM_ALIAS(org.mule.runtime.extension.api.declaration.type.StreamingStrategyTypeBuilder.REPEATABLE_IN_MEMORY_BYTES_STREAM_ALIAS) PoolingProfile(org.mule.runtime.api.config.PoolingProfile) AbstractServerNotification(org.mule.runtime.api.notification.AbstractServerNotification) Preconditions.checkState(org.mule.runtime.api.util.Preconditions.checkState) EnvironmentPropertyObjectFactory(org.mule.runtime.config.internal.dsl.processor.EnvironmentPropertyObjectFactory) OnErrorContinueHandler(org.mule.runtime.core.internal.exception.OnErrorContinueHandler) SecretKeyEncryptionStrategy(org.mule.runtime.core.internal.security.SecretKeyEncryptionStrategy) ByteArrayToObject(org.mule.runtime.core.privileged.transformer.simple.ByteArrayToObject) ServerNotificationManagerConfigurator(org.mule.runtime.config.internal.ServerNotificationManagerConfigurator) ConfigurationExtension(org.mule.runtime.core.api.config.ConfigurationExtension) ExpressionLanguageComponent(org.mule.runtime.core.internal.el.ExpressionLanguageComponent) ForkJoinStrategyFactory(org.mule.runtime.core.internal.routing.ForkJoinStrategyFactory) DataUnit(org.mule.runtime.api.util.DataUnit) InvokerMessageProcessor(org.mule.runtime.core.internal.processor.InvokerMessageProcessor) MessageProcessorChain(org.mule.runtime.core.privileged.processor.chain.MessageProcessorChain) NullCursorStreamProviderObjectFactory(org.mule.runtime.config.internal.factories.streaming.NullCursorStreamProviderObjectFactory) ByteArrayToHexString(org.mule.runtime.core.internal.transformer.simple.ByteArrayToHexString) UsernamePasswordAuthenticationFilter(org.mule.runtime.core.internal.security.UsernamePasswordAuthenticationFilter) DefaultFlowFactoryBean(org.mule.runtime.config.internal.factories.DefaultFlowFactoryBean) AbstractTransformer(org.mule.runtime.core.api.transformer.AbstractTransformer) ResponseMessageProcessorsFactoryBean(org.mule.runtime.config.internal.factories.ResponseMessageProcessorsFactoryBean) Builder.fromReferenceObject(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromReferenceObject) POOLING_PROFILE_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.POOLING_PROFILE_ELEMENT_IDENTIFIER) KeyAttributeDefinitionPair.newBuilder(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair.newBuilder) Builder.fromSimpleReferenceParameter(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromSimpleReferenceParameter) MessageProcessorChainObjectFactory(org.mule.runtime.core.privileged.processor.objectfactory.MessageProcessorChainObjectFactory) ANY_SELECTOR_STRING(org.mule.runtime.core.api.context.notification.ListenerSubscriptionPair.ANY_SELECTOR_STRING) RoundRobin(org.mule.runtime.core.internal.routing.RoundRobin) Function(java.util.function.Function) Builder.fromFixedValue(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromFixedValue) AsyncMessageProcessorsFactoryBean(org.mule.runtime.config.internal.factories.AsyncMessageProcessorsFactoryBean) ComponentBuildingDefinitionProviderUtils.getMuleMessageTransformerBaseBuilder(org.mule.runtime.config.api.dsl.model.ComponentBuildingDefinitionProviderUtils.getMuleMessageTransformerBaseBuilder) DynamicConfigExpiration(org.mule.runtime.core.api.config.DynamicConfigExpiration) ExpressionArgument(org.mule.runtime.core.internal.transformer.expression.ExpressionArgument) XmlEntityDecoder(org.mule.runtime.core.internal.transformer.codec.XmlEntityDecoder) XaTransactionFactory(org.mule.runtime.core.privileged.transaction.xa.XaTransactionFactory) LinkedList(java.util.LinkedList) DEFAULT_BYTE_STREAMING_BUFFER_INCREMENT_SIZE(org.mule.runtime.extension.api.ExtensionConstants.DEFAULT_BYTE_STREAMING_BUFFER_INCREMENT_SIZE) MessageProcessorChainFactoryBean(org.mule.runtime.config.privileged.dsl.processor.MessageProcessorChainFactoryBean) ChoiceRouterObjectFactory(org.mule.runtime.config.internal.factories.ChoiceRouterObjectFactory) Resequencer(org.mule.runtime.core.internal.routing.Resequencer) AnnotatedProcessor(org.mule.runtime.core.privileged.processor.AnnotatedProcessor) Optional.ofNullable(java.util.Optional.ofNullable) DEFAULT_OBJECT_STREAMING_BUFFER_SIZE(org.mule.runtime.extension.api.ExtensionConstants.DEFAULT_OBJECT_STREAMING_BUFFER_SIZE) ReconnectionConfigObjectFactory(org.mule.runtime.config.internal.dsl.processor.ReconnectionConfigObjectFactory) FixedFrequencyScheduler(org.mule.runtime.core.api.source.scheduler.FixedFrequencyScheduler) DEFAULT_BYTES_STREAMING_MAX_BUFFER_SIZE(org.mule.runtime.extension.api.ExtensionConstants.DEFAULT_BYTES_STREAMING_MAX_BUFFER_SIZE) ReconnectionConfig(org.mule.runtime.core.internal.retry.ReconnectionConfig) ParseTemplateProcessor(org.mule.runtime.core.internal.processor.simple.ParseTemplateProcessor) NullCursorIteratorProviderObjectFactory(org.mule.runtime.config.internal.factories.streaming.NullCursorIteratorProviderObjectFactory) INITIAL_STATE_STARTED(org.mule.runtime.core.api.construct.Flow.INITIAL_STATE_STARTED) MessageChunkAggregator(org.mule.runtime.core.internal.routing.MessageChunkAggregator) UntilSuccessful(org.mule.runtime.core.internal.routing.UntilSuccessful) TryProcessorFactoryBean(org.mule.runtime.config.internal.factories.TryProcessorFactoryBean) SetPayloadMessageProcessor(org.mule.runtime.core.internal.processor.simple.SetPayloadMessageProcessor) CORE_PREFIX(org.mule.runtime.internal.dsl.DslConstants.CORE_PREFIX) Builder.fromSimpleParameter(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromSimpleParameter) TypeDefinition.fromConfigurationAttribute(org.mule.runtime.dsl.api.component.TypeDefinition.fromConfigurationAttribute) ComponentBuildingDefinitionProviderUtils.getTransformerBaseBuilder(org.mule.runtime.config.api.dsl.model.ComponentBuildingDefinitionProviderUtils.getTransformerBaseBuilder) ErrorHandlerFactoryBean(org.mule.runtime.config.internal.factories.ErrorHandlerFactoryBean) AutoTransformer(org.mule.runtime.core.internal.transformer.simple.AutoTransformer) RECONNECTION_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.RECONNECTION_ELEMENT_IDENTIFIER) PasswordBasedEncryptionStrategy(org.mule.runtime.core.internal.security.PasswordBasedEncryptionStrategy) MuleRuntimeException(org.mule.runtime.api.exception.MuleRuntimeException) MVELGlobalFunctionsConfig(org.mule.runtime.core.internal.el.mvel.configuration.MVELGlobalFunctionsConfig) ResponseMessageProcessorAdapter(org.mule.runtime.core.internal.processor.ResponseMessageProcessorAdapter) ComponentBuildingDefinition(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition) NON_REPEATABLE_BYTE_STREAM_ALIAS(org.mule.runtime.extension.api.declaration.type.StreamingStrategyTypeBuilder.NON_REPEATABLE_BYTE_STREAM_ALIAS) DEFAULT_POOL_EXHAUSTED_ACTION(org.mule.runtime.api.config.PoolingProfile.DEFAULT_POOL_EXHAUSTED_ACTION) CustomEncryptionStrategyDelegate(org.mule.runtime.config.internal.CustomEncryptionStrategyDelegate) AddFlowVariableProcessor(org.mule.runtime.core.internal.processor.simple.AddFlowVariableProcessor) InMemoryCursorIteratorProviderObjectFactory(org.mule.runtime.config.internal.factories.streaming.InMemoryCursorIteratorProviderObjectFactory) DefaultSchedulerMessageSource(org.mule.runtime.core.internal.source.scheduler.DefaultSchedulerMessageSource) AbstractEncryptionTransformer(org.mule.runtime.core.internal.transformer.encryption.AbstractEncryptionTransformer) CronScheduler(org.mule.runtime.core.api.source.scheduler.CronScheduler) CursorStreamProviderFactory(org.mule.runtime.core.api.streaming.bytes.CursorStreamProviderFactory) MessageEnricher(org.mule.runtime.core.internal.enricher.MessageEnricher) ObjectToString(org.mule.runtime.core.internal.transformer.simple.ObjectToString) CRON_STRATEGY_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.CRON_STRATEGY_ELEMENT_IDENTIFIER) REPEATABLE_IN_MEMORY_OBJECTS_STREAM_ALIAS(org.mule.runtime.extension.api.declaration.type.StreamingStrategyTypeBuilder.REPEATABLE_IN_MEMORY_OBJECTS_STREAM_ALIAS) DEFAULT_MAX_POOL_IDLE(org.mule.runtime.api.config.PoolingProfile.DEFAULT_MAX_POOL_IDLE) EncryptionStrategy(org.mule.runtime.core.api.security.EncryptionStrategy) ArrayList(java.util.ArrayList) DEFAULT_MAX_POOL_WAIT(org.mule.runtime.api.config.PoolingProfile.DEFAULT_MAX_POOL_WAIT) RetryPolicyTemplateObjectFactory(org.mule.runtime.config.internal.dsl.processor.RetryPolicyTemplateObjectFactory) POOL_EXHAUSTED_ACTIONS(org.mule.runtime.api.config.PoolingProfile.POOL_EXHAUSTED_ACTIONS) TypeDefinition.fromType(org.mule.runtime.dsl.api.component.TypeDefinition.fromType) ConfigurableInstanceFactory(org.mule.runtime.config.api.dsl.ConfigurableInstanceFactory) RetryNotifier(org.mule.runtime.core.api.retry.RetryNotifier) GZipUncompressTransformer(org.mule.runtime.core.internal.transformer.compression.GZipUncompressTransformer) I18nMessageFactory.createStaticMessage(org.mule.runtime.api.i18n.I18nMessageFactory.createStaticMessage) Builder.fromMultipleDefinitions(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromMultipleDefinitions) TransactionType(org.mule.runtime.api.tx.TransactionType) String.valueOf(java.lang.String.valueOf) Builder.fromTextContent(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromTextContent) SplitAggregateScope(org.mule.runtime.core.internal.routing.SplitAggregateScope) ComponentBuildingDefinitionProvider(org.mule.runtime.dsl.api.component.ComponentBuildingDefinitionProvider) CollectListForkJoinStrategyFactory(org.mule.runtime.core.internal.routing.forkjoin.CollectListForkJoinStrategyFactory) IdempotentMessageValidator(org.mule.runtime.core.internal.routing.IdempotentMessageValidator) FIXED_FREQUENCY_STRATEGY_ELEMENT_IDENTIFIER(org.mule.runtime.internal.dsl.DslConstants.FIXED_FREQUENCY_STRATEGY_ELEMENT_IDENTIFIER) MessageChunkSplitter(org.mule.runtime.core.internal.routing.MessageChunkSplitter) OnErrorPropagateHandler(org.mule.runtime.core.internal.exception.OnErrorPropagateHandler) PeriodicScheduler(org.mule.runtime.core.api.source.scheduler.PeriodicScheduler) MuleTransactionConfig(org.mule.runtime.core.api.transaction.MuleTransactionConfig) TryScope(org.mule.runtime.core.internal.processor.TryScope) Builder.fromChildCollectionConfiguration(org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildCollectionConfiguration) Predicate(java.util.function.Predicate) XmlEntityEncoder(org.mule.runtime.core.internal.transformer.codec.XmlEntityEncoder) Foreach(org.mule.runtime.core.internal.routing.Foreach) FlowExceptionHandler(org.mule.runtime.core.api.exception.FlowExceptionHandler) SimpleAsyncRequestReplyRequester(org.mule.runtime.core.internal.routing.requestreply.SimpleAsyncRequestReplyRequester) ByteArrayToSerializable(org.mule.runtime.core.privileged.transformer.simple.ByteArrayToSerializable) Flow(org.mule.runtime.core.api.construct.Flow) RaiseErrorProcessor(org.mule.runtime.core.api.processor.RaiseErrorProcessor) FirstSuccessful(org.mule.runtime.core.internal.routing.FirstSuccessful) List(java.util.List) MuleSecurityManagerConfigurator(org.mule.runtime.core.api.security.MuleSecurityManagerConfigurator) SerializableToByteArray(org.mule.runtime.core.privileged.transformer.simple.SerializableToByteArray) MessageProcessorFilterPairFactoryBean(org.mule.runtime.config.internal.factories.MessageProcessorFilterPairFactoryBean) OBJECT_MULE_CONFIGURATION(org.mule.runtime.core.api.config.MuleProperties.OBJECT_MULE_CONFIGURATION) ExpirationPolicyObjectFactory(org.mule.runtime.config.internal.factories.ExpirationPolicyObjectFactory) RETRY_COUNT_FOREVER(org.mule.runtime.core.api.retry.policy.SimpleRetryPolicyTemplate.RETRY_COUNT_FOREVER) IdempotentRedeliveryPolicy(org.mule.runtime.core.privileged.processor.IdempotentRedeliveryPolicy) Builder(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition.Builder) InMemoryCursorStreamProviderObjectFactory(org.mule.runtime.config.internal.factories.streaming.InMemoryCursorStreamProviderObjectFactory) SecurityProvider(org.mule.runtime.core.api.security.SecurityProvider) RetryPolicyTemplate(org.mule.runtime.core.api.retry.policy.RetryPolicyTemplate) MessageSource(org.mule.runtime.core.api.source.MessageSource) RemoveFlowVariableProcessor(org.mule.runtime.core.internal.processor.simple.RemoveFlowVariableProcessor) Splitter(org.mule.runtime.core.internal.routing.Splitter) LOCAL(org.mule.runtime.api.tx.TransactionType.LOCAL) ACTION_INDIFFERENT_STRING(org.mule.runtime.core.api.transaction.MuleTransactionConfig.ACTION_INDIFFERENT_STRING) Processor(org.mule.runtime.core.api.processor.Processor) AsyncDelegateMessageProcessor(org.mule.runtime.core.internal.processor.AsyncDelegateMessageProcessor) SchedulingMessageSourceFactoryBean(org.mule.runtime.config.internal.factories.SchedulingMessageSourceFactoryBean) ChoiceRouter(org.mule.runtime.core.internal.routing.ChoiceRouter) ListenerSubscriptionPair(org.mule.runtime.core.api.context.notification.ListenerSubscriptionPair) ImportEntry(org.mule.runtime.core.internal.el.mvel.configuration.ImportEntry) Notification(org.mule.runtime.api.notification.Notification) MuleContext(org.mule.runtime.core.api.MuleContext) FlowRefFactoryBean(org.mule.runtime.config.internal.factories.FlowRefFactoryBean) CustomSecurityProviderDelegate(org.mule.runtime.config.internal.CustomSecurityProviderDelegate) MuleConfigurationConfigurator(org.mule.runtime.config.internal.MuleConfigurationConfigurator) ModuleOperationMessageProcessorChainFactoryBean(org.mule.runtime.config.internal.factories.ModuleOperationMessageProcessorChainFactoryBean) CursorIteratorProviderFactory(org.mule.runtime.core.api.streaming.object.CursorIteratorProviderFactory) AbstractExpressionTransformer(org.mule.runtime.core.internal.transformer.expression.AbstractExpressionTransformer) AttributeDefinition(org.mule.runtime.dsl.api.component.AttributeDefinition) DEFAULT_OBJECT_STREAMING_BUFFER_INCREMENT_SIZE(org.mule.runtime.extension.api.ExtensionConstants.DEFAULT_OBJECT_STREAMING_BUFFER_INCREMENT_SIZE) CustomSecurityFilterObjectFactory(org.mule.runtime.config.internal.dsl.processor.CustomSecurityFilterObjectFactory) TimeUnit(java.util.concurrent.TimeUnit) ExpressionTransformer(org.mule.runtime.core.internal.transformer.expression.ExpressionTransformer) POOL_INITIALISATION_POLICIES(org.mule.runtime.api.config.PoolingProfile.POOL_INITIALISATION_POLICIES) AliasEntry(org.mule.runtime.core.internal.el.mvel.configuration.AliasEntry) KeyAttributeDefinitionPair.newBuilder(org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair.newBuilder) ComponentBuildingDefinitionProviderUtils.getMuleMessageTransformerBaseBuilder(org.mule.runtime.config.api.dsl.model.ComponentBuildingDefinitionProviderUtils.getMuleMessageTransformerBaseBuilder) ComponentBuildingDefinitionProviderUtils.getTransformerBaseBuilder(org.mule.runtime.config.api.dsl.model.ComponentBuildingDefinitionProviderUtils.getTransformerBaseBuilder) Builder(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition.Builder) Resequencer(org.mule.runtime.core.internal.routing.Resequencer) ByteArrayToHexString(org.mule.runtime.core.internal.transformer.simple.ByteArrayToHexString) ObjectToString(org.mule.runtime.core.internal.transformer.simple.ObjectToString) DynamicConfigExpirationObjectFactory(org.mule.runtime.config.internal.factories.DynamicConfigExpirationObjectFactory) MessageProcessorExpressionPair(org.mule.runtime.core.internal.routing.MessageProcessorExpressionPair) FlowExceptionHandler(org.mule.runtime.core.api.exception.FlowExceptionHandler) AsyncMessageProcessorsFactoryBean(org.mule.runtime.config.internal.factories.AsyncMessageProcessorsFactoryBean) ServerNotificationManagerConfigurator(org.mule.runtime.config.internal.ServerNotificationManagerConfigurator) IdempotentRedeliveryPolicy(org.mule.runtime.core.privileged.processor.IdempotentRedeliveryPolicy) MuleConfigurationConfigurator(org.mule.runtime.config.internal.MuleConfigurationConfigurator) MuleConfiguration(org.mule.runtime.core.api.config.MuleConfiguration) ExpressionLanguageComponent(org.mule.runtime.core.internal.el.ExpressionLanguageComponent) NotificationConfig(org.mule.runtime.config.internal.NotificationConfig) ComponentBuildingDefinition(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition) ResponseMessageProcessorAdapter(org.mule.runtime.core.internal.processor.ResponseMessageProcessorAdapter) Builder(org.mule.runtime.dsl.api.component.ComponentBuildingDefinition.Builder) DefaultFlowFactoryBean(org.mule.runtime.config.internal.factories.DefaultFlowFactoryBean) ImportEntry(org.mule.runtime.core.internal.el.mvel.configuration.ImportEntry) PoolingProfile(org.mule.runtime.api.config.PoolingProfile) LinkedList(java.util.LinkedList) MessageEnricherObjectFactory(org.mule.runtime.config.internal.dsl.processor.factory.MessageEnricherObjectFactory) ResponseMessageProcessorsFactoryBean(org.mule.runtime.config.internal.factories.ResponseMessageProcessorsFactoryBean) TemplateOnErrorHandler(org.mule.runtime.core.privileged.exception.TemplateOnErrorHandler) RaiseErrorProcessor(org.mule.runtime.core.api.processor.RaiseErrorProcessor) SimpleCollectionAggregator(org.mule.runtime.core.internal.routing.SimpleCollectionAggregator) LoggerMessageProcessor(org.mule.runtime.core.internal.processor.LoggerMessageProcessor) AbstractAddVariablePropertyProcessor(org.mule.runtime.core.privileged.processor.simple.AbstractAddVariablePropertyProcessor) InvokerMessageProcessor(org.mule.runtime.core.internal.processor.InvokerMessageProcessor) AnnotatedProcessor(org.mule.runtime.core.privileged.processor.AnnotatedProcessor) ParseTemplateProcessor(org.mule.runtime.core.internal.processor.simple.ParseTemplateProcessor) SetPayloadMessageProcessor(org.mule.runtime.core.internal.processor.simple.SetPayloadMessageProcessor) AddFlowVariableProcessor(org.mule.runtime.core.internal.processor.simple.AddFlowVariableProcessor) RaiseErrorProcessor(org.mule.runtime.core.api.processor.RaiseErrorProcessor) RemoveFlowVariableProcessor(org.mule.runtime.core.internal.processor.simple.RemoveFlowVariableProcessor) Processor(org.mule.runtime.core.api.processor.Processor) AsyncDelegateMessageProcessor(org.mule.runtime.core.internal.processor.AsyncDelegateMessageProcessor) StringAppendTransformer(org.mule.runtime.core.internal.transformer.simple.StringAppendTransformer) Transformer(org.mule.runtime.core.api.transformer.Transformer) EncryptionTransformer(org.mule.runtime.core.internal.transformer.encryption.EncryptionTransformer) DecryptionTransformer(org.mule.runtime.core.internal.transformer.encryption.DecryptionTransformer) GZipCompressTransformer(org.mule.runtime.core.internal.transformer.compression.GZipCompressTransformer) AbstractTransformer(org.mule.runtime.core.api.transformer.AbstractTransformer) AutoTransformer(org.mule.runtime.core.internal.transformer.simple.AutoTransformer) AbstractEncryptionTransformer(org.mule.runtime.core.internal.transformer.encryption.AbstractEncryptionTransformer) GZipUncompressTransformer(org.mule.runtime.core.internal.transformer.compression.GZipUncompressTransformer) AbstractExpressionTransformer(org.mule.runtime.core.internal.transformer.expression.AbstractExpressionTransformer) ExpressionTransformer(org.mule.runtime.core.internal.transformer.expression.ExpressionTransformer) AttributeDefinition(org.mule.runtime.dsl.api.component.AttributeDefinition) DynamicConfigExpiration(org.mule.runtime.core.api.config.DynamicConfigExpiration) MessageProcessorChain(org.mule.runtime.core.privileged.processor.chain.MessageProcessorChain) MuleContext(org.mule.runtime.core.api.MuleContext) CronScheduler(org.mule.runtime.core.api.source.scheduler.CronScheduler) PeriodicScheduler(org.mule.runtime.core.api.source.scheduler.PeriodicScheduler) CustomEncryptionStrategyDelegate(org.mule.runtime.config.internal.CustomEncryptionStrategyDelegate) InvokerMessageProcessor(org.mule.runtime.core.internal.processor.InvokerMessageProcessor) MessageChunkAggregator(org.mule.runtime.core.internal.routing.MessageChunkAggregator) MuleEncryptionEndpointSecurityFilter(org.mule.runtime.core.internal.security.filter.MuleEncryptionEndpointSecurityFilter) MVELGlobalFunctionsConfig(org.mule.runtime.core.internal.el.mvel.configuration.MVELGlobalFunctionsConfig) AnnotatedProcessor(org.mule.runtime.core.privileged.processor.AnnotatedProcessor) ForkJoinStrategyFactory(org.mule.runtime.core.internal.routing.ForkJoinStrategyFactory) CollectListForkJoinStrategyFactory(org.mule.runtime.core.internal.routing.forkjoin.CollectListForkJoinStrategyFactory) MessageChunkSplitter(org.mule.runtime.core.internal.routing.MessageChunkSplitter) Splitter(org.mule.runtime.core.internal.routing.Splitter) POOL_INITIALISATION_POLICIES(org.mule.runtime.api.config.PoolingProfile.POOL_INITIALISATION_POLICIES) CollectListForkJoinStrategyFactory(org.mule.runtime.core.internal.routing.forkjoin.CollectListForkJoinStrategyFactory) OnErrorFactoryBean(org.mule.runtime.config.internal.factories.OnErrorFactoryBean) DefaultSchedulerMessageSource(org.mule.runtime.core.internal.source.scheduler.DefaultSchedulerMessageSource) MessageSource(org.mule.runtime.core.api.source.MessageSource) AsyncDelegateMessageProcessor(org.mule.runtime.core.internal.processor.AsyncDelegateMessageProcessor) Flow(org.mule.runtime.core.api.construct.Flow) PasswordBasedEncryptionStrategy(org.mule.runtime.core.internal.security.PasswordBasedEncryptionStrategy) SubflowMessageProcessorChainFactoryBean(org.mule.runtime.config.internal.factories.SubflowMessageProcessorChainFactoryBean) SecurityProvider(org.mule.runtime.core.api.security.SecurityProvider) FlowRefFactoryBean(org.mule.runtime.config.internal.factories.FlowRefFactoryBean) SimpleAsyncRequestReplyRequester(org.mule.runtime.core.internal.routing.requestreply.SimpleAsyncRequestReplyRequester) CustomSecurityProviderDelegate(org.mule.runtime.config.internal.CustomSecurityProviderDelegate) AliasEntry(org.mule.runtime.core.internal.el.mvel.configuration.AliasEntry) AddFlowVariableProcessor(org.mule.runtime.core.internal.processor.simple.AddFlowVariableProcessor) ListenerSubscriptionPair(org.mule.runtime.core.api.context.notification.ListenerSubscriptionPair)

Aggregations

AttributeDefinition (org.mule.runtime.dsl.api.component.AttributeDefinition)4 List (java.util.List)3 Map (java.util.Map)3 MuleRuntimeException (org.mule.runtime.api.exception.MuleRuntimeException)3 I18nMessageFactory.createStaticMessage (org.mule.runtime.api.i18n.I18nMessageFactory.createStaticMessage)3 String.format (java.lang.String.format)2 ArrayList (java.util.ArrayList)2 PoolingProfile (org.mule.runtime.api.config.PoolingProfile)2 Processor (org.mule.runtime.core.api.processor.Processor)2 RetryPolicyTemplate (org.mule.runtime.core.api.retry.policy.RetryPolicyTemplate)2 Builder.fromChildCollectionConfiguration (org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildCollectionConfiguration)2 Builder.fromChildConfiguration (org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildConfiguration)2 Builder.fromChildMapConfiguration (org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromChildMapConfiguration)2 Builder.fromFixedValue (org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromFixedValue)2 Builder.fromMultipleDefinitions (org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromMultipleDefinitions)2 Builder.fromSimpleParameter (org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromSimpleParameter)2 Builder.fromSimpleReferenceParameter (org.mule.runtime.dsl.api.component.AttributeDefinition.Builder.fromSimpleReferenceParameter)2 ComponentBuildingDefinition (org.mule.runtime.dsl.api.component.ComponentBuildingDefinition)2 Builder (org.mule.runtime.dsl.api.component.ComponentBuildingDefinition.Builder)2 KeyAttributeDefinitionPair (org.mule.runtime.dsl.api.component.KeyAttributeDefinitionPair)2