This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 212509 - Test Resource Uri doesn't work
Summary: Test Resource Uri doesn't work
Status: VERIFIED FIXED
Alias: None
Product: webservices
Classification: Unclassified
Component: REST (show other bugs)
Version: 7.2
Hardware: PC Windows 7
: P2 normal (vote)
Assignee: Denis Anisimov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-15 09:06 UTC by Jiri Skrivanek
Modified: 2017-07-26 12:44 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Skrivanek 2012-05-15 09:06:04 UTC
Product Version: NetBeans IDE Dev (Build 201205150400)
Java: 1.7.0_04; Java HotSpot(TM) 64-Bit Server VM 23.0-b21
System: Windows 7 version 6.1 running on amd64; Cp1250; en_US (nb)

REST web service created from wizard is not available with Test Resource Uri action. To reproduce:

- create web application with GlassFish 3.1.2
- open new file wizard
- select "Web Services|RESTful Web Services from Patterns"
- click Next
- choose "Simple Root Resource" design pattern and click Next.
- provide package name, change mime-type to text/plain
- click Finish
- return valid string in getText() method
- deploy project
- right-click "RESTful Web Services|Generic Resource[generic]" and call "Test Resource Uri". It fails with error message:

Unable to open resource url:
http://localhost:8080/WebApplication1/webresources/generic
Comment 1 Jiri Skrivanek 2012-05-15 09:20:26 UTC
It works with Java EE5 project. It seems "REST Resource Configuration" dialog is not displayed with Java EE6 project.
Comment 2 Denis Anisimov 2012-05-15 09:22:31 UTC
Bad issue evaluation.
"Test Resource Uri" action doesn't work because REST is not configured.
So this is not original problem but just a consequence.
The issue is a regression after changing "REST configuration" approach.
Generated ApplicationConfig class doesn't extend javax.ws.rs.core.Application.
As result REST is not configured and just doesn't exist on the server side.
That's the main issue.

Should be fixed by correcting ApplicationConfig class generation.

JEE5 and JEE6 profiles have different ways of REST configuration.
Comment 3 Denis Anisimov 2012-05-16 08:03:02 UTC
web-main#1f597d3280f2