VOL-1025: Implement a Go language library for affinity proxy request/response handling
- Did a bit of cleanup on the docker-compose environment for rw-core.
To run the compose files, set DOCKER_HOST_IP to your MAC's IP
Change-Id: Iefb99c99d082c2566f3854a27630941e927be0b6
diff --git a/compose/adapters-ponsim.yml b/compose/adapters-ponsim.yml
index dacf83c..145d99b 100644
--- a/compose/adapters-ponsim.yml
+++ b/compose/adapters-ponsim.yml
@@ -26,8 +26,8 @@
"/adapters/adapters/ponsim_olt/main.py",
"-v",
"--name=ponsim_olt",
- "--kafka_adapter=10.176.230.190:9092",
- "--kafka_cluster=10.176.230.190:9092",
+ "--kafka_adapter=${DOCKER_HOST_IP}:9092",
+ "--kafka_cluster=${DOCKER_HOST_IP}:9092",
"--core_topic=rwcore"
]
networks:
@@ -44,8 +44,8 @@
"/adapters/adapters/ponsim_onu/main.py",
"-v",
"--name=ponsim_onu",
- "--kafka_adapter=10.176.230.190:9092",
- "--kafka_cluster=10.176.230.190:9092",
+ "--kafka_adapter=${DOCKER_HOST_IP}:9092",
+ "--kafka_cluster=${DOCKER_HOST_IP}:9092",
"--core_topic=rwcore"
]
networks:
diff --git a/compose/docker-compose-zk-kafka-test.yml b/compose/docker-compose-zk-kafka-test.yml
index 44aa7c2..e339aa4 100644
--- a/compose/docker-compose-zk-kafka-test.yml
+++ b/compose/docker-compose-zk-kafka-test.yml
@@ -33,7 +33,7 @@
- 9092:9092
environment:
# KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://10.100.198.220:9092
- KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://10.176.230.190:9092
+ KAFKA_ADVERTISED_LISTENERS: PLAINTEXT://${DOCKER_HOST_IP}:9092
KAFKA_LISTENERS: PLAINTEXT://:9092
# KAFKA_ADVERTISED_HOST_NAME: 10.100.198.220
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
diff --git a/compose/rw_core.yml b/compose/rw_core.yml
index 3759e96..c5d39ce 100644
--- a/compose/rw_core.yml
+++ b/compose/rw_core.yml
@@ -25,9 +25,9 @@
- -grpc_host=${DOCKER_HOST_IP}
- -grpc_port=50057
- -banner=true
- - -kafka_adapter_host=10.176.230.190
+ - -kafka_adapter_host=${DOCKER_HOST_IP}
- -kafka_adapter_port=9092
- - -kafka_cluster_host=10.176.230.190
+ - -kafka_cluster_host=${DOCKER_HOST_IP}
- -kafka_cluster_port=9092
- -rw_core_topic=rwcore
- -log_level=0
diff --git a/protos/scripts/build_protos.sh b/protos/scripts/build_protos.sh
old mode 100644
new mode 100755
diff --git a/rw_core/config/config.go b/rw_core/config/config.go
index feb9879..c363d49 100644
--- a/rw_core/config/config.go
+++ b/rw_core/config/config.go
@@ -29,13 +29,13 @@
default_InstanceID = "rwcore001"
default_GrpcPort = 50057
default_GrpcHost = "127.0.0.1"
- default_KafkaAdapterHost = "10.176.230.190"
+ default_KafkaAdapterHost = "127.0.0.1"
default_KafkaAdapterPort = 9092
- default_KafkaClusterHost = "10.176.215.107"
+ default_KafkaClusterHost = "127.0.0.1"
default_KafkaClusterPort = 9094
default_KVStoreType = EtcdStoreName
default_KVStoreTimeout = 5 //in seconds
- default_KVStoreHost = "10.176.230.190"
+ default_KVStoreHost = "127.0.0.1"
default_KVStorePort = 2379 // Consul = 8500; Etcd = 2379
default_KVTxnKeyDelTime = 60
default_LogLevel = 0