-
Notifications
You must be signed in to change notification settings - Fork 73
feat: srw #1586
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
base: main-3.x
Are you sure you want to change the base?
Conversation
b3b7ada to
367647b
Compare
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
docs/using-the-jdbc-driver/using-plugins/UsingTheSimpleReadWriteSplittingPlugin.md
Outdated
Show resolved
Hide resolved
...les/AWSDriverExample/src/main/java/software/amazon/SimpleReadWriteSplittingMySQLExample.java
Outdated
Show resolved
Hide resolved
wrapper/src/main/java/software/amazon/jdbc/plugin/AuroraInitialConnectionStrategyPlugin.java
Outdated
Show resolved
Hide resolved
| this.pluginService = pluginService; | ||
| this.properties = properties; | ||
| this.writeEndpoint = writeEndpoint; | ||
| this.readEndpoint = SRW_READ_ENDPOINT.getString(properties); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it mean that SRW_READ_ENDPOINT is optional parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've updated it so that SRW_READ_ENDPOINT is required
| } | ||
|
|
||
| private boolean isWriteEndpoint(final @NonNull HostSpec hostSpec) { | ||
| return Objects.equals(hostSpec.getHost(), this.writeEndpoint); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to use getHostAndPort() and verify equalsIgnoreCase()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we expecting that the port is included in the endpoint?
wrapper/src/main/java/software/amazon/jdbc/plugin/srw/SimpleReadWriteSplittingPlugin.java
Show resolved
Hide resolved
wrapper/src/main/java/software/amazon/jdbc/plugin/srw/SimpleReadWriteSplittingPlugin.java
Show resolved
Hide resolved
wrapper/src/test/java/integration/container/tests/SimpleReadWriteSplittingTest.java
Outdated
Show resolved
Hide resolved
63f3490 to
3f4280b
Compare
Summary
introduces the Simple Read/Write Splitting Plugin (srw)
Description
an alternative to the existing Read/Write Splitting Plugin that connects directly to specified read and write endpoints
Additional Reviewers
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.