Comments (6)
Do you mean RequestConditional plugin and a RequestMatcher?
from httplugbundle.
Yes, I've never worked with the RequestConditional plugin. We should add support for that plugin.
from httplugbundle.
Hm, yes, it sounds like a good idea. Although we have a RequestMatcher interface, I guess most of the times we want to use the default implementation, so I suggest the following plugin configuration:
request_condition:
# optional if something from bellow is provided
matcher: matcher.service
# these are optional if the matcher service is provided
# and creates an instance of the default implementation
path: null
host: null
methods: []
schemes: []
I don't recall how we solved multiple instance of the same plugin: by naming or passing an array to the plugin config?
from httplugbundle.
As far as I understand, what is asked for here is ability to configure CachePlugin with RequestMatcher. For this to implement, https://github.com/php-http/cache-plugin should be first changed to support this. I don't see any other use case for this conditional feature. But currently very few things in CachePlugin are configurable via DSL. For example, in my experience respect_response_cache_directives, default_ttl and cache_lifetime have to be changed often and there is no way to change it in config itself.
from httplugbundle.
given the age of this issue, it seems to me like there is not much need for this. not strictly against it, but having too much flexibility also has a cost for the users.
For example, in my experience respect_response_cache_directives, default_ttl and cache_lifetime have to be changed often and there is no way to change it in config itself.
having such things configurable would seem like a good idea to me.
from httplugbundle.
Agreed, let's close then
from httplugbundle.
Related Issues (20)
- Support for multiple mock clients HOT 4
- Client configuration is ignored for async client HOT 1
- Async request not visible in the profiler HOT 1
- Synfony 5 Support HOT 1
- Conflict with twig 3.0 / symfony 4.4 HOT 2
- Auto discovery broken in Symfony 4.4 ? HOT 4
- The httplug.collector.twig.http_message service is deprecated since version 1.17 HOT 5
- Collector not compatible with Symfony\Component\HttpKernel\DataCollector\DataCollectorInterface HOT 9
- Xdebug nested issue HOT 1
- The data collector does not have reset tag HOT 1
- Can't test throwing an exception. Help needed
- 1.22 crash on cache clear in symfony 4.4 HOT 1
- Not allow null value for cache default_ttl HOT 6
- ErrorPlugin cannot be configured HOT 1
- The collector formatter needs to implement Http\Message\Formatter::formatResponseForRequest HOT 1
- [Profiler] No captured body (Symfony Client) HOT 4
- Switch from Http\Client\HttpClient to Psr\Http\Client\ClientInterface HOT 4
- Package php-http/message-factory is abandoned, you should avoid using it. Use psr/http-factory instead HOT 3
- Header authentication service configuration HOT 2
- Support Symfony 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from httplugbundle.