From 426ff2141fb00e6b2c6c43af3840740514a1778b Mon Sep 17 00:00:00 2001 From: "rodrigo.zamboni" Date: Wed, 29 Jun 2022 17:59:53 -0300 Subject: [PATCH] FIX: Changed registry after adding protospack to codeartifact --- Dockerfile | 1 - package-lock.json | 72 +++++++++---------- package.json | 6 +- src/clients/auth/client.service.ts | 6 +- src/clients/connector/client.config.ts | 2 +- src/clients/connector/client.service.ts | 2 +- src/clients/duc/client.config.ts | 2 +- src/clients/inputs/client.config.ts | 2 +- src/clients/inputs/client.service.ts | 2 +- src/clients/outputs/client.config.ts | 2 +- src/clients/outputs/client.service.ts | 2 +- src/clients/permissions/client.service.ts | 6 +- src/clients/pipelines/client.config.ts | 2 +- src/clients/pipelines/client.service.ts | 2 +- src/clients/transformations/client.config.ts | 2 +- src/clients/transformations/client.service.ts | 2 +- src/modules/auth/auth.controller.ts | 2 +- src/modules/inputs/inputs.service.ts | 4 +- src/modules/pipelines/pipelines.service.ts | 4 +- 19 files changed, 61 insertions(+), 62 deletions(-) diff --git a/Dockerfile b/Dockerfile index 370f2a2..0c77cb1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,7 +9,6 @@ RUN apk update && apk add curl unzip RUN apk add --no-cache aws-cli RUN aws codeartifact login --tool npm --repository dadosfera-npm --domain dadosfera --domain-owner 611330257153 --region us-east-1 -RUN npm install dadosfera-logs RUN npm install RUN rm -f ./.npmrc diff --git a/package-lock.json b/package-lock.json index 18e80a4..21bb1ae 100644 --- a/package-lock.json +++ b/package-lock.json @@ -21,8 +21,6 @@ "@nestjs/platform-express": "^8.4.7", "@nestjs/schedule": "^1.1.0", "@nestjs/swagger": "^5.2.1", - "@victorradael/protospack": "2.5.0", - "@victorradael/protospack-v2": "1.1.1", "axios": "^0.25.0", "cron-parser": "^4.4.0", "dadosfera-logs": "^1.0.0-alpha.10", @@ -36,6 +34,8 @@ "passport-google-oauth20": "^2.0.0", "passport-hubspot-oauth2": "^1.0.3", "passport-mailchimp": "^1.1.0", + "protospack": "2.5.1", + "protospack-v2": "1.1.1", "reflect-metadata": "^0.1.13", "rimraf": "^3.0.2", "rxjs": "^7.5.5", @@ -3320,23 +3320,6 @@ "url": "https://opencollective.com/typescript-eslint" } }, - "node_modules/@victorradael/protospack": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/@victorradael/protospack/-/protospack-2.5.0.tgz", - "integrity": "sha512-DORlm3uHAYVH9dlcmwyOxjA4rk1UZWFyYUpD02k0bFfrH+uzSWe8qiPtTgZym9P8U9D8bXYRWeLlroasBj2Rdw==", - "dependencies": { - "rxjs": "^7.5.5" - } - }, - "node_modules/@victorradael/protospack-v2": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@victorradael/protospack-v2/-/protospack-v2-1.1.1.tgz", - "integrity": "sha512-K9SuHcCGa7wynbzTG1aVnODksajTKfr9+tDHw6qfFfPwBruJXv5HsbMMylizAg+HTgEr/D6h/L1PO05rygDJCw==", - "dependencies": { - "rxjs": "^7.5.5", - "ts-proto": "^1.112.2" - } - }, "node_modules/@webassemblyjs/ast": { "version": "1.11.1", "dev": true, @@ -8980,6 +8963,23 @@ "pbts": "bin/pbts" } }, + "node_modules/protospack": { + "version": "2.5.1", + "resolved": "https://dadosfera-611330257153.d.codeartifact.us-east-1.amazonaws.com:443/npm/dadosfera-npm/protospack/-/protospack-2.5.1.tgz", + "integrity": "sha512-4JTx7B7WxpC1G3S8T7SUEAEgVM9UjdYrOG37fr42wKxl9y6wOyCZJYjG/lXeAqFXOEPj9KSlM+MqBfLIMHWHeA==", + "dependencies": { + "rxjs": "^7.5.5" + } + }, + "node_modules/protospack-v2": { + "version": "1.1.1", + "resolved": "https://dadosfera-611330257153.d.codeartifact.us-east-1.amazonaws.com:443/npm/dadosfera-npm/protospack-v2/-/protospack-v2-1.1.1.tgz", + "integrity": "sha512-BqIJSORaqauAT9kF4/cP/uJNCyoT3KxkVkamd7SWARMxnywFB/mpYJg/VDGcyvVOAU4IOLyjnXkrvRuylE0Q2w==", + "dependencies": { + "rxjs": "^7.5.5", + "ts-proto": "^1.112.2" + } + }, "node_modules/proxy-addr": { "version": "2.0.7", "license": "MIT", @@ -13304,23 +13304,6 @@ "eslint-visitor-keys": "^3.3.0" } }, - "@victorradael/protospack": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/@victorradael/protospack/-/protospack-2.5.0.tgz", - "integrity": "sha512-DORlm3uHAYVH9dlcmwyOxjA4rk1UZWFyYUpD02k0bFfrH+uzSWe8qiPtTgZym9P8U9D8bXYRWeLlroasBj2Rdw==", - "requires": { - "rxjs": "^7.5.5" - } - }, - "@victorradael/protospack-v2": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@victorradael/protospack-v2/-/protospack-v2-1.1.1.tgz", - "integrity": "sha512-K9SuHcCGa7wynbzTG1aVnODksajTKfr9+tDHw6qfFfPwBruJXv5HsbMMylizAg+HTgEr/D6h/L1PO05rygDJCw==", - "requires": { - "rxjs": "^7.5.5", - "ts-proto": "^1.112.2" - } - }, "@webassemblyjs/ast": { "version": "1.11.1", "dev": true, @@ -17160,6 +17143,23 @@ "long": "^4.0.0" } }, + "protospack": { + "version": "2.5.1", + "resolved": "https://dadosfera-611330257153.d.codeartifact.us-east-1.amazonaws.com:443/npm/dadosfera-npm/protospack/-/protospack-2.5.1.tgz", + "integrity": "sha512-4JTx7B7WxpC1G3S8T7SUEAEgVM9UjdYrOG37fr42wKxl9y6wOyCZJYjG/lXeAqFXOEPj9KSlM+MqBfLIMHWHeA==", + "requires": { + "rxjs": "^7.5.5" + } + }, + "protospack-v2": { + "version": "1.1.1", + "resolved": "https://dadosfera-611330257153.d.codeartifact.us-east-1.amazonaws.com:443/npm/dadosfera-npm/protospack-v2/-/protospack-v2-1.1.1.tgz", + "integrity": "sha512-BqIJSORaqauAT9kF4/cP/uJNCyoT3KxkVkamd7SWARMxnywFB/mpYJg/VDGcyvVOAU4IOLyjnXkrvRuylE0Q2w==", + "requires": { + "rxjs": "^7.5.5", + "ts-proto": "^1.112.2" + } + }, "proxy-addr": { "version": "2.0.7", "requires": { diff --git a/package.json b/package.json index 1d8f4c8..16dfcc7 100644 --- a/package.json +++ b/package.json @@ -36,8 +36,8 @@ "@nestjs/platform-express": "^8.4.7", "@nestjs/schedule": "^1.1.0", "@nestjs/swagger": "^5.2.1", - "@victorradael/protospack": "2.5.0", - "@victorradael/protospack-v2": "1.1.1", + "protospack": "2.5.1", + "protospack-v2": "1.1.1", "axios": "^0.25.0", "cron-parser": "^4.4.0", "dadosfera-logs": "^1.0.0-alpha.10", @@ -106,4 +106,4 @@ "coverageDirectory": "../coverage", "testEnvironment": "node" } -} +} \ No newline at end of file diff --git a/src/clients/auth/client.service.ts b/src/clients/auth/client.service.ts index 1c5397d..dd5b8c3 100644 --- a/src/clients/auth/client.service.ts +++ b/src/clients/auth/client.service.ts @@ -2,8 +2,8 @@ import { OnModuleInit, Inject } from '@nestjs/common'; import { ClientGrpc } from '@nestjs/microservices'; import { DadosferaLogger } from 'dadosfera-logs'; -import { ProtoServices } from '@victorradael/protospack-v2/dist/lib/Duc'; -import { AuthProtoService as AuthServiceInterface } from '@victorradael/protospack-v2/dist/lib/Duc/interfaces/write-service'; +import { ProtoServices } from 'protospack-v2/dist/lib/Duc'; +import { AuthProtoService as AuthServiceInterface } from 'protospack-v2/dist/lib/Duc/interfaces/write-service'; import { AuthGetPublicKeysResponse, AuthSignInRequest, @@ -26,7 +26,7 @@ import { AuthVerifyResetPasswordCodeResponse, AuthConfirmResetPasswordRequest, AuthConfirmResetPasswordResponse, -} from '@victorradael/protospack-v2/dist/lib/Duc/interfaces/messages'; +} from 'protospack-v2/dist/lib/Duc/interfaces/messages'; import grpcHandler from '../../utils/grpcHandler'; diff --git a/src/clients/connector/client.config.ts b/src/clients/connector/client.config.ts index 61db9a1..a22a9c8 100644 --- a/src/clients/connector/client.config.ts +++ b/src/clients/connector/client.config.ts @@ -1,6 +1,6 @@ import { credentials } from '@grpc/grpc-js'; import { ClientOptions, Transport } from '@nestjs/microservices'; -import { ConnectorManager } from '@victorradael/protospack-v2'; +import { ConnectorManager } from 'protospack-v2'; export class ConnectorClientConfiguration { config(): ClientOptions { diff --git a/src/clients/connector/client.service.ts b/src/clients/connector/client.service.ts index e30af72..fc8f9dc 100644 --- a/src/clients/connector/client.service.ts +++ b/src/clients/connector/client.service.ts @@ -6,7 +6,7 @@ import { } from '@nestjs/common'; import { DadosferaLogger } from 'dadosfera-logs'; import { ClientGrpc } from '@nestjs/microservices'; -import { ConnectorManager } from '@victorradael/protospack-v2'; +import { ConnectorManager } from 'protospack-v2'; import { from } from 'rxjs'; export class ConnectorClientService implements OnModuleInit { diff --git a/src/clients/duc/client.config.ts b/src/clients/duc/client.config.ts index e1f5de6..180cfa6 100644 --- a/src/clients/duc/client.config.ts +++ b/src/clients/duc/client.config.ts @@ -3,7 +3,7 @@ import { ClientOptions, Transport } from '@nestjs/microservices'; import { ProtoPackages, ProtoPaths, -} from '@victorradael/protospack-v2/dist/lib/Duc'; +} from 'protospack-v2/dist/lib/Duc'; export class DucClient { config(): ClientOptions { diff --git a/src/clients/inputs/client.config.ts b/src/clients/inputs/client.config.ts index 06c6340..525b5eb 100644 --- a/src/clients/inputs/client.config.ts +++ b/src/clients/inputs/client.config.ts @@ -1,7 +1,7 @@ import { credentials } from '@grpc/grpc-js'; import { ClientOptions, Transport } from '@nestjs/microservices'; -import { InputPackages, InputProtoFilePath } from '@victorradael/protospack'; +import { InputPackages, InputProtoFilePath } from 'protospack'; export class InputsClientConfiguration { config(): ClientOptions { diff --git a/src/clients/inputs/client.service.ts b/src/clients/inputs/client.service.ts index 826a276..0f4c94c 100644 --- a/src/clients/inputs/client.service.ts +++ b/src/clients/inputs/client.service.ts @@ -15,7 +15,7 @@ import { InputService, TestConnectionGetColumnsRequest, TestConnectionRequest, -} from '@victorradael/protospack'; +} from 'protospack'; import axios, { AxiosRequestConfig } from 'axios'; import { lastValueFrom } from 'rxjs'; import { InputModel } from 'src/modules/inputs/dtos/input.model'; diff --git a/src/clients/outputs/client.config.ts b/src/clients/outputs/client.config.ts index a9a5bc0..3fac08f 100644 --- a/src/clients/outputs/client.config.ts +++ b/src/clients/outputs/client.config.ts @@ -1,4 +1,4 @@ -import { OutputPackages, OutputProtoFilePath } from '@victorradael/protospack'; +import { OutputPackages, OutputProtoFilePath } from 'protospack'; import { ClientOptions, Transport } from '@nestjs/microservices'; import { credentials } from '@grpc/grpc-js'; diff --git a/src/clients/outputs/client.service.ts b/src/clients/outputs/client.service.ts index 20e4978..7f0b959 100644 --- a/src/clients/outputs/client.service.ts +++ b/src/clients/outputs/client.service.ts @@ -4,7 +4,7 @@ import { DadosferaLogger } from 'dadosfera-logs'; import { OutputServicesNames, OutputsServiceInterface, -} from '@victorradael/protospack'; +} from 'protospack'; import { objectCamelToSnake, objectSnakeToCamel, diff --git a/src/clients/permissions/client.service.ts b/src/clients/permissions/client.service.ts index a5a53ea..cfc30b4 100644 --- a/src/clients/permissions/client.service.ts +++ b/src/clients/permissions/client.service.ts @@ -1,12 +1,12 @@ import { OnModuleInit, Inject } from '@nestjs/common'; import { ClientGrpc } from '@nestjs/microservices'; -import { ProtoServices } from '@victorradael/protospack-v2/dist/lib/Duc'; -import { PermissionsProtoService as PermissionsServiceInterface } from '@victorradael/protospack-v2/dist/lib/Duc/interfaces/write-service'; +import { ProtoServices } from 'protospack-v2/dist/lib/Duc'; +import { PermissionsProtoService as PermissionsServiceInterface } from 'protospack-v2/dist/lib/Duc/interfaces/write-service'; import { Empty, InjectPermissionsRequest, -} from '@victorradael/protospack-v2/dist/lib/Duc/interfaces/messages'; +} from 'protospack-v2/dist/lib/Duc/interfaces/messages'; import { DadosferaLogger } from 'dadosfera-logs'; import grpcHandler from '../../utils/grpcHandler'; diff --git a/src/clients/pipelines/client.config.ts b/src/clients/pipelines/client.config.ts index 21d9a9e..01083eb 100644 --- a/src/clients/pipelines/client.config.ts +++ b/src/clients/pipelines/client.config.ts @@ -2,7 +2,7 @@ import { ClientOptions, Transport } from '@nestjs/microservices'; import { PipelinePackages, PipelineProtoFilePath, -} from '@victorradael/protospack'; +} from 'protospack'; import { credentials } from '@grpc/grpc-js'; export class PipelinesClientConfiguration { diff --git a/src/clients/pipelines/client.service.ts b/src/clients/pipelines/client.service.ts index 555110e..1326ddb 100644 --- a/src/clients/pipelines/client.service.ts +++ b/src/clients/pipelines/client.service.ts @@ -8,7 +8,7 @@ import { ClientGrpc, Payload } from '@nestjs/microservices'; import { PipelineServicesNames, PipelinesServiceInterface, -} from '@victorradael/protospack'; +} from 'protospack'; import { lastValueFrom } from 'rxjs'; import { objectCamelToSnake, diff --git a/src/clients/transformations/client.config.ts b/src/clients/transformations/client.config.ts index 461e6a9..26c52f1 100644 --- a/src/clients/transformations/client.config.ts +++ b/src/clients/transformations/client.config.ts @@ -2,7 +2,7 @@ import { ClientOptions, Transport } from '@nestjs/microservices'; import { TransformationPackages, TransformationProtoFilePath, -} from '@victorradael/protospack'; +} from 'protospack'; import { credentials } from '@grpc/grpc-js'; export class TransformationsClientConfiguration { diff --git a/src/clients/transformations/client.service.ts b/src/clients/transformations/client.service.ts index 731fb2c..ea00f88 100644 --- a/src/clients/transformations/client.service.ts +++ b/src/clients/transformations/client.service.ts @@ -1,6 +1,6 @@ import { Controller, Inject, OnModuleInit, Post } from '@nestjs/common'; import { ClientGrpc } from '@nestjs/microservices'; -import { TransformationsServiceInterface } from '@victorradael/protospack'; +import { TransformationsServiceInterface } from 'protospack'; import { DadosferaLogger } from 'dadosfera-logs'; import { objectCamelToSnake, diff --git a/src/modules/auth/auth.controller.ts b/src/modules/auth/auth.controller.ts index 712b744..d7dee17 100644 --- a/src/modules/auth/auth.controller.ts +++ b/src/modules/auth/auth.controller.ts @@ -19,7 +19,7 @@ import { AuthEnableTotpMfaRequest, AuthDisableTotpMfaRequest, AuthVerifyTotpMfaRequest, -} from '@victorradael/protospack-v2/dist/lib/Duc/interfaces/messages'; +} from 'protospack-v2/dist/lib/Duc/interfaces/messages'; import { AuthClientService } from '../../clients/auth/client.service'; import { PermissionsClientService } from '../../clients/permissions/client.service'; diff --git a/src/modules/inputs/inputs.service.ts b/src/modules/inputs/inputs.service.ts index a7c3715..29d9750 100644 --- a/src/modules/inputs/inputs.service.ts +++ b/src/modules/inputs/inputs.service.ts @@ -1,13 +1,13 @@ import { Body, HttpException, HttpStatus, Injectable } from '@nestjs/common'; import { Timeout } from '@nestjs/schedule'; -import { DecodeGrpcStruct } from '@victorradael/protospack'; +import { DecodeGrpcStruct } from 'protospack'; import CronParser, { CronExpression } from 'cron-parser'; import { InputsClientService } from 'src/clients/inputs/client.service'; import { IIdRequest, Info } from 'src/clients/inputs/interfaces'; @Injectable() export class InputsService { - constructor(private inputClient: InputsClientService) {} + constructor(private inputClient: InputsClientService) { } secondsInADay = 60 * 60 * 24; secondsInAnHour = 60 * 60; diff --git a/src/modules/pipelines/pipelines.service.ts b/src/modules/pipelines/pipelines.service.ts index 416ae97..3073831 100644 --- a/src/modules/pipelines/pipelines.service.ts +++ b/src/modules/pipelines/pipelines.service.ts @@ -1,12 +1,12 @@ import { HttpException, HttpStatus, Injectable } from '@nestjs/common'; -import { DecodeGrpcStruct } from '@victorradael/protospack'; +import { DecodeGrpcStruct } from 'protospack'; import { PipelinesClientService } from 'src/clients/pipelines/client.service'; import { IIdRequest, Info } from 'src/clients/pipelines/interfaces'; import { objectCamelToSnake } from 'src/utils/CaseConverter'; @Injectable() export class PipelinesService { - constructor(private pipelineClient: PipelinesClientService) {} + constructor(private pipelineClient: PipelinesClientService) { } adjustPayload(payload) { if (payload.input?.input_generic) {