To find out why and how actor model can help Struts2, I searched a lot but just found following [1] at [2].
I wonder if you @dev have anything in your mind about: Why and how actor model can help specifically Struts2 ? I don't mean in detail but if for example there is a general issue exists reported by users which reminds us the actor model. Or if for example we can run interceptors in parallel. Or if for example we need sticky sessions in Struts2 and so so any thought?. Thanks in advance! Yasser. [1] Stop me if you’ve heard this one. You just got off the phone with your boss, who is getting frantic phone calls about your application throwing errors all over the place, running extremely slowly, and in general causing massive headaches. You check your pool of app servers, and find that all of the threads are blocked on I/O. It’s 6am, and you haven’t even fired up the coffee maker, and already existential dread is filling your brain. Java web app developers know all about this scenario— Java web frameworks have, historically, been extremely poor at concurrency. The number one cry of Struts or JSF developers is “just turn on sticky sessions”, and then only a percentage of your users will get hosed when things start going wrong at the controller level. Want to write a controller that connects to a third-party REST service which happens to reject a connection from time to time? Beati pauperes spiritu. Want to asynchronously log some action to a database? Send a message to Akka and forget about it. Want to fail gracefully when that REST service refuses your connection? Have your Akka actor schedule the original message to be placed back into the mailbox, and you’re done. Want to share sessions between application servers? Ask an Akka actor to retrieve a key from a cache, and you’re done. Want to recreate the Quartz functionality of JBoss? Schedule an Akka actor to run every so often with one line of code. Want to resize an image as a background task? Send an Akka actor a message containing the bytes of the image, return a Future containing the bytes of the resized image, and you’re done. [2] https://medium.com/21st-century-web-application-development/akka-the-most-important-middleware-youve-never-heard-of-dc19e386026d On 8/1/2017 2:38 PM, Lukasz Lenart wrote: > I do not have any directives how to implement actor/async support in > Struts2 - I thought about using http://jumi.fi/actors.html as it uses > Apache License and it's small & fast library. I wouldn't go with Akka > as this is a huge system by itself.