@@ -125,7 +125,7 @@ The Trino JDBC driver allows users to access Trino from Java-based applications,
125125
126126Refer to the https://trino.io/docs/current/client/jdbc.html[Trino documentation] for setup instructions.
127127
128- The following is an example of a JDBC URL used to create a connection to Redis SQL Trino :
128+ The following is an example of a JDBC URL used to create a connection to {project-name} :
129129
130130[source]
131131----
@@ -157,10 +157,11 @@ cd {project-name}
157157
158158Follow these step-by-step instructions to deploy a single-node Trino server on Ubuntu.
159159
160+ === Install Java
161+
160162Trino requires a 64-bit version of Java 17.
161163It is recommended to use https://www.azul.com/downloads/?package=jdk[Azul Zulu] as the JDK.
162164
163- .Install Java
164165[source,console]
165166----
166167$ java -version
@@ -169,9 +170,10 @@ OpenJDK Runtime Environment Zulu17.36+17-CA (build 17.0.4.1+1-LTS)
169170OpenJDK 64-Bit Server VM Zulu17.36+17-CA (build 17.0.4.1+1-LTS, mixed mode, sharing)
170171----
171172
173+ === Set up Trino
174+
172175Download the Trino server tarball and unpack it.
173176
174- .Install Trino
175177[source,console,subs="verbatim,attributes"]
176178----
177179wget https://repo1.maven.org/maven2/io/trino/trino-server/{trino-version}/trino-server-{trino-version}.tar.gz
@@ -190,15 +192,14 @@ mkdir -p {trino-datadir}
190192
191193Create an `etc` directory inside the installation directory to hold configuration files.
192194
193- .Create etc directory
194195[source,console,subs="verbatim,attributes"]
195196----
196197mkdir {trino-dir}/etc
197198----
198199
199- Create a node properties file.
200+ Create a ` node. properties` file.
200201
201- .etc/node.properties
202+ .{trino-dir}/ etc/node.properties
202203[source,properties,subs="verbatim,attributes"]
203204----
204205node.environment=production
@@ -208,7 +209,7 @@ node.data-dir={trino-datadir}
208209
209210Create a JVM config file.
210211
211- .etc/jvm.config
212+ .{trino-dir}/ etc/jvm.config
212213[source,console]
213214----
214215-server
@@ -231,7 +232,7 @@ Create a JVM config file.
231232
232233Create a config properties file.
233234
234- .etc/config.properties
235+ .{trino-dir}/ etc/config.properties
235236[source,properties]
236237----
237238coordinator=true
@@ -242,24 +243,32 @@ discovery.uri=http://localhost:8080
242243
243244Create a logging configuration file.
244245
245- .etc/log.properties
246+ .{trino-dir}/ etc/log.properties
246247[source,properties]
247248----
248249io.trino=INFO
249250----
250251
251- Download latest {project-url}/releases/latest[release] and unzip without any directory structure under `plugin/redisearch`.
252+ === Set up {project-name}
253+
254+ Download latest {project-url}/releases/latest[release] and unzip without any directory structure under `plugin/redisearch`:
252255
253- .Install RediSearch plugin
254256[source,console,subs="verbatim,attributes"]
255257----
256- wget {project-url}/releases/download/v{trino -version}/{artifact-id}-{trino -version}.zip
258+ wget {project-url}/releases/download/v{project -version}/{artifact-id}-{project -version}.zip
257259unzip -j {artifact-id}-{project-version}.zip -d {trino-dir}/plugin/redisearch
258260----
259261
260- Create a RediSearch connector configuration file.
262+ Create a etc/catalog subdirectory:
261263
262- .etc/catalog/redisearch.properties
264+ [source,console,subs="verbatim,attributes"]
265+ ----
266+ mkdir {trino-dir}/etc/catalog
267+ ----
268+
269+ Create a RediSearch connector configuration file:
270+
271+ .{trino-dir}/etc/catalog/redisearch.properties
263272[source,properties]
264273----
265274connector.name=redisearch
@@ -268,29 +277,29 @@ redisearch.uri=redis://localhost:6379
268277
269278Change and/or add <<properties,properties>> as needed.
270279
271- Start the Trino server.
280+ === Start Trino
281+
282+ Start the Trino server:
272283
273- .Run Trino server
274284[source,console,subs="verbatim,attributes"]
275285----
276286{trino-dir}/bin/launcher run
277287----
278288
279- Download https://repo1.maven.org/maven2/io/trino/trino-cli/{trino-version}/trino-cli-{trino-version}-executable.jar[trino-cli-{trino-version}-executable.jar], rename it to `trino`, make it executable with `chmod +x`, and run it to show the version of the CLI.
289+ === Run Trino CLI
290+
291+ Download and run https://repo1.maven.org/maven2/io/trino/trino-cli/{trino-version}/trino-cli-{trino-version}-executable.jar[trino-cli-{trino-version}-executable.jar]:
280292
281- .Install Trino CLI
282293[source,console,subs="verbatim,attributes"]
283294----
284- wget https://repo1.maven.org/maven2/io/trino/trino-cli/{trino-version}/trino-cli-{trino-version}-executable.jar
285- mv trino-cli-{trino-version}-executable.jar trino
286- chmod +x trino
295+ wget https://repo1.maven.org/maven2/io/trino/trino-cli/{trino-version}/trino-cli-{trino-version}-executable.jar -O /usr/local/bin/trino
296+ chmod +x /usr/local/bin/ trino
297+ trino --catalog redisearch --schema default
287298----
288299
289- Connect to Trino using the CLI and run a SQL query.
300+ Run a SQL query:
290301
291- .Run Trino CLI
292302[source,console]
293303----
294- ./trino --catalog redisearch --schema default
295304trino:default> select * from mySearchIndex;
296305----
0 commit comments