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

  • SEARCH
  • Home
  • 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 9073941
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T18:31:43+00:00 2026-06-16T18:31:43+00:00

If a mail is send to my inbox, I recieve a message, and I’m

  • 0

If a mail is send to my inbox, I recieve a message, and I’m inserting the contents into DB.
I have a org.springframework.integration.core.Message something like follows:

public void receive(Message<?> message)
{
    //I am inserting message contents into DB
}

Now in the event of failure, I wanted to have fail safe recovery mechanism, what I am thinking is to serialize the Message object into a file and later deserialize and update to DB.

Question
1. In this situation how to serialize the Message object?
2. Other than serialization any other mechanism that can be used?

EDIT
I have not done Serialization before, I heard like the class should implements Serializable in order to use ObjectOutputStream, in this case I don’t want to create a subclass of Message, So how to serialize Message to File?

  • 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-06-16T18:31:44+00:00Added an answer on June 16, 2026 at 6:31 pm

    Sure, there are many serialization mechanisms apart from the jvm one.

    • XML
    • JSON
    • BSON
    • MessagePack
    • protobufs
    • …

    Some of them are text-based, some are binary. All have drawbacks and pluses. Text-based ones are human-readable, binary ones are faster and take up less space.

    There are java libraries that handle all the above formats: JAXB (XML), Jackson (JSON), etc.

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

Sidebar

Related Questions

i have used System.Web.Mail.MailMessage to send HTML Formatted message to an email id. The
I could send mail from my Activity when i have already configured with any
I am tring to send mail by AWSCredentials but getting an exception java.lang.NoClassDefFoundError: org/apache/http/conn/scheme/SchemeSocketFactory
Basically I have an MVC 3 form which sends a mail to my inbox
I have to send a mail from go daddy in a project, and that
I have made asp.net webservice in C# to send mail on given mailid as
I've been using scripting bridge to make Mail send messages with attachments in 10.6
I need to send mail daily using smtp and asp.net.
I needed to send mail from my plain Flask app, so I thought the
I'm trying to send mail using phpMailer. It's my code: <?php require_once('phpmailer/class.phpmailer.php'); $mail =

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.