Improve sorting and serialization of TransformLargeRdf2