This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
services: | |
_defaults: | |
autoconfigure: true | |
autowire: true | |
message_bus: | |
class: Symfony\Component\Messenger\MessageBus | |
tags: ['messenger.bus'] | |
arguments: [[]] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace AppBundle\MessageHandlers; | |
use whatever\ImagesBundle\Messages\ImageFilterAppliedMessage; | |
use Predis\Client; | |
use Symfony\Component\Messenger\Handler\MessageHandlerInterface; | |
class ImageFilterAppliedMessageHandler implements MessageHandlerInterface |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace whatever\ImagesBundle\Messages; | |
class ImageFilterAppliedMessage | |
{ | |
protected $redisKey; | |
protected $imagePath; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require('express'); | |
const urlJoin = require('url-join'); | |
const path = require('path'); | |
// you can uncomment those two lines, and create a .env file to store following configs in. | |
//const readConfig = require('@oufok/env-reader').readEnv; | |
//let configDir = path.join(__dirname, './config'); | |
const REDIS_HOST="localhost"; | |
const REDIS_IMAGE_SERVICE_HOST="http://localhost"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Liip\ImagineBundle\Binary\BinaryInterface; | |
use Liip\ImagineBundle\Imagine\Cache\Resolver\ResolverInterface; | |
use Predis\Client; | |
use Symfony\Component\Messenger\MessageBusInterface; | |
class CacheResolver implements ResolverInterface | |
{ | |
protected $redis; |