Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to access compressed value object as buffer in node? #12360

Closed
samzoll22 opened this issue Dec 15, 2017 · 1 comment
Closed

How to access compressed value object as buffer in node? #12360

samzoll22 opened this issue Dec 15, 2017 · 1 comment
Labels
answered For when a question was asked and we referred to forum or answered it.

Comments

@samzoll22
Copy link

using Piwik for site analytics and have our database on AWS RDS Aurora mysql. For testing, I'm running a local Node/Express server, connected to the Piwik AWS mysql db.

How do I transform the piwik_archive_blob value which we receive as a buffer into a readable JSON object/array?

this is what we have value: <Buffer 78 9c a5 ce 51 0a 83 30 0c 06 e0 bb f4 04 a9 a9 8b 4d ef b0 3b c4 ad 30 41 1c 68 df c4 bb 2f 51 ea 9e 06 63 7b 68 f8 43 93 f0 09 23 af 03 fb b4 b0 0f ... >

We know the value column stores serialized and gzcompressed DataTable objects

We have tried everything from .toString('utf8'), .toString('binary'), JSON.stringify(), to using Gzip and zlib.

The only output we can get is null, x, and [object Object],[object Object],[object Object]....

Any ideas would be appreciated, Thanks.

@mattab
Copy link
Member

mattab commented Dec 15, 2017

Hi there,

Sorry but this is not a bug nor a feature request. Maybe ask your question in the forum instead: http://forum.piwik.org/

Or get professional paid support here: http://piwik.org/support/

@mattab mattab closed this as completed Dec 15, 2017
@mattab mattab added the answered For when a question was asked and we referred to forum or answered it. label Dec 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it.
Projects
None yet
Development

No branches or pull requests

2 participants