mime type detection

2015-04-30 Thread Satya Deep Maheshwari
Hi I am facing a problem with the mime type detection of a file. While debugging, I see that SlingTikaDetector.detect method is used for detecting the mime type of my file. See [1]. This method just seems to rely on the name of the file for detecting its mime type. Even though its passed an

Re: mime type detection

2015-05-04 Thread Robert Munteanu
Hi, On Fri, May 1, 2015 at 8:22 AM, Satya Deep Maheshwari wrote: > Hi > > I am facing a problem with the mime type detection of a file. While > debugging, I see that SlingTikaDetector.detect method is used for detecting > the mime type of my file. See [1]. This method just seems

Re: mime type detection

2015-05-04 Thread Satya Deep Maheshwari
Thanks Robert for providing information on this. How about modifying the existing SlingTikaDetector itself and adding a mechanism in it to resort to inputstream based mime-type detection if name based detection draws a null. inputstream based mime-type detection would only come into play when

Re: mime type detection

2015-05-04 Thread Bertrand Delacretaz
Hi, On Mon, May 4, 2015 at 1:36 PM, Satya Deep Maheshwari wrote: > ...How about modifying the > existing SlingTikaDetector itself and adding a mechanism in it to resort to > inputstream based mime-type detection if name based detection draws a > null I don't think we want

Re: mime type detection

2015-05-06 Thread Satya Deep Maheshwari
> inputstream based mime-type detection if name based detection draws a > > null > > I don't think we want to make this the default, as that's much more > expensive than the other methods. > > As Robert says, providing an extension point for content-based mime > type detection is good. > > -Bertrand >