users@jersey.java.net

[Jersey] Re: Hello ,somebody could help me why this code alwaysreturning 404?

From: Redmond_at_139. <redmond_at_139.com>
Date: Fri, 2 Oct 2015 23:51:23 +0800 (CST)

Hello sir
  thank you for replying me,no I'm not build it as a war package.I just trying to debug it,just click run on Eclipse
regards
Ken





--------------------------------------------------------------------------------




------------------ 原始邮件 ------------------




 
 发件人: Pavel Bucek <pavel.bucek_at_oracle.com>
 

 
 发送时间: 2015-10-02 23:47:15
 

 
 收件人: users <users_at_jersey.java.net>
 

 
 抄送: (无)
 

 
 主题: [Jersey] Re: Hello ,somebody could help me why this code alwaysreturning 404?
 



 Hi Ken,
 
 we will need to know more info - for example, how do you build this (is it a war?), where do you deploy it, what returns 404?
 
 looking at web.xml - you seem to use doc from Jersey 1.x (com.sun.jersey.* classes), but you have Jersey 2 in WebContent/WEB-INF/lib directory.
 
 Maybe you should start with something which work - feel free to check-out Jersey 2 examples:
 
 https://github.com/jersey/jersey/tree/2.x/examples
 
 try "helloworld-webapp" first.
 
 https://github.com/jersey/jersey/tree/2.x/examples/helloworld-webapp
 
 Hope it helps,
 Pavel
 
 
On 02/10/15 17:36, Redmond_at_139. wrote:
 
 

 hello sir/madam
    this is my program in github,https://github.com/abcdef123ghi/jerseytest ,there are no errors in Eclipse,However it always returing the 404,any help would be appeciated.Although I'm not familar with Java,but with Google & Jersey docs,I have written the code and there are no errors,but it can't be started.I'm very confused.
 regards
 Ken