Mule 4 Mulesoft Basics Mulesoft Tutorial

Inbound Outbound Properties


In this “Inbound Outbound Properties” tutorial of Mule 4 we will look on how we can set and modify Mule Inbound and Outbound Properties.

In Mule Inbound properties referees to the additional information that comes to an Mule API along with the message body/payload itself. It may consist of inbound Headers, Query Params, URI Params, HTTP method etc.
In Mule Inbound properties are preset by the sender of the message thus cannot be added or modified.

Mule Outbound Properties are headers and properties that Mule API set before ending its request to other external systems.

Inbound Properties
In Mule 3 we used to access inbound properties by #[message.inboundProperties]

Whereas in Mule 4 we access these properties by #[attributes]

Example
We have create a simple project using RAML.
The GET method of the RAML has URI Param – user_id, which can assess by #[attributes.uriParams['user_id']]

Similarly to access Query Param we do it by #[attributes.queryParams['code']]

To view all the Inbound Properties that are received by a Mule API:

#[attributes]


Output :

 

Outbound Properties
As in Mule 3 we used to set outbound properties via using Set Property Component.
In Mule 4, outbound properties no longer exist. Instead, the headers or properties (e.g. HTTP headers or JMS properties) that you wish to send as part of a request or message (e.g. HTTP request or JMS message) respectively are now configured explicitly as part of the connector operation configuration. 
Example:
To Set the outbound HTTP headers and HTTP status code for a Mule API we need to modify the HTTP Listener Configuration.

SoapUI Output –


About Varun Goel

Varun Goel is a technology enthusiast with 6+ years exp in IT industry. In fact, he is been developing application after schooling as freelancer. Currently working with one of the Fortune’s 100 Companies having vast experience Mule ESB, Tibco, HTML5, CSS, JSS, Android, Core Java, JSP, PHP, MySQL, AutoCAD, Maya, ZBrush, Photoshop, Flash CS and many more.

17 comments

  1. Beard Oil Unscented

    naturally like your website however you have to take a look at the spelling on several of your posts. Many of them are rife with spelling issues and I to find it very troublesome to inform the reality however I’ll surely come back again.

  2. Berberine Yarrow

    I just couldn’t depart your web site before suggesting that I actually enjoyed the standard information a person provide for your visitors? Is gonna be back often in order to check up on new posts

  3. Shirley

    The walls do not have to be perfectly even as a little bit
    more adhesive could be added hollow areas and less high is often a bump.
    An uneven surface with seams and joins is an ideal environment
    for the people microbes and bacteria to lurk willing to wage war on your family’s innards,Finally there’s
    the really depressing bit. It might be moulded and cut to almost any shape,
    integrating holes for sockets and pipes, raised cooling racks
    and in many cases integrated bowls.

  4. Nila

    A person will not test a pack that’s clearly leaking, while they know it will fail, thereby distorting the real profile
    of an production run, while a product will collect the sample
    and report the end result objectively. One must consider if the gas leak detectors were designed as fixed or mobile
    phones, whether their application requires the utilization of electricity, batteries,
    or both and whether or not they are in a position to detect the precise gasses found in particular refrigeration and air conditioning.

    Mold is usually a sign you have an undetected roof leak or you have inadequate roofing ventilation.

  5. Markus Ohrnstein

    Excellent read, I just passed this onto a friend who was doing a little research on that. And he actually bought me lunch as I found it for him smile So let me rephrase that: Thank you for lunch!

  6. Randolph Lenertz

    Hi, Neat post. There’s an issue together with your web site in web explorer, would check this… IE still is the marketplace chief and a huge portion of people will omit your great writing because of this problem.

  7. Tianna Stofko

    Attractive part of content. I simply stumbled upon your blog and in accession capital to assert that I get actually enjoyed account your weblog posts. Anyway I’ll be subscribing in your feeds or even I success you get right of entry to consistently rapidly.

  8. why affiliate marketing fail

    Good post. I learn one thing more difficult on totally different blogs everyday. It should always be stimulating to read content from other writers and follow a little one thing from their store. I’d prefer to use some with the content on my weblog whether you don’t mind. Natually I’ll give you a hyperlink on your web blog. Thanks for sharing.

  9. Dorthea Speckman

    I would like to get across my appreciation for your kind-heartedness for individuals that need guidance on your matter. Your real dedication to passing the message throughout came to be especially important and have really allowed women like me to get to their ambitions. The warm and friendly help and advice signifies so much to me and a whole lot more to my peers. With thanks; from all of us.

  10. sale weselne

    Hello! I’m at work surfing around your blog from my new apple iphone!
    Just wanted to say I love reading your blog and look forward to all your posts!
    Carry on the superb work!

Leave a Reply

Your email address will not be published.