Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7635281
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T07:23:43+00:00 2026-05-31T07:23:43+00:00

I have written a component (EHComponent) to do error handling for other components (AComponent).

  • 0

I have written a component (EHComponent) to do error handling for other components (AComponent).

AComponent reads from a queue, encounters an error, and if an exception is thrown, the message gets some headers about the error set, and a .to(“error.queue”) is called to put the message on another queue for the EHComponent to read from.

The EHComponent inspects the message headers referring to the error type, acts accordingly, setting some additional message headers (Counting how many times that message has made it to the error queue)

The EHComponent sets that value, then calls a .to(“Original.Queue”) which is what AComponent reads from.

The problem hasnt been fixed, so a new exception is thrown, so this same message goes through the process again.

The problem I am having is that the 2nd time through, even though I think it is the same message, those headers I set are not there.

I was under the impression that message headers are somewhat stable in Camel, so that even though I’m in a new exchange, the message will header would be intact. What do I have to do to ensure that a message header is accessible from any component, on any part of the route?

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T07:23:44+00:00Added an answer on May 31, 2026 at 7:23 am

    Headers is part of the message, and as such its up to your transports to preserve headers.
    So when you send the messages over the queues using your component, then make sure you preserve headers.

    However if you store properties on the Exchange, then they are kept for the lifetime of the Exchange.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have written a new custom component derived from TLabel. The component adds some
I have a component written in C#. Among other things it performs XSL transform
I have written a COM component in unmanaged C++ to provide customers access to
I have written an advanced text editor component (fixed-width, syntax highlighting, etc.) in Delphi,
I have a COM component written in C# that makes calls to ConfigurationManager.AppSettings.Get(...). This
I have a simple GUI component written in Java. The class draws an analog
We have a WinForms application written in C# that uses the AxAcroPDFLib.AxAcroPDF component to
I have written an AIR Application that downloads videos and documents from a server.
In jQueryMobile, I have written a data-role=listview component and I want to filter the
Let say I have written a small program that reads file_A and file_B as

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.