SalesChannelContextService::DOMAIN_ID => true,
SalesChannelContextService::PAYMENT_METHOD_ID => true,
SalesChannelContextService::SHIPPING_METHOD_ID => true,
SalesChannelContextService::VERSION_ID => true,
SalesChannelContextService::COUNTRY_ID => true,
SalesChannelContextService::COUNTRY_STATE_ID => true,
]);
$key =
implode('-',
[$name,
md5(json_encode($keys, \JSON_THROW_ON_ERROR
))]);
$value =
$this->cache->
get($key,
function DItemInterface
$item) use ($name,
$salesChannelId,
$options) { $context =
$this->tracer->
trace($name,
fn () =>
$this->decorated->
create($salesChannelId,
$options));
$keys =
array_unique(array_merge( $this->tracer->
get($name),
[$name, CachedSalesChannelContextFactory::ALL_TAG
] ));
$item->
tag($keys);
return CacheValueCompressor::
compress($context);
});