Skip to content

Commit c616d26

Browse files
committed
OK
1 parent 2c0c6f1 commit c616d26

File tree

4 files changed

+38
-19
lines changed

4 files changed

+38
-19
lines changed

.gitpod.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ image:
22
file: .gitpod.Dockerfile
33

44
tasks:
5-
# ------------------------------------
6-
# SETUP CQLSH
7-
# ------------------------------------
5+
# --------------------------------------
6+
# SETUP CQLSH and Create DB Workshop
7+
# --------------------------------------
88
- name: setup-cqlsh
99
env:
1010
CQLENG_ALLOW_SCHEMA_MANAGEMENT: 1
@@ -65,7 +65,6 @@ github:
6565

6666
vscode:
6767
extensions:
68-
- cool2k.vscode-lombok
69-
- datastax.astra-for-vs-code
68+
- GabrielBB.vscode-lombok
7069
- vscjava.vscode-java-pack
7170
- Pivotal.vscode-boot-dev-pack

cqlsh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/bash
2+
set -a
3+
source /workspace/workshop-spring-reactive/.env
4+
set +a
5+
/workspace/workshop-spring-reactive/tools/cqlsh-astra/bin/cqlsh -u token -p ${ASTRA_DB_ADMIN_TOKEN} -b /home/gitpod/.astra/scb_${ASTRA_DB_ID}_${ASTRA_DB_REGION}.zip

pom.xml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,26 +20,25 @@
2020
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
2121

2222
<springfox.version>3.0.0</springfox.version>
23-
<astra-sdk.version>0.2.2</astra-sdk.version>
23+
<astra-sdk.version>0.3.0</astra-sdk.version>
2424
<slf4j.version>1.7.30</slf4j.version>
25-
<cassandra-java-driver.version>4.13.0</cassandra-java-driver.version>
25+
<cassandra-java-driver.version>4.14.0</cassandra-java-driver.version>
2626
<maven.test.skip>false</maven.test.skip>
2727
</properties>
2828

2929
<dependencies>
3030

31-
<!-- Reactive REST API -->
32-
<dependency>
33-
<groupId>org.springframework.boot</groupId>
34-
<artifactId>spring-boot-starter-webflux</artifactId>
35-
</dependency>
36-
3731
<!-- Api documentation -->
3832
<dependency>
3933
<groupId>io.springfox</groupId>
4034
<artifactId>springfox-boot-starter</artifactId>
4135
<version>${springfox.version}</version>
4236
</dependency>
37+
<!-- Reactive REST API -->
38+
<dependency>
39+
<groupId>org.springframework.boot</groupId>
40+
<artifactId>spring-boot-starter-webflux</artifactId>
41+
</dependency>
4342

4443
<!-- Cassandra -->
4544
<dependency>

src/main/resources/application.yml

Lines changed: 22 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,26 @@
11
server:
22
port: 9966
3+
4+
spring:
5+
application:
6+
name: petclinic
7+
data:
8+
cassandra:
9+
schema-action: create-if-not-exists
310

411
astra:
5-
application-token: <CHANGE_ME>
6-
database-id: <CHANGE_ME>
7-
database-region: <CHANGE_ME>
8-
keyspace: spring_petclinic
9-
metrics:
10-
enabled: false
12+
api:
13+
application-token: ${ASTRA_DB_ADMIN_TOKEN}
14+
database-id: ${ASTRA_DB_ID}
15+
database-region: ${ASTRA_DB_REGION}
16+
cql:
17+
enabled: true
18+
download-scb:
19+
enabled: true
20+
driver-config:
21+
basic:
22+
session-keyspace: spring_petclinic
23+
advanced:
24+
connection:
25+
init-query-timeout: 10s
26+

0 commit comments

Comments
 (0)