Is it possible to make queue in ThreadPoolTaskExecutor persistent
I have used Spring TaskExecutor with a ThreadPoolTaskExecutor
implementation to implement an asynchronous queue with a thread pool. The
objects being stored on the queue are small JSONObjects (40 bytes max) but
the number of objects will be quite large, up to 100,000.
A new requirement has now been placed on us to make this queue persistent
so that it can survive a JVM/server restart. Is there an efficient way to
persist this queue reusing the above implementation and without
introducing too much complexity into my application? Is there something in
the TaskExecutor configuration itself that I can use to achieve this aim
or do I have to resort to something else, like JMS, or a custom solution,
such as writing to a file?
Any help/ideas will be greatly appreciated.
No comments:
Post a Comment