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

Profiler log output should use strict JSON representation for BSON types #178

Open
jmikola opened this issue Mar 18, 2013 · 5 comments
Open
Labels
Projects

Comments

@jmikola
Copy link
Member

jmikola commented Mar 18, 2013

From comment in #177:

I suppose the most preferable option would be to serialize the driver classes in the "strict JSON" format defined in: http://docs.mongodb.org/manual/reference/mongodb-extended-json/#data_binary (the mongoexport commands use that notation).

@jmikola jmikola modified the milestones: 3.0.0, 3.0.0-BETA5 May 19, 2014
@malarzm malarzm modified the milestones: 3.0.0, 3.1 May 22, 2015
@malarzm malarzm added the Task label Jan 19, 2016
@malarzm malarzm modified the milestones: 3.2, 3.1 Apr 10, 2016
@malarzm malarzm removed this from the 3.2 milestone Jun 30, 2016
@stale
Copy link

stale bot commented Jan 21, 2019

This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in a week if no further activity occurs. Thank you for your contributions.

@stale stale bot added the Stale Issues that have not seen any activity in 30 days label Jan 21, 2019
@stale stale bot closed this as completed Jan 28, 2019
@jmikola jmikola reopened this Feb 5, 2019
@jmikola
Copy link
Member Author

jmikola commented Feb 5, 2019

@malarzm: It's been a while since I worked with the bundle, but are CommandDataCollector.php and PSRCommandLogger.php the only classes relevant to data collection and logging? The original classes mentioned in #177 no longer exist.

It looks like the current classes are using json_encode(), which addresses the original concern in #177 since binary data is displayed as base64-encoded. That said, the driver's JsonSerializable implementations on BSON types yields a legacy extended JSON format (vs. the formats outlined in the Extended JSON spec). If you think it's worth fixing that, I can submit a quick patch that round-trips the command documents through fromPHP() and toRelaxedExtendedJSON().

If not, feel free to close this as-is.

@malarzm
Copy link
Member

malarzm commented Feb 6, 2019

@jmikola looking at Conversion table the relaxed format looks nice and if it's not a big hassle I'd say it's nice to have :)

@stale stale bot removed the Stale Issues that have not seen any activity in 30 days label Feb 6, 2019
@alcaeus
Copy link
Member

alcaeus commented Feb 7, 2019

Let's try to get this done for 4.0 :)

@alcaeus alcaeus added this to 4.0 in Roadmap Feb 7, 2019
@IonBazan
Copy link
Member

@alcaeus isn't it fixed in #652?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Roadmap
4.0 (unsupported)
Development

No branches or pull requests

4 participants