FeatureOnDemand

Note: This is the original page about the Feature On Demand idea, which has already materialized in the IDE (since NetBeans 6.7). For more information see FitnessForever.

Consumer IDE: Get What You Want, When You Want It

Motto: Nobody needs it all!

Full version of the NetBeans IDE provides instant support for variety of technologies. The current list is impressive and still it is growing up pretty quickly. On the other hand, not all people really need assistance with everything. In spite that the major downloaded configuration of the IDE is Full (who would like to get small, if one can get all), still it is clear that majority of our users is sticking with plain desktop and web applications:

Image:DisplayChart_FeatureOnDemand.png


Source

It is quite good to have the rest of the tools instantly ready, however there are also costs for doing that including increased demand on memory and start up time. As the situation will only get worse (read: support for various technologies will get better and each will want to be in Full IDE), we need a radical shift. Having support for technologies instantly ready is good, having bloated IDE is bad. This proposal outlines general, future oriented solution that solves the problem right now, however, and more importantly, it also sets correctly the future direction, that will eliminate such problem in future and for ever.


Contents


Scenario

  1. User download&install Full IDE
  • IDE contains basic functionality only
  • but contains UI of all tools like Full IDE, i.g. all Project Types like C/C++, Module Development
  1. Create some project (C/C++)
  • open New Project wizard
  • if the asked feature hasn't been present yet then will be downloaded and installed
  • wizard continues and completes creating C/C++ project

UI Specification

Read more...


Possible UI entry points

  • New Project wizard P1
  • New framework for Web project (both during new project wizard and in project properties) (VisualWeb P1)
  • Open Project dialog and other means of opening a project (select in project) P1
  • P1 detect visual web extensions (can be done in web project itself)
  • P2 the prominent place to support download of kits on demand
  • Open file (find target feature by file type) from explorer P2
  • Open file with File/Open... P2
  • How to recognize WSDL and other XML like files? Potentially reuse definitions of declarative mimetypes, Services/MimeResolvers/**
  • What if there are multiple choices - select the one like in "Full IDE"
  • New File wizard P1
  • Needed by Other/Ruby, JSF/Visual Web Page, Others/Java Script, etc.
  • This build has to look like Full IDE
  • Main Menu item P1
  • Versioning Submenu, handcoded for menu and options?
  • Browsing through Tools/Options ???
  • Toplevel buttons: Ruby, C++, UML, with button "enabled" P2
  • Miscellaneous/Visual Web and other tabs P3
  • Editor/Code Templates/Ruby NO
  • Miscellaneous/Versioning/ClearCase NO
  • UML's "reverse engineer" project popup menu action P1
  • Java Platform Manager (Mobility platform)
  • Disable modules not used for longer time P3
  • How to verify consistency?
  • Automate build of FeaturesOnDemand config files
  • list of modules by default off P1
  • get UI entry points automatically P3 for 6.1, P1 for future
  • How to give user a chance to enable everything?
  • Add "Enable All" to UI of plugin manager
  • Give user a chance to enabled/disable the UI functionality of feature on demand P3
  • enable/disable UI entry points, do not touch current state of modules
  • support for download instead of just enable (maven, linux distros) P2
  • longer time for download
  • check for license panel


Prospective users

  • performance team - the FeatureOnDemand can be used as part of Fitness program to speed up startup of NetBeans IDE. Instead of giving Full version to all our users, they might get some smaller one which could then grow "On Demand". Following table lists times measured on Window computer having NetBeans as well as its userdir on a localdisk on a build made on 18th Jan, 2008:
Basic UML Mobility SOA Ruby Identity API support PHP Cnd Time  %
X X X X X X X X X 80s 100%
X X X X X X X X 80s 100%
X X X X X X X X 69s 86%
X X X X X X X X 70s 87%
X X X X X X X 63s 78%
X X X X X X 60s 75%
X X X X X X 60s 75%
X X X X X 59s 74%
X X X X 58s 73%
X X X 58s 73%
X X 57s 71%
X 56s 70%


These data are from NetBeans 6.0RC2:

Bundle Cold Startup Warm Startup
JavaSE 21 7
JavaEE 27 9
Mobility 24 7
CND 18 6
Ruby 18 6
Full 35 11


Another data (from August) compare startup of various add-ons over basic IDE:

Configuration Cold Startup
Basic 43 s
Base+Web 57 s
Base+Mobility 62 s
Base+UML 51 s
Base+SOA 67 s
Base+Ruby 58 s
Full 81 s


  • HIE team
  • NBI team

Yet more variants

  • Distribute Full IDE but most of module are disabled in default and will enabled on first usage
  • Wade Chandler - I think this would be best to be in place even if installing modules on demand. It would be nice for a module to have another notification tier such as nowUsed or firstUse so modules could defer loading different things. That would save memory, and make startup faster.

    It wouldn't make things snappy on first use though. It would be like loading a .NET web project after the IDE starts, it takes about 20 seconds the first time. To speed up startup times the modules could, use a warm up thread and spread out their initialization and other modules in the background, and then if they are needed on startup, say because a project was opened before etc, they could synchronize on some object and keep the project from loading until they finished initializing.

    Then maybe some kind of a special API for a module to put messages for different systems to use would be good. That way the user wouldn't be staring at a blocked screen wondering what is going on, and they'll know what is loading, and it could be used by any module to let the user know it is waiting on something else to load, of course too many loading messages may be annoying ;-), but if in the status bar it would probably be OK...at least better than nothing, and the messages could show only after a specified timeout had been reached...seconds or milliseconds.
  • More option on NB Download page :
  • small IDE and install later
  • full IDE but disabled most features (handy for CD distribution)
  • Hibernate features with rare usage (switch off them and enable again on next one usage)


Let's try it

  1. Install some recent NB6 or Dev build, not full IDE e.g. Java SE IDE
  2. Download and Install the NBM FeatureOnDemand/org-netbeans-modules-cndplaceholder_FeatureOnDemand.nbm (in Tools|Plugins)
  3. Try to create some C/C++ project
  • open New Project wizard
  • if the asked feature hasn't been present yet then will be downloaded and installed
  • wizard continues and completes creating C/C++ project

Outline

  • A dispatcher of UI based on Autoupdate API
  • The dispatcher providers UI actions like Project Types templates, top-menu actions for features which are not currently loaded in IDE
  • A contract (API) between the dispatcher and features about mapping templates/action to modules.
  • If an user invokes an action the dispatcher will find asked feature and install or enable it. After that the action continues.
  • If the asked feature is installed already then no dispatcher is called.
  • After uninstallation the feature its UI points are handled by dispatcher again.

Open issues

  • Designed only for Project/File templates and top-menu actions
  • Recognize VisualWeb project (probably shared with Web project), when install VisualWeb functionality
  • does web project knows about web project
  • do we need special UI?
  • speed up enablement of features, Jirka claims that module system has some cycle
Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo