Of course you can do that, but it has nothing to do with packaging. If your web-app uses a certain facade interface to do persistence/transactions then that's it - you isolated it. You can put the implementation of that facade anywhere you want (packed in war/lib, on the app-server classpath or exposed as a remote service) , it will not change it's semantic.
