Aman
Aman

Reputation: 3261

Storing and reading images from hbase

I want to store images in my hbase table.And I want to read the image file from hbase table as a image.Is it possible to do it in hbase.
Image size may not exceed 10MB.For each row there should be an image associated with it.Wondering how to do it.Need some clue hot to proceed.

Upvotes: 0

Views: 4680

Answers (1)

Anil Gupta
Anil Gupta

Reputation: 1126

Yes, it is possible to store image in HBase and Read images directly from HBase table.
Store byte[] of an image in one column. You will be able to retrieve the image. Also, you can use http://hbase.apache.org/book.html#_rest to retrieve the image. Just use this request header: "

Accept: application/octet-stream

"
We at Truecar.com are using HBase to store millions of Images. Recently, we presented our use case at Hadoop Summit 2015. Soon, we will share slides and more details in a blogpost.

Also have a look at this enhancement HBase jira for storing images: https://issues.apache.org/jira/browse/HBASE-11339

Here is an old presentation for storing image yfrom.com : http://www.slideshare.net/jacque74/hug-hbase-presentation

Upvotes: 3

Related Questions