List:Internals« Previous MessageNext Message »
From:Sergei Golubchik Date:March 30 2011 6:57am
Subject:Re: storage engine access to serialized version of a TABLE or
TABLE_SHARE?
View as plain text  
Hi, Zardosht!

On Mar 29, Zardosht Kasheff wrote:
> Once again, thank you Dmitry and Sergei for pointing me in the right
> direction.
> 
> I want to make sure that my understanding is correct. Looking at NDB,
> it seems that they use the functions readfrm() and packfrm() to save
> the frm file. readfrm() seems get the contents uncompressed, and
> packfrm() compresses them.
> 
> Suppose I want to just save the raw uncompressed bytes that make up
> the file. I think I can just use the function readfrm() to get the
> data. And, if some crash caused the frm file and my saved version to
> get out of sync, I can just generate a new frm file by saving the data
> that readfrm() retrieved into a new frm file.
> 
> I will give the above a shot.

I don't think that silently overwriting frm file under MySQL feet is a
good idea. Instead, use the discovery mechanism of MySQL. As an example
look at NDB or Archive. It allows the engine to tell the server that a
table has a structure different from what MySQL thinks (after reading
frm), or that a table exists (when frm does not).

Regards,
Sergei
Thread
storage engine access to serialized version of a TABLE or TABLE_SHARE?Zardosht Kasheff29 Mar
  • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Stewart Smith29 Mar
  • Re: storage engine access to serialized version of a TABLE orTABLE_SHARE?Sergei Golubchik29 Mar
    • Re: storage engine access to serialized version of a TABLE orTABLE_SHARE?Dmitry Lenev29 Mar
    • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Stewart Smith30 Mar
Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Zardosht Kasheff29 Mar
  • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Zardosht Kasheff30 Mar
    • Re: storage engine access to serialized version of a TABLE orTABLE_SHARE?Sergei Golubchik30 Mar
    • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Stewart Smith30 Mar
      • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Zardosht Kasheff30 Mar
        • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Zardosht Kasheff30 Mar
          • Re: storage engine access to serialized version of a TABLE orTABLE_SHARE?Dmitry Lenev30 Mar
            • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Zardosht Kasheff6 Apr
              • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Jonas Oreland6 Apr
                • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Stewart Smith7 Apr
                  • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Zardosht Kasheff7 Apr
                    • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Stewart Smith8 Apr
  • Re: storage engine access to serialized version of a TABLE or TABLE_SHARE?Stewart Smith30 Mar