File tree Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Expand file tree Collapse file tree 3 files changed +11
-2
lines changed Original file line number Diff line number Diff line change 6565 CLAMP_DB_CONNECTION_STR : " host=localhost:5432 user=clamptest dbname=clamptest"
6666 CLAMP_KAFKA_CONNECTION_STR : " localhost:9092"
6767 CLAMP_QUEUE_CONNECTION_STR : " amqp://guest:guest@localhost:5672/"
68+ ENABLE_KAFKA_INTEGRATION : true
69+ ENABLE_AMQP_INTEGRATION : true
6870 command : |
6971 if [ $CIRCLE_BRANCH == 'master' ]; then
7072 ./cc-test-reporter before-build
Original file line number Diff line number Diff line change @@ -45,6 +45,9 @@ var ENV = struct {
4545 */
4646 PORT string `env:"APP_PORT" envDefault:"8080"`
4747 AllowOrigins []string `env:"ALLOW_ORIGINS" envDefault:"http://localhost:3000,http://54.149.76.62"`
48+
49+ EnableKafkaIntegration bool `env:"ENABLE_KAFKA_INTEGRATION" envDefault:false`
50+ EnableRabbitMQIntegration bool `env:"ENABLE_AMQP_INTEGRATION" envDefault:false`
4851}{}
4952
5053func init () {
Original file line number Diff line number Diff line change @@ -19,8 +19,12 @@ func main() {
1919 os .Exit (0 )
2020 }
2121
22- listeners .AmqpStepResponseListener .Listen ()
23- listeners .KafkaStepResponseListener .Listen ()
22+ if config .ENV .EnableRabbitMQIntegration {
23+ listeners .AmqpStepResponseListener .Listen ()
24+ }
25+ if config .ENV .EnableKafkaIntegration {
26+ listeners .KafkaStepResponseListener .Listen ()
27+ }
2428 handlers .LoadHTTPRoutes ()
2529 log .Println ("Calling listener" )
2630}
You can’t perform that action at this time.
0 commit comments