Hi, +1 from my side for the broad contours as proposed above.
Thanks Amit On Thu, Aug 24, 2017 at 10:58 AM, Chetan Mehrotra <chetan.mehro...@gmail.com > wrote: > Based on the feedback so far below is revised proposal > > 1. Define a new Adaptable interface in 'org.apache.jackrabbit.oak.api' > > public interface Adaptable { > > /** > * Adapts the binary to another type > * > * @param <AdapterType> The generic type to which this type is adapted > * to > * @param type The Class object of the target type > * @return The adapter target or <code>null</code> if the type cannot > * adapt to the requested type > */ > <AdapterType> AdapterType adaptTo(Class<AdapterType> type); > } > > 2. Have the binary implementation in Oak implement Adaptable > 3. Have a minimal implementation in Oak on line of Sling Adaptor support > [1] > > For current usecase we would provide an adaptation to SignedBinary > > public interface SignedBinary { > > URI getUri() > } > > Chetan Mehrotra > > [1] https://github.com/apache/sling/tree/trunk/bundles/api/ > src/main/java/org/apache/sling/api/adapter > > > On Wed, Aug 23, 2017 at 10:04 PM, Chetan Mehrotra > <chetan.mehro...@gmail.com> wrote: > >> Hence, why not simply use binaryProp instanceof SignedBinary ? > > > > As Julian mentioned it would make it tricky to support multiple > > extensions with various permutations. Having adapter support for > > simplify the implementation > > > >> No client should be issued a signed url that could be used in the > distant > >> (relatively) future bypassing fresh ACL constraints saved to Oak. > > > > Fair point. Then lets drop the ttl paramater > > > > Chetan Mehrotra >