Benedikt Franke

Results 536 comments of Benedikt Franke

I have come up with an optimization that should be both simple and efficient: Only run certain field middleware once for every usage of the field in the query. That...

I see how an `or` connected `@can` would make sense in your particular use case, but in the general case `and` is what i would expect. Same with `@guard` and...

Combining channels in more flexible ways seems like a great enhancement for the use case you described and others. I am not looking to implement such a feature myself, but...

Everything related to subscriptions is located within https://github.com/nuwave/lighthouse/tree/master/src/Subscriptions At a glance, the `Subscriber` class seems to assume the 1-1 correlation between channels and subscribers: https://github.com/nuwave/lighthouse/blob/3082329767f605f6b9270be8638fdea1ff965664/src/Subscriptions/Subscriber.php#L16-L21 This attribute is accessed in...

Good analysis. I now remember a discussion about this, resulting in the following issue: https://github.com/webonyx/graphql-php/issues/674. If we could use that to determine equivalence of queries, we might optimize that part....

Chunking seems good. That can be a configurable setting. Can you create a PR?

```php protected function channelName(): string { return 'private-lighthouse-room-' . md5(json_encode([(string) $this->query, $this->args])); } ``` That looks like a great start. We can improve upon this in two ways: - use...

I agree with @SirLamer on skipping out on the query/args normalization for now. It is not required for this feature to work, and perhaps not even optimal for performance. As...

I am against introducing such a global setting, let's stick with security by default. One thing we can do to simplify the schema definition is to allow the directive to...

@palypster assuming `Message` and `StockUpdate` or not scalar values, that would not suffice. Let me illustrate the rules I had in mind, given the following schema: ```graphql type Subscription {...