I am developing a secure web application that does financial transactions and using spring in it. Which will be more suitable to use for security, JAX-RS services or spring rest services? I thought of going with spring as we are already using it in application and if it provides the features then why to go for JAX-RS, but as I said its a highly secured web application where people will buy things and make financial transactions so I have to see which is more suitable to use.
I followed the following blogs still a little confused…
Can anybody suggest which will be more useful to use ??
It's not an either-or choice. I use Spring and JAX-RS (specifically, Apache CXF, which implements the JAX-RS specification) together in the same secured application.
The key to understanding this is to note that Spring isn't one homogenous lump. It's actually many pieces. The parts I'm using are (approximately) the Spring IoC core, Spring AOP and Spring Security. The IoC core is the part that is Spring; it manages the lifecycle and configuration of your beans. I use AOP for transaction management (since that's far easier than coding all that myself in each method that needs a transaction). The management of the dispatch of the REST calls to my code is handled by Apache CXF (which sits very nicely inside Spring IoC provided you use the right context loader) and that does work well with Spring Security.
As a side note, you are aware that financial transaction handling is tricky? Not because the code is that much harder, but because the consequences of getting it wrong are worse and there are plenty of people willing to try to make things go wrong for personal gain.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With