Displaying homepage on localhost REST+ JAVA -
i have written rest+tomcat+jersey java application , rest oft paths homepage working fine. however, localhost:8080 returns 404 because there's no function points it. in:
@path("/") @produces({mediatype.text_plain}) public string homepage(){ homecoming "homepage"; }
i have tried using "/" path doesnt seem work. how proceed? thanks!
if deploy war named foo
tomcat listening @ http://localhost:8080/
, root of war available @ http://localhost:8080/foo/
.
if jax-rs application configured utilize additional path segment bar
, homepage
resource available @ http://localhost:8080/foo/bar
.
check bailiwick of jersey configuration in application value of bar
, if there any.
java rest
No comments:
Post a Comment