Skip to content
Snippets Groups Projects
Commit 0b35b4c8 authored by George Falileev's avatar George Falileev
Browse files

Merge branch 'HF-infoice-product' into 'master'

HF: Type_INVOICE_PRODUCT export

See merge request mashplace/backend/statistics!19
parents 99247c7c cc40316d
Branches master
No related tags found
No related merge requests found
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.28.1
// protoc v3.21.7
// protoc v3.21.12
// source: statistics.proto
package statistics
......@@ -39,6 +39,7 @@ const (
Type_INVOICE_SERVICE Type = 12
Type_INVOICE_PAYMENT Type = 13
Type_DOCUMENT Type = 14
Type_INVOICE_PRODUCT Type = 15
)
// Enum value maps for Type.
......@@ -59,6 +60,7 @@ var (
12: "INVOICE_SERVICE",
13: "INVOICE_PAYMENT",
14: "DOCUMENT",
15: "INVOICE_PRODUCT",
}
Type_value = map[string]int32{
"ACCOUNT": 0,
......@@ -76,6 +78,7 @@ var (
"INVOICE_SERVICE": 12,
"INVOICE_PAYMENT": 13,
"DOCUMENT": 14,
"INVOICE_PRODUCT": 15,
}
)
......@@ -212,7 +215,7 @@ var file_statistics_proto_rawDesc = []byte{
0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x2a, 0x0a, 0x0e, 0x55, 0x70, 0x6c, 0x6f, 0x61,
0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75, 0x63,
0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63, 0x63,
0x65, 0x73, 0x73, 0x2a, 0x85, 0x02, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07,
0x65, 0x73, 0x73, 0x2a, 0x9a, 0x02, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x0b, 0x0a, 0x07,
0x41, 0x43, 0x43, 0x4f, 0x55, 0x4e, 0x54, 0x10, 0x00, 0x12, 0x09, 0x0a, 0x05, 0x4f, 0x46, 0x46,
0x45, 0x52, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x50, 0x52, 0x4f, 0x50, 0x45, 0x52, 0x54, 0x59,
0x10, 0x02, 0x12, 0x0b, 0x0a, 0x07, 0x50, 0x41, 0x59, 0x4d, 0x45, 0x4e, 0x54, 0x10, 0x03, 0x12,
......@@ -228,18 +231,20 @@ var file_statistics_proto_rawDesc = []byte{
0x53, 0x10, 0x0b, 0x12, 0x13, 0x0a, 0x0f, 0x49, 0x4e, 0x56, 0x4f, 0x49, 0x43, 0x45, 0x5f, 0x53,
0x45, 0x52, 0x56, 0x49, 0x43, 0x45, 0x10, 0x0c, 0x12, 0x13, 0x0a, 0x0f, 0x49, 0x4e, 0x56, 0x4f,
0x49, 0x43, 0x45, 0x5f, 0x50, 0x41, 0x59, 0x4d, 0x45, 0x4e, 0x54, 0x10, 0x0d, 0x12, 0x0c, 0x0a,
0x08, 0x44, 0x4f, 0x43, 0x55, 0x4d, 0x45, 0x4e, 0x54, 0x10, 0x0e, 0x32, 0x66, 0x0a, 0x11, 0x53,
0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65,
0x12, 0x51, 0x0a, 0x06, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x22, 0x2e, 0x6d, 0x61, 0x73,
0x68, 0x72, 0x6f, 0x6f, 0x6d, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73,
0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23,
0x2e, 0x6d, 0x61, 0x73, 0x68, 0x72, 0x6f, 0x6f, 0x6d, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73,
0x74, 0x69, 0x63, 0x73, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f,
0x6e, 0x73, 0x65, 0x42, 0x40, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x6c, 0x61, 0x62, 0x2e, 0x6d, 0x61,
0x73, 0x68, 0x72, 0x6f, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6d, 0x61, 0x73, 0x68, 0x72,
0x6f, 0x6f, 0x6d, 0x2f, 0x62, 0x61, 0x63, 0x6b, 0x65, 0x6e, 0x64, 0x2f, 0x73, 0x74, 0x61, 0x74,
0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x2f, 0x61, 0x70, 0x69, 0x3b, 0x73, 0x74, 0x61, 0x74, 0x69,
0x73, 0x74, 0x69, 0x63, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x08, 0x44, 0x4f, 0x43, 0x55, 0x4d, 0x45, 0x4e, 0x54, 0x10, 0x0e, 0x12, 0x13, 0x0a, 0x0f, 0x49,
0x4e, 0x56, 0x4f, 0x49, 0x43, 0x45, 0x5f, 0x50, 0x52, 0x4f, 0x44, 0x55, 0x43, 0x54, 0x10, 0x0f,
0x32, 0x66, 0x0a, 0x11, 0x53, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x53, 0x65,
0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x51, 0x0a, 0x06, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x12,
0x22, 0x2e, 0x6d, 0x61, 0x73, 0x68, 0x72, 0x6f, 0x6f, 0x6d, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x69,
0x73, 0x74, 0x69, 0x63, 0x73, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x52, 0x65, 0x71, 0x75,
0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x6d, 0x61, 0x73, 0x68, 0x72, 0x6f, 0x6f, 0x6d, 0x2e, 0x73,
0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x2e, 0x55, 0x70, 0x6c, 0x6f, 0x61, 0x64,
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x42, 0x5a, 0x40, 0x67, 0x69, 0x74, 0x6c,
0x61, 0x62, 0x2e, 0x6d, 0x61, 0x73, 0x68, 0x70, 0x6c, 0x61, 0x63, 0x65, 0x2e, 0x63, 0x6f, 0x6d,
0x2f, 0x6d, 0x61, 0x73, 0x68, 0x70, 0x6c, 0x61, 0x63, 0x65, 0x2f, 0x62, 0x61, 0x63, 0x6b, 0x65,
0x6e, 0x64, 0x2f, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x2f, 0x61, 0x70,
0x69, 0x3b, 0x73, 0x74, 0x61, 0x74, 0x69, 0x73, 0x74, 0x69, 0x63, 0x73, 0x62, 0x06, 0x70, 0x72,
0x6f, 0x74, 0x6f, 0x33,
}
var (
......
......@@ -20,6 +20,7 @@ enum Type {
INVOICE_SERVICE = 12;
INVOICE_PAYMENT = 13;
DOCUMENT = 14;
INVOICE_PRODUCT = 15;
}
message UploadRequest {
......
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.2.0
// - protoc v3.21.7
// - protoc v3.21.12
// source: statistics.proto
package statistics
......
......@@ -534,6 +534,19 @@ func GetDBConfigByType(apiType api.Type, pipeline string) (*domain.DBConfig, err
BigQueryTableName: "payment",
SslMode: "disable",
}, nil
case api.Type_INVOICE_PRODUCT:
return &domain.DBConfig{
Type: domain.DBTypePostgres,
User: env.ResolveString("INVOICE_USER", "data"),
Password: env.ResolveString("INVOICE_PASSWORD", "data"),
Host: env.ResolveString("INVOICE_HOST", "mashroom-invoice-postgres"),
Port: env.ResolveString("INVOICE_PORT", "5432"),
Database: env.ResolveString("INVOICE_DATABASE", "data"),
TableOrCollectionName: env.ResolveString("INVOICE_PAYMENT_COLLECTION", "products"),
BigQueryDataset: fmt.Sprintf("raw_%s_mashroom_postgres_%s", pipeline, "invoice"),
BigQueryTableName: "product",
SslMode: "disable",
}, nil
default:
return nil, fmt.Errorf("DBConfig for %s not found", apiType)
}
......@@ -547,6 +560,7 @@ func GetAllTypesGroupedByDataSets() [][]api.Type {
api.Type_INVOICE_CHARGES,
api.Type_INVOICE_SERVICE,
api.Type_INVOICE_PAYMENT,
api.Type_INVOICE_PRODUCT,
},
{
api.Type_PROPERTY,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment