Re: [RADIATOR] Using Storable in a hook

2012-01-26 Thread Alexander Hartmaier
Is it really binary data that your want to store? I suggest you serialize to a variable and log it before guessing what's happening. Also enable DBI trace mode to see what queries get executed: https://metacpan.org/module/DBI#TRACING Best regards, Alex Am 2012-01-25 18:15, schrieb Jared Watkins:

Re: [RADIATOR] Using Storable in a hook

2012-01-25 Thread Jared Watkins
I've tried storing the data a few different ways.. and I always end up with the same 3 byte value stored in the database... which sounds like a memory pointer rather than data. I found a specific reference under DBD:Pg about binary data.. and it suggests that you have to do an explicit bind an

Re: [RADIATOR] Using Storable in a hook

2012-01-25 Thread Heikki Vatiainen
On 01/25/2012 05:44 AM, Jared Watkins wrote: > I figured out that I have to call it directly like Storable::nfreeze(\%x) but > the error I was getting for other way was: > > Bizarre copy of HASH in refgen at > > Now.. I'm passing the value in as a bound parameter in the hook and according > to

Re: [RADIATOR] Using Storable in a hook

2012-01-25 Thread Jared Watkins
The attribute list portion that I want to store is an array. I want to store it for development and debugging reasons since I'll be receiving records from several different kinds of sources and I'm trying to develop logic to clean up and normalize the bits I care about. The alternative.. is to m

Re: [RADIATOR] Using Storable in a hook

2012-01-25 Thread Alexander Hartmaier
Serializing Objects, references and regexes is no easy task. What are you trying to achieve? I suggest you switch to a different format like JSON and only serialize a data structure you created from the request attributes by yourself. The internal representation of a packet could change with every

Re: [RADIATOR] Using Storable in a hook

2012-01-24 Thread Jared Watkins
I figured out that I have to call it directly like Storable::nfreeze(\%x) but the error I was getting for other way was: Bizarre copy of HASH in refgen at Now.. I'm passing the value in as a bound parameter in the hook and according to a length call on the variable.. it's going in with an avera

Re: [RADIATOR] Using Storable in a hook

2012-01-24 Thread Heikki Vatiainen
On 01/24/2012 10:44 PM, Jared Watkins wrote: > I'm seeing some weird errors and behavior trying to use the freeze method > from Storable. Is there a special trick to making it work in hook code? I have not used Storable myself, but if you could reply with some examples I can take a a look. No