Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: API agent spinup #381

Merged
merged 7 commits into from
Dec 28, 2023
Merged

refactor: API agent spinup #381

merged 7 commits into from
Dec 28, 2023

Conversation

KulkarniShashank
Copy link
Contributor

What

Refactoring the code related to API agent spinup, To enhance its efficiency, readability, and maintainability. This includes restructuring the initialization process and optimizing relevant components for improved performance.

Why

The refactoring is motivated by the need to address existing code complexities, reduce redundancy, and ensure a more streamlined and coherent API agent spinup process.

How

  • Code Restructuring:
    Reorganize the existing codebase to create a more modular and organized structure.
    Identify and eliminate any redundant or unnecessary code blocks.

  • Performance Optimization:
    Evaluate and enhance the efficiency of API agent initialization routines.
    Optimize resource utilization for a more responsive and scalable.

Signed-off-by: KulkarniShashank <[email protected]>
}

if (AgentSpinUpStatus.COMPLETED === getOrgAgent?.agentSpinUpStatus) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we use Switch case over here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using a switch statement is preferable when dealing with multiple 'if-else' cases. If there is only a single 'if' condition, then using an 'if' statement is appropriate. Can I proceed with this approach ?

libs/common/src/response-messages/index.ts Outdated Show resolved Hide resolved
libs/common/src/response-messages/index.ts Outdated Show resolved Hide resolved
Copy link

sonarcloud bot commented Dec 28, 2023

Quality Gate Passed Quality Gate passed

The SonarCloud Quality Gate passed, but some issues were introduced.

1 New issue
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@vivekayanworks vivekayanworks merged commit f9a2a37 into nats-refactor Dec 28, 2023
2 checks passed
@vivekayanworks vivekayanworks deleted the API-agent-spinup branch December 28, 2023 07:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants