Ads are not an endorsement by the blog author.

Dan's Developer Diary (3D)

Public Journal
A journal of things related to my work. Archives | Subscribe to Alerts Alerts Subscribe to Alerts | Feeds
 
Wednesday, February 13, 2008

Dojo Developer Days IV - Day 2 wrapup

Happy


I attended DDD:IV last week held on Google's campus.  Here are some notes on what happened.
 
The recap from the day before (Contributer Day) was:
- 1.1 beta by end of Feb.
    - Improvements on dojo.data and dojox libraries. 
    - A couple of widgits graduating to dijit from dojox.  (Wizard, ScrollPane, BorderContainer: combines LayoutContainer and SplitContainer)
    - Ability to rebuild layers. 
    - JSONPath
    - New RPC system, currently in dojox (uses SMD)
 - There will be 3 major releases this year (to 1.3).  Most of the work will be outside of core.
 
For half of the day a couple of SitePen people were giving basic demos of how to use Dojo.  Meanwhile the contributers were doing a hack-athon in the back of the room working on documentation and examples for the dojotoolkit.org website.
 
During lunch it was demo time with 10 minutes per presenter to show something they were working on.  People came with demos of Cometd, dojox charting, SitePen projects, dojox DTL (Django Template Language).  I gave a presentation on our performance gains moving from dojo 0.43 to 1.0, which got a great response from Alex Russell and other dojo contributers.  They even asked for a demo of Webmail.  Afterwards Brad Neuberg, creator of dojox offline and Google Gears developer, wanted to know if we were thinking of the offline potential.  Lastly someone showed off a fun copy of Scriptaculous' home page with dojo.moj.oe (http://dojotoolkit.org/~dante/dojo.moj.oe/mojo.html)
 
Finally the last part of the day had longer presentations on dojo accessibility and creating a dojo theme.
 
Overall it was time well spent, most people there are interested in how the real world uses dojo, and it's good to immerse yourself in dojo-land every now and then.  I look forward to following up how we can benefit whether it be offline, dojo.data, or any number of improvements coming our way.


Tags:


danielruspini1 at 10:29:23 AM PST Permalink | Blog about this entry
This entry has 0 comments: Add your own

Thursday, August 2, 2007

TAE sessions - Dojo 0.9: Faster, Leaner and Dijit?

Last week I went to the Ajax Experience conference in San Francisco.  It was 3 days packed full of sessions of which I attended about a dozen.  Here is a review of one of those sessions, Dojo 0.9.  I'll send out more notes as I have time to write them up.

 

Dojo 0.9: Faster, Leaner and Dijit?  (Dylan Schiemann - Dojo co-creator)

This session was cool because although I'd heard a lot about what was happening with 0.9 this was the first time I'd seen some of the changes and real size/performance numbers.  The idea behind 0.9 was to scale down the code which had grown bloated over time due to the nature of the core principles: support as many browsers as possible, allow contributers to add widgets to the widget library, support backwards-compatibility code.  What they found was that 30% of the code was expendable.  Also the widgets had been written in a variety styles and were not all consistent in use; while others were not used by most developers.  In some cases very popular widgets were trying to do too much by covering every possible use case which made them slow (ex. Button). 

 

Dojo 0.9 is a rearchitecture in that many of the namespaces have changed, the API trimmed (ex. won't support 14 different args to connect an event), and there will be no backwards-compatibility support for 0.4x.  There will also be no v0.5-v0.8, the idea is for 0.9 to be the beta for 1.0 which should be ready before the end of 2007.  They've also had the chance to integrate new ideas and rework 0.4 pain points (blank page problem, module overload, "spaghetti requires", markup parsing performance, widget layout performance, spotty theme support, inconsistent documentation, too much "magic"/cleverness).

 

Dojo 0.9 is now 3 top-level projects.

  • Core - The main API (Dojo Base)
  • Dijit - Most used widgets (all support I18N, accessibility, theming).  Also notable is removing templateCSS support, now all CSS will be together which should make for less CSS.  New Tundra theme across widgets, they all look the same out of the box!
  • DojoX - Experimental or less used API. (dojox.gfx, offline, comet, charting, event advice)

They've dumped Ant in favor of a Java-based process which works well with Rhino.  I think we've already done a lot of this for Webmail, but you can build your code, not just Dojo code, can "intern" templates, create layered builds.

 

Performance!

I’ve copied this all from the slides, so feel free to look at them in pretty graph form here:

http://ajaxexperience.techtarget.com/images/Presentations/Schiemann_Dylan_Dojo_0.9.pdf

 

Build Sizes

Variant

0.4 “Ajax

0.9 Base

Uncompressed

319K

169K

Built

148K

43K

gzipped (OTW)

39K

20K

 

More Build Sizes

Variant

0.4 “Widget”

0.9 Base + Digit

Uncompressed

443K

233K

Built

197K

61K

gzipped (OTW)

53K

29K

 

Other interesting numbers

0.4.3 vs. 0.9 Object Allocation

Ajax” build = ~30% less

Widget infrastructure = ~30% less

100 widgets = ~60% less

 

0.4 vs. 0.9: Micro Benchmark

100 buttons (programmatic) and 100 buttons (Markup)

Look at the PDF for somewhat exact numbers, but suffice it to say they look VERY good…drastic improvements

 

We’re now in the under 1 second category when it used to be upwards of 10 seconds.

 

Results

50-66% Smaller

5-20x Faster

35-50% Fewer Objects = less memory and CPU utilization

 

 

Furthermore, there are a few new parts of Dojo that will help us rely less on widgets.

 

Introducing dojo.behavior

Not everything needs a widget

Progressive enhancement

Apply JavaScript to CSS selectors

 

dojo.query

The basis for widget parsing and for behavior

Accepts most CSS3 selectors

Supports scoped queries

Returns a “real” array

Really, really fast

Comparable to jQuery

 

Finally what good would a new dojo be without a new powerful new testing tool….

 

Testing: “D.O.H!” The Dojo Objective Harness

D.O.H (think Homer Simpson) is the new unit testing platform.  Can be used command-line or within the browser.

 

My final thoughts

I ran into Alex Russell (co-creator Dojo) in the hall and asked his opinion on how much time it would take to port a dojo RIA to 0.9, and he told me around 2 days.  So translate that to a bigger app like Webmail and I'm hoping that we're talking realistically like 2 weeks.

 

Feel free to send me questions and if I can’t answer them I’ll make sure they do get answered by some one inside the Dojo community.



danielruspini1 at 3:37:45 PM PDT Permalink | Blog about this entry
This entry has 0 comments: Add your own

Tuesday, July 31, 2007

The Ajax Experience West (July 25-27, San Francisco CA)

Walking away from the Grand Hyatt last Friday I had the feeling that although the developer community is large, there is a strong sense of unity and direction amongst us.   Throughout the 3 day conference the defining theme was that we are all in this together and we have the opportunity to pave the road in front of us.
On the last day of the conference I attended the Future of Ajax panel discussion.  On stage were Brenden Eich (Mozilla), Douglas Crockford (Yahoo!), John Resig, Bill Scott (Yahoo!), and the Ajaxian MCs Dion Almaer and Ben Galbraith.  They participated in prepared discussion topics as well as answer questions from the audience.  What struck me more than ever before is that developers and the people who create the browsers were talking about where to go next, what works, what is broken, and who was doing what to make progress.  A comment was made that developers have pushed the boundaries of the browser once again and that the browser makers need to catch up.  Between the remarks of Chris Wilson (Platform Architect of Internet Explorer) and Brenden Eich I was certain they were listening to the audience in regards to what standards should be and where they might concentrate their efforts.  For the first time ever it seemed like we were all in the same game, the browser companies were not these monolithic faceless entities shipping browsers that developers had to create hacks for to make work the way they wanted.  Finally, although still perhaps a few years away, we've agreed to work together and get over the hurdles so we can enter the next phase of web development.
(jQuery/Mozilla),

danielruspini1 at 11:34:36 AM PDT Permalink | Blog about this entry
This entry has 0 comments: Add your own