Merged asterix_stabilization r529:r543.

git-svn-id: https://asterixdb.googlecode.com/svn/branches/asterix_fix_agg@544 eaa15691-b419-025a-1212-ee371bd00084