Skip to content

Commit 16c085e

Browse files
committed
feat: added timeout for prisma service
1 parent e6053fe commit 16c085e

File tree

3 files changed

+17
-3
lines changed

3 files changed

+17
-3
lines changed

.circleci/config.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ workflows:
6868
branches:
6969
only:
7070
- develop
71+
- pm-2539
7172

7273
# Production builds are exectuted only on tagged commits to the
7374
# master branch.

.env.sample

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,11 @@ SERVICEACC02_CID="devadmin1"
143143
SERVICEACC02_SECRET="devadmin1"
144144
SERVICEACC02_UID="100000027"
145145

146-
# Note: Registration default password is no longer configurable; for social/SSO
147-
# registrations without a provided password, a unique 16-character random
148-
# password is generated at registration time.
146+
# Note: Registration default password is no longer configurable; for social/SSO
147+
# registrations without a provided password, a unique 16-character random
148+
# password is generated at registration time.
149+
150+
151+
# Prisma configuration
152+
153+
IDENTITY_SERVICE_PRISMA_TIMEOUT=10000

src/shared/member-prisma/member-prisma.service.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,14 @@ export class MemberPrismaService
66
extends MemberPrismaClient
77
implements OnModuleInit, OnModuleDestroy
88
{
9+
constructor() {
10+
super({
11+
transactionOptions: {
12+
timeout: process.env.IDENTITY_SERVICE_PRISMA_TIMEOUT || 10000,
13+
},
14+
});
15+
}
16+
917
async onModuleInit() {
1018
await this.$connect();
1119
}

0 commit comments

Comments
 (0)