From bdab9ab2a7fd1811b8815093dd0ea61127276838 Mon Sep 17 00:00:00 2001 From: crusader Date: Tue, 10 Apr 2018 14:24:03 +0900 Subject: [PATCH] ing --- config/external/{external-config.go => external.go} | 9 ++++----- config/external/grpc/grpc-config.go | 6 ------ config/external/grpc/grpc.go | 6 ++++++ config/external/kafka/kafka-config.go | 6 ------ config/external/kafka/kafka.go | 6 ++++++ config/external/redis/redis-config.go | 6 ------ config/external/redis/redis.go | 6 ++++++ 7 files changed, 22 insertions(+), 23 deletions(-) rename config/external/{external-config.go => external.go} (58%) delete mode 100644 config/external/grpc/grpc-config.go create mode 100644 config/external/grpc/grpc.go delete mode 100644 config/external/kafka/kafka-config.go create mode 100644 config/external/kafka/kafka.go delete mode 100644 config/external/redis/redis-config.go create mode 100644 config/external/redis/redis.go diff --git a/config/external/external-config.go b/config/external/external.go similarity index 58% rename from config/external/external-config.go rename to config/external/external.go index aee994f..3221f53 100644 --- a/config/external/external-config.go +++ b/config/external/external.go @@ -6,9 +6,8 @@ import ( "git.loafle.net/overflow/commons-go/config/external/redis" ) -type ExternalConfig struct { - GRPC *grpc.GRPConfig `json:"grpc"` - Kafka *kafka.KafkaConfig `json:"kafka"` - Redis *redis.RedisConfig `json:"redis"` +type External struct { + GRPC *grpc.GRPC `json:"grpc"` + Kafka *kafka.Kafka `json:"kafka"` + Redis *redis.Redis `json:"redis"` } - diff --git a/config/external/grpc/grpc-config.go b/config/external/grpc/grpc-config.go deleted file mode 100644 index f468157..0000000 --- a/config/external/grpc/grpc-config.go +++ /dev/null @@ -1,6 +0,0 @@ -package grpc - - -type GRPConfig struct { - Address string `json:"address"` -} diff --git a/config/external/grpc/grpc.go b/config/external/grpc/grpc.go new file mode 100644 index 0000000..efbfc69 --- /dev/null +++ b/config/external/grpc/grpc.go @@ -0,0 +1,6 @@ +package grpc + +type GRPC struct { + Network string `json:"network"` + Address string `json:"address"` +} diff --git a/config/external/kafka/kafka-config.go b/config/external/kafka/kafka-config.go deleted file mode 100644 index a6700f7..0000000 --- a/config/external/kafka/kafka-config.go +++ /dev/null @@ -1,6 +0,0 @@ -package kafka - - -type KafkaConfig struct { - Address string `json:"address"` -} \ No newline at end of file diff --git a/config/external/kafka/kafka.go b/config/external/kafka/kafka.go new file mode 100644 index 0000000..91587db --- /dev/null +++ b/config/external/kafka/kafka.go @@ -0,0 +1,6 @@ +package kafka + +type Kafka struct { + Network string `json:"network"` + Address string `json:"address"` +} diff --git a/config/external/redis/redis-config.go b/config/external/redis/redis-config.go deleted file mode 100644 index e8c3c92..0000000 --- a/config/external/redis/redis-config.go +++ /dev/null @@ -1,6 +0,0 @@ -package redis - - -type RedisConfig struct { - Address string `json:"address"` -} \ No newline at end of file diff --git a/config/external/redis/redis.go b/config/external/redis/redis.go new file mode 100644 index 0000000..b3105cc --- /dev/null +++ b/config/external/redis/redis.go @@ -0,0 +1,6 @@ +package redis + +type Redis struct { + Network string `json:"network"` + Address string `json:"address"` +}