Ajax response console show
XMLHttpRequest cannot load http://127.0.0.1:8080/jerseyStock/services/stockJersey/getStock?stock_id=0050&stock_name=. No ‘Access-Control-Allow-Origin’ header is present on the requested resource. Origin ‘http://localhost:8080’ is therefore not allowed access.
Create a new filter, which will set the header response
Edit web.xml add those lines

