際際滷

際際滷Share a Scribd company logo
Mule Integration Workshop
Mule Filters
Rapidly connect any application, anywhere
Anypoint Platform helps companies prepare for the future
with a next-generation SOA platform that connects on-
premises systems and the cloud.
Mule ESB, CloudHub, Mule Studio, Mule Enterprise
Management, Anypoint Connectors
Anypoint
Platform
for SOA
Connect SaaS with any application, anywhere
Anypoint Platform helps companies connect SaaS applications
to each other and the enterprise, in the cloud and on-
premises.
CloudHub, Mule ESB, Mule Studio, CloudHub Insight,
Anypoint Connectors
Anypoint
Platform
for SaaS
All you need to connect any app, any device and any API
With the Anypoint Platform for APIs, you can build new APIs,
design new interfaces for existing APIs and more efficiently
manage all your APIs using a single platform.
API Portal, API Manager, Mule Studio, Mule ESB, CloudHub
Anypoint
Platform
for API
MuleSoft Anypoint Platforms
1
Chapters
Schedule
Filter Types
Filters
Filter Types
FILTERS
 Mule bundles more than a dozen Filters that determine whether a
message can proceed through an application flow. The simplest filters
implement basic logic operators (such as and, or, and not), but these
simple elements can be combined in various ways to specify complex
logical conditions.
 Filters provide the logic by which to invoke a particular router.
 Filters can be combined using the logic filters, AndFilter, OrFilter and
NotFilter.
 E.g. PayloadType Filter, RegEx Filter, WildCard Filter, XPath Filter etc.
FILTER TYPES
 Custom Filter
 custom filter to specify a precise set of conditions a message must satisfy before it
can continue through the flow.
 Bundled Filters
Filters Description
And/Not/Or
The three And/Not/Or logic filters express simple logic. When required to express complex logic, these three
filters can be used in combination with other filters.
Custom References a user-implemented filter class.
Exception Filters against an exception of a specified type.
Expression Filters against a range of expressions.
Filter Ref References a globally-defined filter.
Idempotent
Message
This filter ensures that a flow receives only unique messages.
Message Applies specified criteria to a message to determine whether it should be processed.
Message Property Evaluates message properties to determine whether that message should be processed.
Payload Evaluates the payload type of a message to determine whether it should be processed.
Regex Applies a regular expression pattern to the message payload to determine whether it should be processed.
Schema Validation Uses the JAXP libraries, to validate a message against a schema.
Wildcard Filter Matches string messages against a wildcard pattern.
FILTER TYPES
 Payload Type Filter:
Checks the class type of the payload object inside a message.
 RegEx Filter:
Applies a regular expression pattern to the message payload.
 Exception Type Filter
A filter that matches an exception type.
FILTER TYPES
 And Filter
 An And filter combines two filters and only accepts the message if it
matches the criteria of both filters.
 Or Filter
 The Or filter considers two filters and accepts the message if it
matches the criteria of either one of the filters.
FILTER TYPES
 Not Filter:
 A Not filter accepts the message if it does not match the criteria in the
filter.
 Expression filter:
 This can be used in content-based routing to assert statements on the
current message and route the message accordingly.
Thank you

More Related Content

Mule filters

  • 2. Rapidly connect any application, anywhere Anypoint Platform helps companies prepare for the future with a next-generation SOA platform that connects on- premises systems and the cloud. Mule ESB, CloudHub, Mule Studio, Mule Enterprise Management, Anypoint Connectors Anypoint Platform for SOA Connect SaaS with any application, anywhere Anypoint Platform helps companies connect SaaS applications to each other and the enterprise, in the cloud and on- premises. CloudHub, Mule ESB, Mule Studio, CloudHub Insight, Anypoint Connectors Anypoint Platform for SaaS All you need to connect any app, any device and any API With the Anypoint Platform for APIs, you can build new APIs, design new interfaces for existing APIs and more efficiently manage all your APIs using a single platform. API Portal, API Manager, Mule Studio, Mule ESB, CloudHub Anypoint Platform for API MuleSoft Anypoint Platforms 1
  • 4. FILTERS Mule bundles more than a dozen Filters that determine whether a message can proceed through an application flow. The simplest filters implement basic logic operators (such as and, or, and not), but these simple elements can be combined in various ways to specify complex logical conditions. Filters provide the logic by which to invoke a particular router. Filters can be combined using the logic filters, AndFilter, OrFilter and NotFilter. E.g. PayloadType Filter, RegEx Filter, WildCard Filter, XPath Filter etc.
  • 5. FILTER TYPES Custom Filter custom filter to specify a precise set of conditions a message must satisfy before it can continue through the flow. Bundled Filters Filters Description And/Not/Or The three And/Not/Or logic filters express simple logic. When required to express complex logic, these three filters can be used in combination with other filters. Custom References a user-implemented filter class. Exception Filters against an exception of a specified type. Expression Filters against a range of expressions. Filter Ref References a globally-defined filter. Idempotent Message This filter ensures that a flow receives only unique messages. Message Applies specified criteria to a message to determine whether it should be processed. Message Property Evaluates message properties to determine whether that message should be processed. Payload Evaluates the payload type of a message to determine whether it should be processed. Regex Applies a regular expression pattern to the message payload to determine whether it should be processed. Schema Validation Uses the JAXP libraries, to validate a message against a schema. Wildcard Filter Matches string messages against a wildcard pattern.
  • 6. FILTER TYPES Payload Type Filter: Checks the class type of the payload object inside a message. RegEx Filter: Applies a regular expression pattern to the message payload. Exception Type Filter A filter that matches an exception type.
  • 7. FILTER TYPES And Filter An And filter combines two filters and only accepts the message if it matches the criteria of both filters. Or Filter The Or filter considers two filters and accepts the message if it matches the criteria of either one of the filters.
  • 8. FILTER TYPES Not Filter: A Not filter accepts the message if it does not match the criteria in the filter. Expression filter: This can be used in content-based routing to assert statements on the current message and route the message accordingly.