May 21, 2012

Force.com Summer’12 Release Favourites !

Force.com Summer’12 Release brought some interesting and much awaited enhancements, this post briefs the ones that interested me most.

PDF Rendering Pipeline Optimizations

As the release notes say they have improved the processing to render the PDF pages faster. I came to know previously page is processed twice, thus constructors + action functions are invoked twice as well. This change is good, but I found few peers struggling with the same, even release notes warn to do extensive testing for this upgrade.

Apex Describe Support for Field Sets

Fieldsets helped a lot in bridging the gap between Admin and Developer, I loved and used them a lot in many of visualforce pages. Only gap felt was availability of the same in Apex, found a hack for the same few weeks back. But I’m glad that the same is coming natively in Apex now.

JavaScript Remoting Enhancements 

If you are developing an AppExchange app or managed package using JS Remoting, then you must have felt this pain i.e. having no namespace prefix vs having prefixes. This post from @WesNolte suggests a clean approach to handle this problem. Again as of fieldset this problem is solved natively by availablity of a new global variable in visualforce called “$RemoteAction”. This variable automatically resolves the namespaces just like $Page for visualforce pages.

Layout Attribute for Custom Components

“layout” attribute is added to custom components, that can help rendering the component either inline(span), block(div) or no wrapper.

Disable Development Mode Button

This button can help in quickly turning off the development mode, when no longer required.

disable development mode visualforce page

Referential Integrity Validation Improvements

Strong dependency checks are added to ensure visualforce pages and components are stable in case you are refactoring Apex classes for methods, types etc. This is important change, and sometimes tough to scan on own in a big code base.

Developer Console Enhancements

Their are many enhancements, my favourite are:

  • Performance Tree: To precisely know the space and time consumed in various operations.
  • Overlaying Apex Code and SOQL Statements: Ability to run a SOQL or Apex on heap dumps can be a time saver for sure.
  • Execute Anonymous Apex Code Enhancements: Ability to execute selected code is a great, we often end up writing lots of playground good in anonymous block, but limited code is required to be executed.

 

Separate Organization-Wide Defaults for External Users—Pilot

External users specially those coming from customer portals for sure need a separate boundary from the company’s internal users. Having separate OWD settings for such external users will be helpful, from both usage and performance reasons.

JSON Parsing Enhancements

Default lenient parsing, with option to do strict parsing is a great addition. Sometimes its really tough to create all the attributes to match the JSON structure. Apart from that  new “deserializeUntyped()” is great, specially for quick prototyping something on platform.

Callout Limit Increase for Batch Apex

This relieves a big pain, specially when you need to use data from one web service invocation as input to other. With limit raised to 10 from 1, no more hacks are needed now.

New Type Methods

These long awaited and discussed methods i.e. “forName()” are specially good for ISV’s developing AppExchange apps. This post from @cloudysan explains a real world usage with good example.

Sorting Support for Non-Primitive Data Types in Lists

Previously we need to use hacks to sort non primitive data types, for ex. one way to sort Apex SelectOption classes by label or value is listed here. With newly available “Comparable” interface one can easily define the sorting criteria, matching the business or sorting requirements. The plus of having native sorting ability is lesser consumption of script statements, specially when sorting big collections.

New Interfaces and Methods for Running Apex on Package Install/Upgrade and Uninstall

Interfaces like InstallHandler and UninstallHandler can be used to give interesting insights when customer performs either of the action.

 

Your thoughts

Looking forward to hear what summer’12 features interested you most.