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

chore: support for common interface to get a session to support multiplexed session #2204

Merged
merged 12 commits into from
Dec 27, 2024

Conversation

alkatrivedi
Copy link
Contributor

@alkatrivedi alkatrivedi commented Dec 12, 2024

This PR contains the common interface class SessionFactory which will be responsible for the creation of the Session Pool and the Multiplexed Session(if the env variable would be set to true) upon client initialization.

This PR also contains the getSession method which will return the session(multiplexed/regular) based upon the env variable value.

@alkatrivedi alkatrivedi requested review from a team as code owners December 12, 2024 02:32
@product-auto-label product-auto-label bot added size: l Pull request size is large. api: spanner Issues related to the googleapis/nodejs-spanner API. labels Dec 12, 2024
@alkatrivedi alkatrivedi force-pushed the get-session-class branch 4 times, most recently from bddd1d4 to 421a5a1 Compare December 16, 2024 09:25
@alkatrivedi alkatrivedi force-pushed the get-session-class branch 3 times, most recently from 21394ef to 3730a8a Compare December 19, 2024 17:07
@alkatrivedi alkatrivedi added kokoro:force-run Add this label to force Kokoro to re-run the tests. owlbot:run Add this label to trigger the Owlbot post processor. labels Dec 19, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Dec 19, 2024
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Dec 19, 2024
@alkatrivedi alkatrivedi added kokoro:force-run Add this label to force Kokoro to re-run the tests. owlbot:run Add this label to trigger the Owlbot post processor. labels Dec 20, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Dec 20, 2024
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Dec 20, 2024
@alkatrivedi alkatrivedi force-pushed the get-session-class branch 3 times, most recently from e24245d to be238ed Compare December 21, 2024 08:12
@alkatrivedi alkatrivedi added the owlbot:run Add this label to trigger the Owlbot post processor. label Dec 21, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Dec 21, 2024
@alkatrivedi alkatrivedi added kokoro:force-run Add this label to force Kokoro to re-run the tests. owlbot:run Add this label to trigger the Owlbot post processor. labels Dec 21, 2024
@product-auto-label product-auto-label bot added the size: xl Pull request size is extra large. label Dec 27, 2024
@product-auto-label product-auto-label bot added size: l Pull request size is large. and removed size: xl Pull request size is extra large. labels Dec 27, 2024
@alkatrivedi alkatrivedi added kokoro:force-run Add this label to force Kokoro to re-run the tests. owlbot:run Add this label to trigger the Owlbot post processor. labels Dec 27, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Dec 27, 2024
*
* @param {Database} database Database object.
* @param {String} name Name of the database.
* @param {SessionPoolOptions|SessionPoolInterface} options Session pool
Copy link
Contributor

Choose a reason for hiding this comment

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

SessionPoolConstructor right

Suggested change
* @param {SessionPoolOptions|SessionPoolInterface} options Session pool
* @param {SessionPoolOptions| SessionPoolConstructor} options Session pool

Copy link
Contributor

Choose a reason for hiding this comment

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

Please let me know if my understanding is incorrect ?

Copy link
Contributor Author

@alkatrivedi alkatrivedi Dec 27, 2024

Choose a reason for hiding this comment

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

Since, the SessionPoolConstructor is eventually creating SessionPoolInterface object, hence we can keep SessionPoolInterface here in the documentation

@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Dec 27, 2024
@alkatrivedi alkatrivedi added kokoro:force-run Add this label to force Kokoro to re-run the tests. owlbot:run Add this label to trigger the Owlbot post processor. labels Dec 27, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Dec 27, 2024
@alkatrivedi alkatrivedi added the do not merge Indicates a pull request not ready for merge, due to either quality or timing. label Dec 27, 2024
@surbhigarg92 surbhigarg92 changed the title feat: support for common interface to get a session chore: support for common interface to get a session to support multiplexed session Dec 27, 2024
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Dec 27, 2024
@alkatrivedi alkatrivedi added kokoro:force-run Add this label to force Kokoro to re-run the tests. owlbot:run Add this label to trigger the Owlbot post processor. labels Dec 27, 2024
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Dec 27, 2024
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Dec 27, 2024
@alkatrivedi alkatrivedi added automerge Merge the pull request once unit tests and other checks pass. and removed do not merge Indicates a pull request not ready for merge, due to either quality or timing. labels Dec 27, 2024
@gcf-merge-on-green gcf-merge-on-green bot merged commit b467380 into main Dec 27, 2024
19 checks passed
@gcf-merge-on-green gcf-merge-on-green bot removed the automerge Merge the pull request once unit tests and other checks pass. label Dec 27, 2024
@gcf-merge-on-green gcf-merge-on-green bot deleted the get-session-class branch December 27, 2024 13:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: spanner Issues related to the googleapis/nodejs-spanner API. size: l Pull request size is large.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants