Skip to content

Commit 5805c36

Browse files
chore: regenerate README (#265)
This PR was generated using Autosynth. 🌈 <details><summary>Log from Synthtool</summary> ``` 2020-11-08 23:10:41,211 synthtool [DEBUG] > Executing /root/.cache/synthtool/java-spanner-jdbc/.github/readme/synth.py. On branch autosynth-readme nothing to commit, working directory clean 2020-11-08 23:10:42,077 synthtool [DEBUG] > Wrote metadata to .github/readme/synth.metadata/synth.metadata. ``` </details> Full log will be available here: https://source.cloud.google.com/results/invocations/c618af2e-7ed8-4b37-892b-2ac9dc809ab4/targets - [ ] To automatically regenerate this PR, check this box.
1 parent 5f6522f commit 5805c36

File tree

2 files changed

+5
-27
lines changed

2 files changed

+5
-27
lines changed

.github/readme/synth.metadata/synth.metadata

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
"git": {
55
"name": ".",
66
"remote": "https://github.com/googleapis/java-spanner-jdbc.git",
7-
"sha": "03f85578270816cdbcafa480bbf69e2fa9775dc5"
7+
"sha": "3a305ba00b9739ceb17c879f82319b0a6b2a3f9f"
88
}
99
},
1010
{
1111
"git": {
1212
"name": "synthtool",
1313
"remote": "https://github.com/googleapis/synthtool.git",
14-
"sha": "6abb59097be84599a1d6091fe534a49e5c5cf948"
14+
"sha": "1f1148d3c7a7a52f0c98077f976bd9b3c948ee2b"
1515
}
1616
}
1717
]

README.md

Lines changed: 3 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -58,30 +58,8 @@ See the [Google Cloud Spanner JDBC client library docs][javadocs] to learn how t
5858
use this Google Cloud Spanner JDBC Client Library.
5959

6060

61-
### Creating a JDBC Connection
62-
63-
The following example shows how to create a JDBC connection to Cloud Spanner and execute a simple query.
64-
65-
```java
66-
String projectId = "my-project";
67-
String instanceId = "my-instance";
68-
String databaseId = "my-database";
69-
70-
try (Connection connection =
71-
DriverManager.getConnection(
72-
String.format(
73-
"jdbc:cloudspanner:/projects/%s/instances/%s/databases/%s",
74-
projectId, instanceId, databaseId))) {
75-
try (Statement statement = connection.createStatement()) {
76-
try (ResultSet rs = statement.executeQuery("SELECT CURRENT_TIMESTAMP()")) {
77-
while (rs.next()) {
78-
System.out.printf(
79-
"Connected to Cloud Spanner at [%s]%n", rs.getTimestamp(1).toString());
80-
}
81-
}
82-
}
83-
}
84-
```
61+
62+
8563

8664

8765
## Troubleshooting
@@ -123,7 +101,7 @@ Java 8 OSX | [![Kokoro CI][kokoro-badge-image-3]][kokoro-badge-link-3]
123101
Java 8 Windows | [![Kokoro CI][kokoro-badge-image-4]][kokoro-badge-link-4]
124102
Java 11 | [![Kokoro CI][kokoro-badge-image-5]][kokoro-badge-link-5]
125103

126-
[product-docs]: https://cloud.google.com/spanner/docs/use-oss-jdbc
104+
[product-docs]: https://cloud.google.com/pubsub/docs/
127105
[javadocs]: https://googleapis.dev/java/google-cloud-spanner-jdbc/latest/index.html
128106
[kokoro-badge-image-1]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-spanner-jdbc/java7.svg
129107
[kokoro-badge-link-1]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-spanner-jdbc/java7.html

0 commit comments

Comments
 (0)