Skip to content

Commit

Permalink
#4213 Restore
Browse files Browse the repository at this point in the history
Signed-off-by: Stepan Kiryakov <[email protected]>
  • Loading branch information
Stepan-Kirjakov committed Oct 31, 2024
1 parent fc5b8dd commit 3bcb54e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion guardian-service/src/api/profile.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ async function createUserProfile(
if (vcDocument) {
logger.info('Create VC Document', ['GUARDIAN_SERVICE']);

let credentialSubject: any = { ...vcDocument } || {};
let credentialSubject: any = { ...vcDocument };
credentialSubject.id = userDID;
if (schemaObject) {
credentialSubject = SchemaHelper.updateObjectContext(schemaObject, credentialSubject);
Expand Down
11 changes: 8 additions & 3 deletions queue-service/src/app.ts
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
import { ApplicationState, COMMON_CONNECTION_CONFIG, DatabaseServer, GenerateTLSOptionsNats, MessageBrokerChannel, mongoForLoggingInitialization, NotificationService, PinoLogger, pinoLoggerInitialization } from '@guardian/common';
import { ApplicationState, COMMON_CONNECTION_CONFIG, DatabaseServer, GenerateTLSOptionsNats, LargePayloadContainer, MessageBrokerChannel, mongoForLoggingInitialization, NotificationService, PinoLogger, pinoLoggerInitialization } from '@guardian/common';
import { ApplicationStates, GenerateUUIDv4 } from '@guardian/interfaces';
import { MikroORM } from '@mikro-orm/core';
import { MongoDriver } from '@mikro-orm/mongodb';
import * as process from 'process';
import { Module } from '@nestjs/common';
import { NestFactory } from '@nestjs/core';
import { MicroserviceOptions, Transport } from '@nestjs/microservices';
import { QueueService } from './queue-service/queue-service';
import { QueueService } from './queue-service/queue-service.js';

@Module({
providers: [
NotificationService,
]
})
class AppModule{
class AppModule {
}

const channelName = (process.env.SERVICE_CHANNEL || `queue.${GenerateUUIDv4().substring(26)}`).toUpperCase();
Expand Down Expand Up @@ -51,6 +51,11 @@ Promise.all([

await new QueueService().setConnection(cn).init();

const maxPayload = parseInt(process.env.MQ_MAX_PAYLOAD, 10);
if (Number.isInteger(maxPayload)) {
new LargePayloadContainer().runServer();
}

await state.updateState(ApplicationStates.READY);
await logger.info('Queue service started', ['QUEUE_SERVICE'])

Expand Down
2 changes: 1 addition & 1 deletion worker-service/src/api/helpers/hedera-sdk-helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ import { ContractParamType, FireblocksCreds, GenerateUUIDv4, HederaResponseCode,
import Long from 'long';
import { TransactionLogger } from './transaction-logger.js';
import process from 'process';
import { FireblocksHelper } from './fireblocks-helper';
import { FireblocksHelper } from './fireblocks-helper.js';

export const MAX_FEE = Math.abs(+process.env.MAX_TRANSACTION_FEE) || 30;
export const INITIAL_BALANCE = 30;
Expand Down

0 comments on commit 3bcb54e

Please sign in to comment.