-
-
Notifications
You must be signed in to change notification settings - Fork 188
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
Allow for decorating the client builder #290
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I cannot honestly review this, it's out of what I know 😅
@stayallive as it has been released, did you plan to mention this in the docs ? |
@smknstd, yes. It’s taking a little time though. I hope for now the description of the PR will do until the docs can be updated, if you need any clarification let me know because that might benefit the documentation changes later on. |
IMO Laravel section in the docs should mention context's additional data. Of course the job belongs more to laravel and PSR3, but I think it's an important feature and I'm pretty sure it could help to mention it explicitly. It could also mention more about it like:
It's really frustrating to discover those behaviors afterward... Maybe a snippet like this could help:
And then
|
I tried this and it "sort of" works, or at least, not in the way I expected it:
I wasn't sure if it's worth opening a dedicated issue, maybe that's simply the way it works but I found nothing in the docs regarding the thanks! |
@stayallive it seems more to me that he changed how the serializer works in the wrong way. @mfn there's a specific |
@stayallive @Jean85 $this->app->extend(ClientBuilderInterface::class, function (ClientBuilderInterface $clientBuilder): ClientBuilderInterface {
$clientBuilder->setSerializer(new Serializer($clientBuilder->getOptions(), 5));
$clientBuilder->setRepresentationSerializer(new RepresentationSerializer($clientBuilder->getOptions(), 5));
return $clientBuilder;
}); |
sorry for the ping @stayallive @Jean85 but can you check my last comment? ☝️ |
@mfn, sorry I missed your response, it looks like you are doing it right but my assumption is that this is a UI "problem" and that the Sentry UI might not allow more nesting to show. Could you share (the relevant section) of the event JSON to make sure it does come across correctly nested? And yeah it's probably a good idea to move this to a new issue so we don't discuss this on a pretty unrelated PR :) |
This allows the user to add this snippet to for example their
AppServiceProvider
sregister
method to set a custom serializer or do other tweaks to theClientBuilderInterface;
implementation or swap it out for their own builder interely.In this example we increase
maxDepth
to 5 in for the default serializer.Resolves #289.