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 81895 - Create new External WSDL using remote file system throws NPE
Summary: Create new External WSDL using remote file system throws NPE
Status: RESOLVED DUPLICATE of bug 46813
Alias: None
Product: platform
Classification: Unclassified
Component: Filesystems (show other bugs)
Version: 5.x
Hardware: All Windows XP
: P2 blocker (vote)
Assignee: rmatous
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-04 02:18 UTC by Sreenivasan Genipudi
Modified: 2008-12-22 20:42 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 Sreenivasan Genipudi 2006-08-04 02:18:58 UTC
1) Create a new BPEL Module project
2) On Source package folder, right click and create new File 
   (XML -> External WSDL File )
3) Choose From Local File System
4) Choose a network folder that is accessible from your machine 
   .Make sure that folder contains atleast one valid  WSDL 
   
    The entry will look something like 
     "\\remotemachine\mydirectory\wsdl" ( Windows ) 

5) Click finish - Then it will throw exception dialog with - NPE
   
java.lang.NullPointerException
	at org.openide.filesystems.FileUtil.copyFile(FileUtil.java:210)
	at
org.netbeans.modules.xml.retriever.ImportDirectory.copyFiles(ImportDirectory.java:164)
	at org.netbeans.modules.xml.retriever.ImportDirectory.run(ImportDirectory.java:127)
[catch] at java.lang.Thread.run(Thread.java:595)
Comment 1 Girish Balachandran 2006-08-05 01:39:36 UTC
Importing files from a network drive is not a very strong use case. Downgrading
to P3.
Comment 2 Girish Balachandran 2006-08-29 01:04:44 UTC
The root cause of the problem is the FileObject API in Netbeans. I am trying to
do the following:

FileObject source = FileUtil.toFileObject(FileUtil.normalizeFile(srcFile));

this gives me a null source if srcFile is of the format
"\\remotemachine\mydirectory\wsdl" on windows. java.io.File API is able to
handle file with this path but not the FileObject.

This problem is seen many ways in the Netbeans IDE. Here are some examples:

1. Try to add "\\remotemachine\mydirectory\wsdl" type folder in the "Favorites"
tab and nothing will be mounted.

2. Try to open a Java Project from a "\\remotemachine\mydirectory\wsdl" path.
You will notice that the contents are seen in the FileDialog, but the NB project
folder is not recognized.
Comment 3 Girish Balachandran 2006-08-29 01:22:27 UTC
I changed the retriever wizard to print error messages in the output window
instead of ugly NPE. Once Netbeans FileObject (FileUtil) bug is fixed, this bug
will be fixed completely.
Comment 4 rmatous 2006-09-15 14:49:41 UTC

*** This issue has been marked as a duplicate of 46813 ***