My application that i am working on does not have a database it does all the works by using the services available. Now we came across a problem. One of the service that we use could fail sometimes(even after retrying) which leads to loss of data that we are supposed to send to that service.
One solution that i know is to use serialization and resend data at later point in time. The problem is, what if the machine at which our application running fails(goes down). The serialized object would be lost.
Can anyone suggest an alternative to save the data.Alternative to save the data or alternative to save the serialized object
Why to worry about things in which we dont have control, Why to worry about things in which we have control ! !
I am much worried about the situation wherein the machine in which the app is deployed crashes. In that case the serialized objects will also be lost.
(Please keep in mind that i dont have the a DB to store the data)
If you have no way to persistently store objects (you don't have a database as you say, or you don't have a file system where you can store the serialized objects in a file), then there is no way you can save the data if the application crashes.
Serialization is not some magic way of storing your objects in case you don't have a place to store them persistently; it's just a mechanism to convert objects to and from a format that's suitable for storing them somewhere.
To solve this problem, you need some kind of persistent store, whether it's a database, a file system or something else.