I architect and lead high-performance systems that don't just handle growth—they accelerate it. At Crickpe, I designed a distributed architecture that seamlessly manages 100k requests/minute, leveraging Redis and RabbitMQ to ensure lightning-fast responsiveness. My database optimizations kept user experience smooth even as traffic surged.
Currently, as the Solution Architect at Zerope, I'm orchestrating a cloud-native future with Kubernetes. Our microservices architecture isn't just a buzzword—it's a strategic choice that enhances our agility and scalability. We're not just building a product; we're building an adaptable tech ecosystem.
Tech Lead
Third unicorn pvt ltdTechnical Lead
Third Unicorn Pvt LtdTeam Lead
Codebrew labs pvt ltdSoftware Engineer
Brucode Technologies pvt ltdMEAN Stack Developer
Innovation Pvt LtdMeanstack developer
Innovation pvt ltdNode.js

MySQL

NoSQL

Angular

React

Nest.js

Redis

Express

MongoDB

Postgres

Next.js

SignalR
Uh, could you help me understand more about your background by giving a brief introduction of yourself? Uh, yes. Uh, I am at I'm working as a tech lead in 0 pay. So, like, I am handling 2 product, uh, 0 pay and click pay in my team. So and, basically, like, we are a product based company, and, uh, so, like, I'm I'm dealing uploaded. Okay. Uh, so, like, I am dealing with, yeah. So I'm leading the team tech team over here. So, uh, we are, uh, designing the system that that should be more scalable for the user. So mostly, we try to, uh, uh, design a system that should scale horizontally. So we are using, uh, Node. Js. Uh, our text type is in Node. Js. So, like, we are using NestJS with TypeScript because we decided to have a more safety checking. So, uh, our back end is in NestJS. And we are using Postgres as a database, and, uh, we are using, uh, RabbitMQ for the queue management. And on the server side, we are using Kubernetes. So Google managed Kubernetes. Uh, we are with GCP. So, uh, basically, uh, we want to scale our server horizontally so it can, you know, handle as much as the traffic will come. So, yes, we have tested our server with higher number of users also. So our ports, uh, get increased by in case. So it it is handling, uh, handling the load well. K. And we try to write the optimized code so that it should take less, uh, less server resources.
Could you suggest a strategy for implementing role based access control? Role based access control in Node. Js API using passport. Uh, like, I haven't used passport, but, yes, I have used JWT token. So, uh, JWT auth, we use here. So by using JWT auth, we can easily implement, uh, role based access, like when we generate the JWT token. So what we can do is we can, uh, we can, you know, uh, check what is the role of a user. So in the token itself, we can pass that information. So we can pass user ID and the role. And when we will get the hit from the user, so we can check-in the database and, uh, okay. This user have this role. And, also, uh, we will cache it to the Redis because we don't want every time we get hit from the user, we should check-in the database. So we will check-in the Redis. So like this, I think, uh, we can easily implement role based access.
How would you use Type ORM to manage database schema migration in production environment? Yeah. Like, currently, in the Nest JS product, uh, we are using type ORM only. So to manage a schema migration, so, uh, we are using type ORM commands to generate the migration. So, like, in the type ORM, we define our collection as entity. So the entity we define, okay, these are the column we need. And then, uh, we, uh, we click on we run the command to generate the migration. So it check from the entry table and then database, it compares. And then the missing, uh, missing row missing missing schema, it adds the command in our any table or any alter command. It will add, uh, in the in the migration file. So I think this is how, uh, we are doing it, and then we run the migration on the prod. Yes. We are using type 1 m for cedar also. Like, we use the cedar functionality to, uh, seed any prefilled data to our system.
In which cases, would you prefer to use type ORM over other ORM and why? Uh, basically, we just used type ORM because it is, you know, much we we were having we have to choose between SQLize and Type ORM. So we have done r and d for both. So we find out that, okay, SQLize is for, you know, if you need a heavy and more features from the ORM, you can use SQLize. But Type ORM is lightweighted TypeScript ORM. So this this works fine, and, I think, in build support it. So I I I have chosen type ORM for this.
What concern must taken into account when implementing pagination of record from a MySQL database in uh, when you implement, uh, pagination, then you must, uh, you know, check that, okay, if you have large number of records, then if you send that, okay, these are the record 10 records, and then you send total count. So when you send the total count, uh, and then no. You know? You you have to scan all the table, and then you have to provide the total count. So if the queries get complex, it is it is little bit heavy to get the total count. Like, okay. When you have lots of filter and everything, then, yeah, the total count will be a challenge, uh, will be a challenge. Yes. Uh, so I think, uh, you have to implement indexing on those on those filters. So, basically, if you have a filter of name, suppose, so you have to index your name field also. And in the app, uh, in the app, when I do the pagination, what I do is I, uh, because normally it is scrolling, so in there, we don't have to specify the total pages. So what I do is I I just suppose you have I have to give 10 records. So what I do is I I just query 11 records and check, okay, if there are there is one more record. So I slice it before sending it, but now I know that, okay, there is one more record. So I send a key, has more true. So so if they get has more truth, so they will again hit our API. So this is how, uh, I implement the app based pagination. And in this, like, I just have to fetch, you know, 11 record. That's it. I don't have to count all the records. So, like, if you have in 1,000,000 and billions, so counting all the records will be a challenge for you.
How can we leverage the Type ORM library to enforce referential integrity across table relationship in a MySQL database. Uh, basically, referential integrity, yeah, we implement a foreign key. We implement, uh, foreign key. And in the entity class, uh, we define, uh, suppose there is a user table and then there is a role table. So in user enrolled role. So, uh, there is a user table. There is a OTP table. So in the OTP table, we have user OTP. So in the OTP table, yeah, we define that, okay, OTP, uh, will have many. So that will be has many has many relation with user, and user will have, you know, has user will have has many with the with OTP, and OTP will have one relation, like, one user ID. So this is how, like, we have has 1, has has many relation belongs to. So we use this type of, uh, this type of, uh, relationship definition. So we define it, uh, using this in my seat.
Can given given the JavaScript code is in the spot, any button? Client socket Require socket. IO socket. IO. Uh, the optimization, I think, um, the code looks good. Spot any potential performance issue. Not much idea about it, but, yeah, we can use, uh, connection pulling so that we can limit the number of connection. I think this is my suggestion.
How do you ensure that API endpoint developed with the expresses are strongly typed when using TypeScript? We ensure, like, we use, uh, we we implement TypeScript in our Express JS pro project, and then, yeah, we use, uh, like, the TypeScript will give us the error. Like okay. And, uh, yeah, we just have to use TypeScript in our expression, and we can run it using that. So that will help us. And, uh, uh, the API endpoints, yeah, we like we can, you know, define everything with the with the type checking. So I think yeah.
What approach would you take to migrate a complex database schema without downtime using type ORM and Node. Js? Okay. So migrate a complex database schema. So, like, if you run any schema so, yeah, it I don't think, uh, Node. Js or Type ORM will give any error. So, yeah, I think it will work fine. Uh, there won't be an issue with that.
What method do you recommend for implementing a custom valid logic in type ORM that are not supported? What customer? What method? So we can create our own class, and we can use it.
Details how you would manage asynchronous programming in Node JS to optimize performance while integrating multiple third party APIs. It is how you would manage asynchronous programming in Node. Js to optimize performance when integrating. Recording. Multiple. Uh, details. See how you would manage asynchronous programming notices to optimize when integrated. So, like, when we use multiple third party API app, so we can call them in promise and, uh, like, promise dot all, and we can call all the 3rd parties so, like, it will run parallelly. And if they are dependent on, like, each other, so we can, uh, use async library also. And by using that, uh, we can in async library, we have the option that, okay, we have to use waterfall model or we have to call everything at once. Even we can use, uh, async await also. In async await, we have the option to call, uh, all the APIs. If they are not dependent on each other, we will call all the APIs. We will call all the function without using a wait, and then, uh, we will call. And then when we will storing the result, then we will use the wait. And if they are dependent on each other, so we will use a wait and then call the function. So this is how we can, uh, we manage the manage and optimize the process.