How to do simple authentication in resteasy? -
i tried this
final nettyjaxrsserver server = new nettyjaxrsserver(); server.setdeployment(deployment); server.setexecutorthreadcount(1); server.setport(port); server.setrootresourcepath(""); final simplesecuritydomain securitydomain = new simplesecuritydomain(); securitydomain.adduser("user", "123", new string[] { "admin" }); server.setsecuritydomain(securitydomain);
and annotation request handler this
@path("") @rolesallowed("admin") public class mossroserequesthandler
but server returns response code 200 , empty content. server works when securitydomain set null. help? much!
Comments
Post a Comment