title: How to inject a specific cache pool?
body: <p>In my Symfony 5 application I want to use different caches for different tasks and of course for different environments.</p>
  <p>e.g. my configuration looks like this:</p>
  <pre><code>framework:
      cache:
          pools:
              cache.auth:
                  adapter: cache.adapter.redis
                  provider: app.my_custom_redis_provider
              cache.sap:
                  adapter: cache.adapter.redis
                  provider: app.my_custom_redis_provider
  services:
      app.my_custom_redis_provider:
          arguments:
              - '%env(REDIS_URL)%'
              -
                  retry_interval: 2
                  timeout: '%env(REDIS_TIMEOUT)%'
          class: Redis
          factory:
              - Symfony\Component\Cache\Adapter\RedisAdapter
              - createConnection
  </code></pre>
  <p>I use dependency injection with my classes. So how would I define which of those two cache pools is used by a specific class?</p>
  <p>At the moment I get my cache like this:</p>
  <pre><code>class SapListService implements ListServiceInterface
  {
      use LoggerTrait;
  
      private CountryServiceInterface $countryService;
      private CurrencyServiceInterface $currencyService;
  
      public function __construct(
          SapClientFactoryInterface $sapClient,
          CacheItemPoolInterface $cache,
          ParameterBagInterface $params
      ) {
          $sapUser = $params-&gt;get('sap_user');
          $sapPw = $params-&gt;get('sap_pw');
          $urlStruktur = $params-&gt;get('sap_struktur');
          $this-&gt;countryService = $sapClient-&gt;getCountryService($sapUser, $sapPw, $urlStruktur, $cache);
          $this-&gt;currencyService = $sapClient-&gt;getCurrencyService($sapUser, $sapPw, $urlStruktur, $cache);
      } 
  </code></pre>
  <p>How do I configure my <code>SapListService</code> to use the cache.sap pool?</p>