toArray and toString are critically memory-intensive calls for any large dataset. We are already operating in ES environments with limited memory and these methods will punish the library when GC panics.
What is the purpose of toArray anyway? The way I see it, there are no legitimate use-cases for an array of quads that cannot be handled by Dataset alone or in tandem with a serializer.
toString is also redundant. This sort of task should be handled by piping to a serializer. We should document all these as examples.
toCanonical is another dangerous 'buffer-everything-into-a-string' method. This should be replaced with a method that returns a new Dataset, and complemented with another method that returns the normalized hash string of a dataset.
toArrayandtoStringare critically memory-intensive calls for any large dataset. We are already operating in ES environments with limited memory and these methods will punish the library when GC panics.What is the purpose of
toArrayanyway? The way I see it, there are no legitimate use-cases for an array of quads that cannot be handled by Dataset alone or in tandem with a serializer.toStringis also redundant. This sort of task should be handled by piping to a serializer. We should document all these as examples.toCanonicalis another dangerous 'buffer-everything-into-a-string' method. This should be replaced with a method that returns a new Dataset, and complemented with another method that returns the normalized hash string of a dataset.