Skip to content

Commit

Permalink
[patch] divide gateway
Browse files Browse the repository at this point in the history
Signed-off-by: kpango <i.can.feel.gravity@gmail.com>
  • Loading branch information
kpango committed May 31, 2020
1 parent fa241f1 commit 2dd0c27
Show file tree
Hide file tree
Showing 195 changed files with 52,062 additions and 188 deletions.
16 changes: 10 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,20 @@ GOPKG = github.com/$(REPO)/$(NAME)
TAG = $(eval TAG := $(shell date -u +%Y%m%d-%H%M%S))$(TAG)
BASE_IMAGE = $(NAME)-base
AGENT_IMAGE = $(NAME)-agent-ngt
GATEWAY_IMAGE = $(NAME)-gateway
BACKUP_GATEWAY_IMAGE = $(NAME)-backup-gateway
CI_CONTAINER_IMAGE = $(NAME)-ci-container
DISCOVERER_IMAGE = $(NAME)-discoverer-k8s
META_REDIS_IMAGE = $(NAME)-meta-redis
META_CASSANDRA_IMAGE = $(NAME)-meta-cassandra
MANAGER_BACKUP_MYSQL_IMAGE = $(NAME)-manager-backup-mysql
FILTER_GATEWAY_IMAGE = $(NAME)-filter-gateway
GATEWAY_IMAGE = $(NAME)-gateway
HELM_OPERATOR_IMAGE = $(NAME)-helm-operator
LB_GATEWAY_IMAGE = $(NAME)-lb-gateway
MANAGER_BACKUP_CASSANDRA_IMAGE = $(NAME)-manager-backup-cassandra
MANAGER_BACKUP_MYSQL_IMAGE = $(NAME)-manager-backup-mysql
MANAGER_COMPRESSOR_IMAGE = $(NAME)-manager-compressor
MANAGER_INDEX_IMAGE = $(NAME)-manager-index
CI_CONTAINER_IMAGE = $(NAME)-ci-container
HELM_OPERATOR_IMAGE = $(NAME)-helm-operator
META_CASSANDRA_IMAGE = $(NAME)-meta-cassandra
META_GATEWAY_IMAGE = $(NAME)-meta-gateway
META_REDIS_IMAGE = $(NAME)-meta-redis

NGT_VERSION := $(eval NGT_VERSION := $(shell cat versions/NGT_VERSION))$(NGT_VERSION)
NGT_REPO = github.com/yahoojapan/NGT
Expand Down
36 changes: 36 additions & 0 deletions Makefile.d/docker.mk
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,42 @@ docker/name/gateway-vald:
docker/build/gateway-vald: docker/build/base
docker build -f dockers/gateway/vald/Dockerfile -t $(REPO)/$(GATEWAY_IMAGE) .

.PHONY: docker/name/gateway-meta
docker/name/gateway-meta:
@echo "$(REPO)/$(META_GATEWAY_IMAGE)"

.PHONY: docker/build/gateway-meta
## build gateway-meta image
docker/build/gateway-meta: docker/build/base
docker build -f dockers/gateway/vald/Dockerfile -t $(REPO)/$(META_GATEWAY_IMAGE) .

.PHONY: docker/name/gateway-backup
docker/name/gateway-backup:
@echo "$(REPO)/$(BACKUP_GATEWAY_IMAGE)"

.PHONY: docker/build/gateway-backup
## build gateway-backup image
docker/build/gateway-backup: docker/build/base
docker build -f dockers/gateway/vald/Dockerfile -t $(REPO)/$(BACKUP_GATEWAY_IMAGE) .

.PHONY: docker/name/gateway-filter
docker/name/gateway-filter:
@echo "$(REPO)/$(FILTER_GATEWAY_IMAGE)"

.PHONY: docker/build/gateway-filter
## build gateway-filter image
docker/build/gateway-filter: docker/build/base
docker build -f dockers/gateway/vald/Dockerfile -t $(REPO)/$(FILTER_GATEWAY_IMAGE) .

.PHONY: docker/name/gateway-lb
docker/name/gateway-lb:
@echo "$(REPO)/$(LB_GATEWAY_IMAGE)"

.PHONY: docker/build/gateway-lb
## build gateway-lb image
docker/build/gateway-lb: docker/build/base
docker build -f dockers/gateway/vald/Dockerfile -t $(REPO)/$(LB_GATEWAY_IMAGE) .

.PHONY: docker/name/meta-redis
docker/name/meta-redis:
@echo "$(REPO)/$(META_REDIS_IMAGE)"
Expand Down
4 changes: 4 additions & 0 deletions apis/docs/filter/ingress/docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@

| Method Name | Request Type | Response Type | Description |
| ----------- | ------------ | ------------- | ------------|
| GenVector | [.payload.Object.Blob](#payload.Object.Blob) | [.payload.Object.Vector](#payload.Object.Vector) | |
| StreamGenVector | [.payload.Object.Blob](#payload.Object.Blob) stream | [.payload.Object.Vector](#payload.Object.Vector) stream | |
| FilterVector | [.payload.Object.Vector](#payload.Object.Vector) | [.payload.Object.Vector](#payload.Object.Vector) | |
| StreamFilterVector | [.payload.Object.Vector](#payload.Object.Vector) stream | [.payload.Object.Vector](#payload.Object.Vector) stream | |



Expand Down
68 changes: 68 additions & 0 deletions apis/docs/gateway/filter/docs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# Protocol Documentation
<a name="top"></a>

## Table of Contents

- [filter/filter.proto](#filter/filter.proto)
- [Filter](#filter.Filter)

- [Scalar Value Types](#scalar-value-types)



<a name="filter/filter.proto"></a>
<p align="right"><a href="#top">Top</a></p>

## filter/filter.proto









<a name="filter.Filter"></a>

### Filter


| Method Name | Request Type | Response Type | Description |
| ----------- | ------------ | ------------- | ------------|
| SearchObject | [.payload.Search.ObjectRequest](#payload.Search.ObjectRequest) | [.payload.Search.Response](#payload.Search.Response) | |
| StreamSearch | [.payload.Search.ObjectRequest](#payload.Search.ObjectRequest) stream | [.payload.Search.Response](#payload.Search.Response) stream | |
| InsertObject | [.payload.Object.Blob](#payload.Object.Blob) | [.payload.Empty](#payload.Empty) | |
| StreamInsertObject | [.payload.Object.Blob](#payload.Object.Blob) stream | [.payload.Empty](#payload.Empty) stream | |
| MultiInsertObject | [.payload.Object.Blob](#payload.Object.Blob) | [.payload.Empty](#payload.Empty) | |
| UpdateObject | [.payload.Object.Blob](#payload.Object.Blob) | [.payload.Empty](#payload.Empty) | |
| StreamUpdateObject | [.payload.Object.Blob](#payload.Object.Blob) stream | [.payload.Empty](#payload.Empty) stream | |
| MultiUpdateObject | [.payload.Object.Blob](#payload.Object.Blob) | [.payload.Empty](#payload.Empty) | |
| UpsertObject | [.payload.Object.Blob](#payload.Object.Blob) | [.payload.Empty](#payload.Empty) | |
| StreamUpsertObject | [.payload.Object.Blob](#payload.Object.Blob) stream | [.payload.Empty](#payload.Empty) stream | |
| MultiUpsertObject | [.payload.Object.Blob](#payload.Object.Blob) | [.payload.Empty](#payload.Empty) | |





## Scalar Value Types

| .proto Type | Notes | C++ | Java | Python | Go | C# | PHP | Ruby |
| ----------- | ----- | --- | ---- | ------ | -- | -- | --- | ---- |
| <a name="double" /> double | | double | double | float | float64 | double | float | Float |
| <a name="float" /> float | | float | float | float | float32 | float | float | Float |
| <a name="int32" /> int32 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) |
| <a name="int64" /> int64 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. | int64 | long | int/long | int64 | long | integer/string | Bignum |
| <a name="uint32" /> uint32 | Uses variable-length encoding. | uint32 | int | int/long | uint32 | uint | integer | Bignum or Fixnum (as required) |
| <a name="uint64" /> uint64 | Uses variable-length encoding. | uint64 | long | int/long | uint64 | ulong | integer/string | Bignum or Fixnum (as required) |
| <a name="sint32" /> sint32 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) |
| <a name="sint64" /> sint64 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. | int64 | long | int/long | int64 | long | integer/string | Bignum |
| <a name="fixed32" /> fixed32 | Always four bytes. More efficient than uint32 if values are often greater than 2^28. | uint32 | int | int | uint32 | uint | integer | Bignum or Fixnum (as required) |
| <a name="fixed64" /> fixed64 | Always eight bytes. More efficient than uint64 if values are often greater than 2^56. | uint64 | long | int/long | uint64 | ulong | integer/string | Bignum |
| <a name="sfixed32" /> sfixed32 | Always four bytes. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) |
| <a name="sfixed64" /> sfixed64 | Always eight bytes. | int64 | long | int/long | int64 | long | integer/string | Bignum |
| <a name="bool" /> bool | | bool | boolean | boolean | bool | bool | boolean | TrueClass/FalseClass |
| <a name="string" /> string | A string must always contain UTF-8 encoded or 7-bit ASCII text. | string | String | str/unicode | string | string | string | String (UTF-8) |
| <a name="bytes" /> bytes | May contain any arbitrary sequence of bytes. | string | ByteString | str | []byte | ByteString | string | String (ASCII-8BIT) |

34 changes: 34 additions & 0 deletions apis/docs/payload/docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
- [Meta.Val](#payload.Meta.Val)
- [Meta.Vals](#payload.Meta.Vals)
- [Object](#payload.Object)
- [Object.Blob](#payload.Object.Blob)
- [Object.Distance](#payload.Object.Distance)
- [Object.ID](#payload.Object.ID)
- [Object.IDs](#payload.Object.IDs)
Expand All @@ -61,6 +62,7 @@
- [Search](#payload.Search)
- [Search.Config](#payload.Search.Config)
- [Search.IDRequest](#payload.Search.IDRequest)
- [Search.ObjectRequest](#payload.Search.ObjectRequest)
- [Search.Request](#payload.Search.Request)
- [Search.Response](#payload.Search.Response)

Expand Down Expand Up @@ -697,6 +699,22 @@



<a name="payload.Object.Blob"></a>

### Object.Blob



| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| id | [string](#string) | | |
| object | [bytes](#bytes) | | |






<a name="payload.Object.Distance"></a>

### Object.Distance
Expand Down Expand Up @@ -876,6 +894,22 @@



<a name="payload.Search.ObjectRequest"></a>

### Search.ObjectRequest



| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| object | [bytes](#bytes) | | |
| config | [Search.Config](#payload.Search.Config) | | |






<a name="payload.Search.Request"></a>

### Search.Request
Expand Down
Loading

0 comments on commit 2dd0c27

Please sign in to comment.