Bug 277181 - org.eclipse.core.filesystem.filesystems invokes extension for closed projects
Summary: org.eclipse.core.filesystem.filesystems invokes extension for closed projects
Status: ASSIGNED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Resources (show other bugs)
Version: 3.5   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-Resources-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-05-20 14:09 EDT by Dan O'Connor CLA
Modified: 2019-09-06 16:06 EDT (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dan O'Connor CLA 2009-05-20 14:09:39 EDT
Build ID: 20090513-1800

Steps To Reproduce:
In our code we extended Eclipse using the org.eclipse.core.filesystem.filesystems extension point.
We created a class which extends org.eclipse.core.filesystem.provider.FileSystem.
When our product is shutting down we close all .project files(IProject.close) that we own. Each .project is associated with our extension of the filesystem by way of Scheme look-up:

  <extension
         point="org.eclipse.core.filesystem.filesystems">
      <filesystem scheme="abcd">
         <run class="com.ibm.MyFileSystem"/>
      </filesystem>
   </extension>
   <extension
         point="org.eclipse.ui.ide.filesystemSupport">
      <filesystemContributor
            class="com.ibm.MyFileSystemContributor"
            label="Custom Virtual File System"
            scheme="abcd"/>
   </extension>

In the .project files the URI is stored as URI//abcd:/Local/MyProject. 

The issue is during Eclipse workbench start-up, at that point the Eclipse filesystem reads the workspace for projects and if it encounters a project which requires a contributed filesystem to read it, it automatically instantiates that file system regardless of whether or not the project is open or not.
In our case we do not want our MyFileSystemContributor class to be initialized unless a project is open that requires our code to read it. 

More information:
Comment 1 Szymon Brandys CLA 2009-05-21 07:44:09 EDT
I can see it too. Could you explain why you don't want to initialize MyFileSystemContributor?
Comment 2 Paul Webster CLA 2009-05-21 07:49:57 EDT
(In reply to comment #1)
> I can see it too. Could you explain why you don't want to initialize
> MyFileSystemContributor?

It would cause plugin loading for a project that cannot have its resources accessed.

PW
Comment 3 Szymon Brandys CLA 2009-05-21 08:18:45 EDT
(In reply to comment #2)
> It would cause plugin loading for a project that cannot have its resources
> accessed.

Right. I would rather like to understand if the problem is "loading the plug-in" itself or there is another issue caused by this.

Comment 4 Dan O'Connor CLA 2009-05-21 09:51:10 EDT
The issue here is loading the plug-in. I am working on a project where we have multiple products being contributed to the same eclipse install.
Product A contributes to org.eclipse.core.filesystem.filesystems, Product B does not. When Product B launches eclipse reads the workspace, which is OK. However all projects are closed, and the contributor to org.eclipse.core.filesystem.filesystems still gets initialized even though it basically can do nothing until the project is opened, which will not happen in this case as Product B does not use Product A's contribution to the file system.


The issue here is the plug-in being loaded for closed projects. The product I am working on is very sensitive to performance and plug-in start-up. If possible we would prefer if contributors to org.eclipse.core.filesystem.filesystems were only initialized when open projects were encountered.
Comment 5 Pawel Pogorzelski CLA 2010-01-25 06:28:58 EST
Moving to 3.6 M6.
Comment 6 Tomasz Zarna CLA 2010-02-19 05:50:30 EST
Deferring due to lack of cycles in 3.6M6.
Comment 7 Pawel Pogorzelski CLA 2010-04-19 07:16:52 EDT
Moving to 3.7.
Comment 8 Pawel Pogorzelski CLA 2010-08-02 12:54:02 EDT
Moving to M2.
Comment 9 Szymon Brandys CLA 2010-08-30 08:10:00 EDT
Moving the bug to the inbox. Pawel does not work in this area anymore.
Comment 10 Eclipse Webmaster CLA 2019-09-06 16:06:15 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.