As we transition to the new Hyland Community, some post links may be temporarily disrupted as we finalize redirects. We apologize for the inconvenience and are working to resolve this as quickly as possible. Details.
Nuxeo Folks: KeyValueBlobTransientStore.getBlobs can return Collections.emptyList which you can't add to. However, SimpleTransientStore.getBlobs returns an ArrayList and so a unit test that expects to be able to add to the return value from getBlobs can pass, but then fail if deployed over a K/V transient store...
KeyValueBlobTransientStore.getBlobs
Collections.emptyList
add
SimpleTransientStore.getBlobs
ArrayList
getBlobs
The Javadoc for TransientStore.getBlobs doesn't promise anything about mutability of the returned List, so you shouldn't assume that it's an ArrayList even though that's the case for the current implementation of SimpleTransientStore.
TransientStore.getBlobs
List
SimpleTransientStore
True. It is a shortcoming of Java that interface contracts don't explicitly state mutability. Lacking that, programmers tend to interpret the contract to be