Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 152701

Summary: wsdl validation done on local file even when turned off
Product: [WebTools] WTP Webservices Reporter: Andrew Mak <makandre>
Component: jst.wsAssignee: Chris Brealey <cbrealey>
Status: CLOSED FIXED QA Contact: Chris Brealey <cbrealey>
Severity: normal    
Priority: P3 CC: kathy, mahutch
Version: 1.5   
Target Milestone: 1.5.1 M151   
Hardware: PC   
OS: Windows 2000   
Whiteboard:
Attachments:
Description Flags
Patch fix.
none
Patch fix. none

Description Andrew Mak CLA 2006-08-03 00:13:57 EDT
In the web services wsdl selection dialog box, validation is done on local file even if the preference is set to validated only remote files.  This only happens if the filename is of the form "file:/<some_path>".

To reproduce:
=============
1. Ensure validate local file is turned off:  Goto Window > Preferences > Web Services > Profile Compliance and Validation.  Select "Wizard WSDL validation for remote files only" option.
2. Import any wsdl file into a project on for workspace, i.e. /MyProject/WebContent/AreaService.wsdl
3. Select the imported wsdl, right click, select New > Other > Web Services > Web Service.  Click Next.
4. At the next page, click "Browse" beside the Service Definition field.
5. wsdl validation is performed, note that the wsdl file is listed as "file:/<some_path>/MyProject/WebContent/AreaService.wsdl"
6. Change the file name to just "/MyProject/WebContent/AreaService.wsdl", the dialog will give the message "Wizard WSDL validation is only enabled for remote files."
Comment 1 Chris Brealey CLA 2006-08-03 09:24:18 EDT
Created attachment 47316 [details]
Patch fix.

Andrew, good catch. Please try the attached.

This patch also fixes a layout issue with the two validation text fields sandwiched between the validation messages table and the "stop validation" button in which. I don't know if you saw this behaviour, but the initial WSDL browse dialog was opening for me with the two text fields heavily clipped. Increasing the size of the dialog reveals the text fields, and decreasing the size clips them further. This patch locks sets the minimum height of both text fields to SWT.DEFAULT.
Comment 2 Andrew Mak CLA 2006-08-03 10:11:21 EDT
The fix worked great, thanks.

For the clipping problem, there was actually another bug opened for that problem (bug 152156).  The fix there is slightly different, please take a look.
Comment 3 Chris Brealey CLA 2006-08-03 11:41:36 EDT
*** Bug 152156 has been marked as a duplicate of this bug. ***
Comment 4 Chris Brealey CLA 2006-08-03 11:47:30 EDT
Created attachment 47335 [details]
Patch fix.

Andrew, thanks for the pointer to bug 152156. I've switched over to using "new GridData(SWT.FILL, SWT.FILL, false, false)" (shared by both text controls).
Comment 5 Chris Brealey CLA 2006-08-03 14:23:18 EDT
Committed. Will release after this week's M build is declared.
Comment 6 Chris Brealey CLA 2006-08-09 11:48:10 EDT
Released with tag v200608091548 for inclusion in the 8/11 WTP1.5.1 M-build.
Comment 7 Chris Brealey CLA 2006-08-09 14:21:05 EDT
*** Bug 153326 has been marked as a duplicate of this bug. ***
Comment 8 Andrew Mak CLA 2006-09-05 12:57:09 EDT
Verified in M200609051217 wtp build.
Comment 9 Chris Brealey CLA 2006-09-07 14:16:26 EDT
Closed.