Fix sort mode and made accessible to all sort descriptors
Serialize sorts as array instead of dictionary
Merge pull request #807 from elasticsearch/fix/sorting

Fix/sorting