jackrabbit-oak-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Dürig <mdue...@apache.org>
Subject Re: ContentSession#createBlob ?
Date Fri, 19 Oct 2012 09:43:12 GMT


On 19.10.12 10:36, Angela Schreiber wrote:
> hi michael
>
> thanks for the info
>
>> Note that createBlobd() is very much the same as the
>> getCoreValueFactory() method, which it replaced.
>
> yes, i am aware of this... the reason why i don't like
> the method on contentsession has nothing to do with the
> 'what-it-does' but rather the fact i IMO it wasn't
> the responsibility of a contentsession to deal with binary
> values when at the other hand we have all value handling
> separated out to a ValueFactory(Impl).

Yes, but this is oak-jcr, not oak-core. If we forfeit the capability for 
creating "immediately streamed" blobs on the oak-core level, we can 
remove that method from the API.

Michael.

>
> kind regards
> angela
>
>> Michael
>>
>>
>> On 19.10.12 8:54, Angela Schreiber wrote:
>>> hi all
>>>
>>> recent the ContentSession interface got a new method
>>>
>>>    Blob createBlob(InputStream inputStream) throws IOException;
>>>
>>> this there is no TODO comment associated with it i assume
>>> that is intended to stay... however, it feels a bit odd to
>>> me having that method on the content session interface and
>>> i don't see how and why a regular API consumer of the
>>> ContentSession would need/use this.
>>>
>>> currently the only usage of the method is in a private
>>> method on ValueFactoryImpl, which for that very purpose
>>> needs to have the content session passed to the constructor
>>> but doesn't otherwise need access to the content session
>>> at all...
>>>
>>> imo that should be reviewed again.
>>>
>>> kind regards
>>> angela
>>>
>>>
>>>

Mime
View raw message