P4WSAD 2009.1 and introducing P4Java
The 2009.1 version of the Perforce Eclipse Plug-in, P4WSAD, has been released and it now uses the new Perforce Java library, P4Java. This is an important milestone for P4WSAD as it no longer requires the P4 command line to run Perforce server commands. The P4Java library is a pure Java implementation of the Perforce client/server protocol. The server commands executed through P4WSAD will now run in-process using standard Java file and socket libraries to do things such as syncing, fstat'ing, editing, reverting, and submitting.
P4WSAD Connections view
P4Java is available as a stand-alone JAR file that can be used to write Java applications that interact with a Perforce server. P4Java only requires the standard J2SE libraries and can be deployed and run cross-platform wherever a 1.6+ JVM runs. P4Java is an officially supported API with available Javadoc and usage guide. It can be used for integrations into things such as Ant, Hudson, Maven, called from servlets, JSPs, or used for IDE plugins (such as P4WSAD).
Besides the new underlying P4Java library there are also many new features included in the 2009.1 P4WSAD release. The focus of this was release was adding new functionality that would enable developers to stay inside Eclipse for the most common Perforce tasks. In previous release these tasks had to be done either through the command line or P4V. This release includes new features to create and edit Perforce clients and jobs, integrate branches, browse labels, add/remove files from labels, set the status of jobs upon changelist submission, and force sync a selection of files and folders. All of these options are now available from menu and toolbars in the Perforce views or Eclipse resource views.
Other notable new features in the 2009.1 P4WSAD release are described below with screenshots. There are many other new features not mentioned as well as numerous bug fixes. View the P4WSAD 2009.1 release notes to see the complete list of bug fixes and enhancements.
P4WSAD Connection Wizard
A new connection wizard was added that allows you to browse existing clients or to use or create a new one and also allows you import projects directly into Eclipse upon finish. This is available from the P4 Connections view or the New->Other...->Perforce->Perforce Connection menu.
P4WSAD Connection wizard client page
P4WSAD Connection wizard import projects page
Improved Refactoring Support
Refactoring support from P4WSAD was also improved in this release. The 2009.1 release of the Perforce server added the move command which is now the new default command used during refactoring. This allows you to refactor multiple times before submit which was difficult in previous releases since a combination of p4 integ, add, revert, and delete commands were used. Also new in P4WSAD is refactoring support for files set as always writeable (+w). Enabling this option will cause these files to now be checked out when saved from an Eclipse editor or when modified during a refactoring operation.
Synchronize view showing refactoring using 'p4 move' command
Customizable label decorations
A long absent feature in P4WSAD was the ability to customize the label text and image decorations to the granularity that other SCM plugins offered. The 2009.1 feature includes this level of decoration customization with support for fully customizable text and label decorations with a preview pane showing examples of all decoration types. Also new in this release is a special decorator files for files included in .p4ignore files.
P4WSAD image and text label decoration preview
Perforce Label Support
Support was added for creating and modifying Perforce labels from within Eclipse. You can now select one more files/folders and select to tag them with a label or remove them from a label. Also added was a labels view that can be searched and selected labels can be synced to.
P4WSAD tagging selection with a label name
External Tools support
One last important feature added in this release is the ability to select files from Eclipse and bring up the P4V Revision Graph or Time Lapse view. Also P4Merge can now be utilized from Eclipse for files that need to be resolved. In previous releases the workflow was quite poor, you would have to leave Eclipse, find the file in P4V and launch the tools from there. The 2009.1 P4WSAD release puts these tools at your fingertips from within Eclipse once the paths are configured.
P4WSAD External Tools preference page for P4V/P4Merge