Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^3: Storable: Byte order is not compatible

by Aristotle (Chancellor)
on Apr 26, 2012 at 14:02 UTC ( #967358=note: print w/replies, xml ) Need Help??


in reply to Re^2: Storable: Byte order is not compatible
in thread Storable: Byte order is not compatible

in our database, we have some frozen Perl hashes that were created with [] Storable

That right there is your problem. Storable makes no promises about binary compatibility across different releases or different perls. You do not want to use it as a serialisation mechanism. It is not a good idea for anything except intra- or interprocess communication between forks of the same process.

Most likely you want JSON. That will also decouple your data from perl. JSON::XS even happens to be faster than Storable, and by no small margin (which is where the simplicity of the JSON data model pays off).

Makeshifts last the longest.

  • Comment on Re^3: Storable: Byte order is not compatible

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://967358]
help
Chatterbox?
[choroba]: I don't even remember the beginning
[choroba]: someone told me to use perl instead of sed for something, and several years later, I'm developing a huge Tk application
[Discipulus]: choroba started in primary school to get some advantage in the future..
[choroba]: nono, I programmed in Basic at the primary school, on my Commodore 116/16
[Discipulus]: ;=)
[choroba]: then learned some assebly on the same machine, then moved to my father's PC (XT with a Hercules card), used Turbo Pascal a lot
[choroba]: I started with *nix at the University, we had some Sparcs and Linux machines
[choroba]: that was around 1994 or 95
hippo actually introduced Linux to his university.
Discipulus mmh will be a fun meditation: How I started with computers and programming..

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (11)
As of 2018-06-22 09:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?



    Results (123 votes). Check out past polls.

    Notices?