I want ot add few more points
I am using Java native Api for Hbase get/put
and below is the example
assume i have below schema and I am inserting data by using this schema
into Hbase but later I have new new values coming and i need to fit this
into my schema for this I need to create new schema as showing in below
example
in example 2 I have new field time stamp
example 1
{ "type" : "record", "name" : "twitter_schema", "namespace" :
"com.miguno.avro", "fields" : [ { "name" : "username", "type" : "string",
"doc" : "Name of the user account on Twitter.com" }, { "name" : "tweet",
"type" : "string", "doc" : "The content of the user's Twitter message" } ] }
example 2
{ "type" : "record", "name" : "twitter_schema", "namespace" :
"com.miguno.avro", "fields" : [ { "name" : "username", "type" : "string",
"doc" : "Name of the user account on Twitter.com" }, { "name" : "tweet",
"type" : "string", "doc" : "The content of the user's Twitter message" }, {
"name" : "timestamp", "type" : "long", "doc" : "Unix epoch time in seconds"
} ], }
Thanks
Manjeet
On Tue, Aug 30, 2016 at 11:47 AM, Manjeet Singh <[email protected]>
wrote:
> Hi All,
>
> I have use case to put data in avro format in Hbase , I have frequent read
> write operations but its not a problem.
>
> Problem is what if my avro schema get changed how shuld I deal with it?
> This should in mind what about older data which already inserted in Hbase
> and now we have new schema.
>
> can anyone suggest me solution for the same
>
> Thanks
> Manjeet
>
> --
> luv all
>
--
luv all