any services is better to be as java package (OSGi bundles). Problem with JQuery would be, if there are any JS errors for some UI bug, then your service might also stop working, keeping services at the front end is not recommended.Security can still be achieved if you have written the java webservic...