Thursday, November 22, 2007

API Tooling is a work in progress

Lately I have had the chance to work on a new project a little outside the scope of debuggers: API tooling support for the platform. Ultimately the goal of this incubator project is to provide tools for 'working' with APIs. Working in this context is loosely defined as:

1. Manging API usage across builds/products
2. Creating API profiles to compare against
3. Tools to compare APIs
4. Tools to manage API breakage detection/repair
...

Alot more information can be found on the wiki for the project (here).

One of the features currently available in the project is the ability to manage API profiles. API profiles are considered to be a description of the API of a component (which can be a project, plugin, bundle, etc). These profiles can be used to compare current source to, or another component.

The following screenshot is the 'API Profiles' preference page used manage API profiles (hence its name :) )



Another feature is the ability to use Javadoc source tags to define API restrictions. The tags are provided as completion proposals for classes, interfaces, methods and fields. For example you could add a @noimplement tag to an API interface that clients are intended to use but not implement.

The following screen cap is a shot of a Java editor showing a variety of source tags.



These are of course previews of current ongoing work, so it could change at any time :)

Tuesday, October 30, 2007

One year of contributing

It has been exactly one year since I started working at IBM and one year since I started contributing to Eclipse.

To celebrate, I am spending the whole day testing!

... I suppose I could have tried to find something more fun to do. Maybe next week on my birthday (which happens to be Eclipse's birthday as well), I'll imbibe some kind of frosty beverage.

Monday, October 22, 2007

Searching Now Includes Launch Configurations

I love the community of Eclipse, and how some people, other than us committers take time to re-examine old bugs that they are interested in. Most recently bug 57515 was re-examined by the community, which resulted in the patch being committed, and the debug team having a new feature to brag about :).

Without further ado, this post is about searching, search participants and the new-fangled feature that returns launch configurations as search matches (when looking for Java types). To be more explicit, only launch configurations that have a main type attribue to search against will be found as possible matches.

Ok so really that last paragraoh was all there was to say about searching, etc. But you can check out a snazy screenshot of the eclipse search view showing a Java launch configuration match.



Thanks again Peter for the patch for a cool feature.

Thursday, October 04, 2007

Import/Export Launch Configurations

This week I thought to myself, "lets fix a really old bug that has been marked LATER". So I went off looking for a bug or enhancement to try and find a good one. The best I could come with was importing and exporting launch configurations, bug 12898 (to and from the local file system). Rest assured there were a lot of cool bugs, but I also had to find one that would not take a long time to fix...

A good part of the idea behind this one was that not everyone uses CVS (or a variant) to share code (making shared configs almost useless). Most people also do not know where launch configuration files are stored in their workspace. With that in mind you can now fire up the export wizard, choose launch configurations, select the ones you want and the location to save them and PRESTO (not the pasta sauce) you get an instant copy of the selected configurations in that new location.

The export wizard


The configuration export wizard



Now lets say you have you have a bunch of launch configurations in a folder that you would like in your workspace, you can use the import wizard to make this happen. The import wizard uses the standard 'import resources' widgetry, so there should be nothing new in this wizard page (provided you have imported something from your file system before).

The import wizard



The configuration import wizard



You're welcome.

Wednesday, September 19, 2007

It never ceases to amaze me...

In the relatively small amount of time I have been contributing to Eclipse, I have grown to expect great things from the platform and the community. Yet, on a regular basis (often coinciding with updated new and noteworthy pages), I find myself thinking "Cool, I didn't know you could do that.". I am also constantly astounded by the enthusiasm, support and knowledge of Eclipse committers.

So what has caught my attention this week? Plug-in Spy is the tool I have been searching for since I started working on Eclipse. Now I can instantly determine the class for an open dialog, link to the source and edit it. Another useful feature that I found was the zip file comparator. I'm not sure how long it has been around, but I discovered that you can see the outgoing changes to a zip file in a nice directory structure with changes to individual files shown. I was also reminded of how powerful context launching is when it stopped working.

I stepped into PDE land for a couple of days to work on an import quick fix feature. The enthusiasm of the PDE team is unparalleled. Brian Bauman, along with other committers, made working on it both enjoyable and straightforward. Keep an eye on PDE's M2 new and noteworthy.

It was great to see a community member, Joe Pluta, step forward to help out with our M2 test-pass (there were only two committers available to test this week). I updated our Get Involved web page, and hope that others would consider helping out the debug team (or any other Eclipse team). There are many ways to get involved, including testing for defects, triaging bugs and contributing fixes.

Don't forget that Sept. 28th is Bug Day!

Wednesday, September 12, 2007

Sharing Makes the World Go 'Round

New API released in JDT Debug project: our Java launch shortcuts (finally).

Gone are the days of having to copy and paste all of our code so that you too can have a base Java launch shortcut with a couple of different 'tweaks'. Now every contributor has the use and extensibility of all of our Java shortcuts (and their parent abstract class) without getting those annoying 'discouraged access' warnings.

There are three classes in total, made available in the package org.eclipse.jdt.debug.launchConfigurations:

1. JavaLaunchShortcut (the abstract parent class)
2. JavaAppletLaunchShortcut (our concrete implementation for launching applets)
3. JavaApplicationLaunchShortcut (our concrete implementation for launching Java applications)

Wednesday, September 05, 2007

((Debug + Context Launching) >> 32)^2

New to 3.4 is context launching 2.0.

With this new addition people who want to take part in context launching but do not care about IResource's can participate as well. Gone are the days of context launching only working for 'things' that have an IResource adapter. Now anyone, using nothing more than the new API for a launch shortcut, can have a say what should be launched, or what resource should be launched (if any).

The new API in question comes from ILaunchShortcut2 (which surprisingly is an extension to ILaunchShortcut), and provides 4 new methods:

1. getLaunchableResource(IEditorPart)
2. getLaunchableResource(ISelection)
3. getLaunchConfigurations(IEditorPart)
4. getLaunchConfigurations(ISelection)

With these methods contributors can now tell context launching either which resource it should be launching, or what launch configurations it should be launching.

Tuesday, July 17, 2007

Out of Lockdown V2.0

As Curtis put it: it is nice to be out of the 3.3 lockdown. It means that we can start writing some cool code and adding in some cool new features. Curtis already told you all about the cool new dragging and dropping. I will tell you about non-resource based context launching.

You might remember back in 3.3M6 when we added in the new feature for context sensitive launching, heck you might even be using the new feature. For all the good that it brought to the world, it did have a severe drawback; it did not work with project artifacts that were not resource based (had or could get a handle on an IResource).

What we want to do now (in the start of 3.4) is extend context launching to allow contributors the ability to tell us how to launch something. That way if we don't know how to launch foo.xxp you can provide a context launching participant to tell us how you would like it launched.

We are hoping that this will bring together the best of all worlds of launching and make it even easier for novice to expert users to make use of launching/development in Eclipse.

Thursday, July 12, 2007

Escape from 3.3 Lockdown

It's so nice to be out of the 3.3 lockdown. We can finally put some new features in (plus there was time for a week long vacation in Rushing River). In the two weeks spent working on 3.4, the Debug team has already added many new fixes and features. One of these new features is dragging and dropping for the variables and expressions views.

To create a new watch expression for a variable in the variables view, you simply select a variable and drag it to the expressions view. You can even select multiple variables to create expressions for them all.

To create a new watch expression you can also drag text from the editor or anywhere that supports text dragging. Drag selected text onto the expressions view to create a new watch expression with the dragged text as its code snippet.

When dragging to the expressions view you can insert to a specific place in the view, or just add it to the end. You can also drag existing expressions to reorder them in the view.

During 3.4 the debug team is looking at other ways to use drag and drop to improve the user experience. If you have any ideas, leave a comment or file an enhancement request.

Thursday, June 21, 2007

Darin Wright, Champion Among Men

Today I would like to make a post telling everyone that our manager, Darin Wright is indeed a champion among men (not just to get a promotion).

On the ride to work today, as Darin rides his bike to work every day, he was hit by a truck. Luckily he was not harmed in any way, and yes the driver was talking on his cell phone and not paying attention.

But this is not what makes him the champ.

The fact that he walked what was left of his bike home, fixed it, and then rode it to work (again), and then once he got here was still happy to be at work, is what makes him the champ.

Axesome.

Wednesday, June 20, 2007

Facebook is the new Eclipse Hangout

For all you Eclipse Committers (and Committer wannabes) who hang out on Facebook at least once in a blue moon, Mike and myself have started a new group for you. The group is called Eclipse Committers and is of the type: Internet & Technology - Software.

So join up, say hi, and let everyone see all the embarassing information you leave on your Facebook profile.

Tuesday, June 19, 2007

iClipse

For all those Mac users out there, Eclipse 3.3 comes with an important fix. You can now run and debug applications on more than the OS default VM. We discovered that an environment variable on the Mac (JAVA_JVM_VERSION) controls which VM gets launched. Eclipse now modifies this environment variable for each new process (VM) that gets launched, to match the user selected JRE.

Monday, June 18, 2007

Cleaning the bug buckets

Over the last few weeks the debug team has been going through the dreaded and controversial "Resolved - Later" bugs and feature requests. I wasn't able to come up with the right Bugzilla query to get exact statistics, but I know we had over 800 Resolved-Later bugs last month, and now we're sitting at 715. Not bad - that's over a 12% reduction! Some bugs had been fixed along the way (always a nice surprise), some had become irrelevant, some were re-opened to be addressed, and some were even re-opened with fresh patches to be applied soon.

Just another seven months and we'll have had a chance to look at each one :-) Be patient.

Friday, June 15, 2007

One Europa Experience

I swear I'm not just doing this for the free shirt. With only 2 weeks to go until it is released, I figured it was time for me to get a taste of Europa.

The coolest thing about Europa is that it should make it easy to install a large number of tools. Using Europa, you spend your time using the tools, not installing them.

Does Europa do a good job at this? I'm not entirely sure, my experience was far from perfect, but I can't say I regret it.

The good:

- The ability to see such a wide variety of projects in the update manager, choose the ones I wanted and have the manager select all the required plugins is great. I was unable to resolve dependency issues for the Buckminster project, but I'll just assume that it will be fixed in the next couple of weeks.

- Once I had Europa up and running, I found a lot of axesome tools, many of which use the platform and/or the JDT debugger framework. I was impressed by the functionality available, so a pat on the back to all the teams out there creating these open source tools.

The not so good:

- The welcome page seemed so empty and not helpful considering how many tools I had installed.

- The preferences dialog is scary. It is a strong encouragement to use the default settings. Expect to spend a long time going through it if you like having everything configured the way you like it. Oh and don't forget to export your settings when you are done.

- Before I could even close the welcome page, Mylar was helpful enough to open a dialog, preventing me from doing anything until I set some preferences. What is so important about the Mylar options that they need a dialog on startup vs a preference page. This dialog got even more annoying when I clicked the link at the bottom to watch a video about getting starte with Mylar. The progress bar showed up for a second and that was it. Once I closed the welcome page (after just hitting okay on the dialog with the default settings), I discovered several web browsers open trying to show me a video (which had been moved due to the renaming of the Mylar project).

- After playing around with some of my freshly installed tools, I checked the log. Sure enough, errors galore from multiple projects. Europa is only 2 weeks away. Having dozens of errors in the log is not going to make us look good.

- While I found the update manager to be an effective way to install the tools, Mike may not agree. For starters while using Europa, his chair broke. The handle broke right off. Oh and his Eclipse installation crashed and wouldn't launch again.

Overall, I like Europa and I think it goes a long way to make it easy for users to get the projects they need. Plus, users who use Europa to get a couple of tools they need are likely to try out some of the other projects available. But things really need to be polished in the next couple of weeks.

Thursday, June 07, 2007

Whats Up Doc?

Ok, first off let me say I just couldn't resist on the title, I know it is corney, stupid, etc, but I had to let it out.

Todays post is about how much I love to write doc for our plugins and the number Z.

Writing doc is one of those things that we all hate doing, but we all agree needs to be done. This lack of enthusiasm is probably why it is put off until the very last minute in the release cycle instead of being done during the release cycle. I think deep down inside everyone really likes to write doc, as it takes us away to that magical "working but not really" place where we can spend hours and feel a sense of self worth....or not perhaps.

Let me leave this post on a positive note by saying how much I love to write doc.

Friday, May 11, 2007

Context Launching....Friend Or Foe

In 3.3M6 some of you might have noticed that launching has changed...just a little bit.

In an on-going effort to make the world of launching in Eclipse just that little bit easier for novice users, we have introduced the concept termed 'context launching'. The premise of context launching is that we do everything in our power to try and run whatever the 'thing' you have selected is; failing that we give you the option to try and run the project it is contained in (if there is one). Furthermore, during the context launching process we abstract the hassle of having to create launch configurations or activate shortcut menus by creating the configurations for you, and presenting 'ways' of launching for users to select (if there is more than one way to launch the 'thing' selected).

Lets stop here for a second so I can tell you that YOU CAN TURN CONTEXT LAUNCHING OFF on the launching preferences page if you don't want to be cool and use the newest coolest launching stuff (but thats fine, I am not in charge of your coolness, I only provide the tools to increase it, a-la your_coolness++).

Ok back to context launching and why you can't do without it.

To provide context launching (so far) we have taken all of the familiar launching artifects, like launch shortcuts, etc, and rolled them all into one, leveraging it such a way that you can simply press the run or debug button (when context launching is on that is) and have a configuration pertaining to what you are doing be launched. Right now context launching is limited to things that have an associated IResource (using adapters), but this will likely be extended in the future to include non-resource based stuff (see see this bug).

The upshot of this is that no matter if you are a plugin, java, etc developer there is no 'new' stuff to learn, all you have to do is press the button (or use the menu shortcut). Even if you spend days creating the best launch configuration in the world it will be used in context launching, as we also make use of your launch history and favorites to help make decisions about what to launch and when. The downside is that it does not cover 100% of the edge cases in launching (
see this bug).

There is more specific information about context launching and how we implemented it (see this document) if you are interested.

So for now, we'll leave it at that and I hope everyone enjoys context launching and provides feedback if they don't, but like I mentioned I cannot be responsible for any depreciation in your coolness if you don't like it.

This feature has officially been labelled Axesome.

Friday, March 30, 2007

Export More Stuff For Everyone

Are you one of those people that just has to have everything just so? even to the point of having your collection type variables show exactly how you want them? Well if you are you no longer have to fear losing all of those custom logical structures you speant so many hours making.

You can now export and import Java logical structure preferences separate from other workspace preferences. Java logical structures are defined on the Java > Debug > Logical Structures preference page.

This is a cool feature...but not quite axesome.

Hyperlink Debugging

I know I have been silent for qute some time, so I figured it was time to come back to the blogosphere and drop some more knowledge. This time (nothing like that breakpoints post) we have an axesome new feature which is proving to be far more handy than any of us could have really imagined (except Darin of course because he knows everything); Hyperlink Debugging.

The idea behind hyperlink debugging follows that useful feature that pretty much everyone already knows about: hyperlink open declaration (Ctrl+Click in editors open declarations). Except in our case you can do lightning fast step-into operations with but the press of Ctrl+Alt and a click of the mouse....not impressed yet? check out the example.

Lets say you wanted to step into the createComposite method shown below:

SWTFactory.createComposite(getParent(), mainComp.getFont(), getStyle(), getFill());

The old way, you would have to step into and out of all of the method calls in the createComposite method prior to stepping into the one you wanted. You could of course use the old passe method of step into selection...but just imaging being able to step into creatComposite with a single click...no more selecting code, no more repetitious step into/out of code.

You can even select what keys to use as modifiers (thanks to the jdt UI guys of course).


I know what you are thinking....Axesome.

Thursday, February 15, 2007

Custom Detail Pane Widgets

First off, let me introduce myself to all you avid Debug Team Blog readers. My name is Curtis Windatt and I am the newest member of the debug team. I have been working with Darin and Mike at IBM in Winnipeg for almost four months now and I am looking forward to receiving commit rights to the debug projects in the not so far off future.

The first major feature I worked on is adding support for custom detail pane widgets (Bug 75852). This feature allows plugins to contribute new detail panes. The “detail pane” is the area in the variable, expressions and registers view that displays information about the currently selected variable. Up until now, the detail pane could only display text.

Now it can display colours! This custom pane changes background colours depending if the selected element is public/private/etc:


Of course, it can display much more than that. A custom detail pane is defined by implementing org.eclipse.debug.ui.IDetailPane. The pane can contribute any SWT Control, including Composites that contain multiple controls, to the detail pane. When the user makes a selection the custom pane is passed the selection so it can display the information however it wants. The user can use the context menu to choose between the different detail panes available for the current selection.

To contribute a custom detail pane you must use the new extension point org.eclipse.debug.ui.detailPaneFactories. At this extension point you specify a class implementing org.eclipse.debug.ui.IDetailPaneFactory. Each contributed factory will be asked what detail panes that factory can produce for a given selection. A factory can offer different combinations of detail panes depending on the selection. For example, a pane might only be available when 2 or more java variables are selected. To reduce plugin loading, plugins can also add enablement expressions to the extension so that the factory is only instantiated if the selection applies.

We are looking forward to seeing what people can do with this new feature. Leave a comment or send us an e-mail if you create one. In the future we will try to make an example plugin and possibly a short tutorial available.

Tuesday, January 09, 2007

All About Perspective

In line with the changes to the launching framework (retargetting launch delegates, etc), we thought it would be a good idea if we could also fit the 'new way' of launching into the existing perspective switching way of things.

We felt that with such fine control (now) over how and what does the launching, it would be a nice addition to extend that notion to perspective settings. For example, consider you have two profilers that both launch a Java application with profile options. Traditionally this would have led to perspective switching based on which-ever launch delegate was chosen in the end, leaving the user no control over what would be switched to based on what did the launching.

Now however, the user can select down to the launch delegate level to specify launch perspective settings. Changes to these setting can be applied on the Perspective preference page as before, with the only notable change being to the launchers tree (see screen shot).

This new page design also allows multiple perspectives to be set at one time, i.e. you can multi-select items in the tree and set perspectives for common modes to all delegates/types in the selection. You can also over-write common perspective settings for launch delegates of a particular type by changing the perspective settings of that type.

This new hotness is available in builds >= Jan 9 2006