You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Upgrade to spring-boot 3.2.5;
- Upgrade to springdoc-openapi 2.5.0;
- Upgrade to apache-maven 3.9.5;
- Upgrade to jib-maven-plugin 3.4.2;
- Upgrade to amazoncorretto-jdk 17.0.10
- Upgrade to elasticsearch docker image 8.10.4;
- Add in create-index.sh, a request to Elasticsearch to Fix High Disk Watermark issue;
- Remove obsolete version field in docker-compose.yml;
- Update README.
Copy file name to clipboardexpand all lines: README.adoc
+18-18
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
= springboot-elasticsearch-thymeleaf
2
2
3
-
The goal of this project is to implement an application called `product-app`. It consists of two https://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/[`Spring Boot`] services: `product-api` (backend) and `product-ui` (frontend). The data will be stored in https://www.elastic.co/products/elasticsearch[`Elasticsearch`].
3
+
The goal of this project is to implement an application called `product-app`. It consists of two https://spring.io/projects/spring-boot[`Spring Boot`] services: `product-api` (backend) and `product-ui` (frontend). The data will be stored in https://www.elastic.co/products/elasticsearch[`Elasticsearch`].
`Spring Boot` Web Java application that exposes a REST API to manages products. The information about products is stored in `Elasticsearch`. `product-api` uses https://docs.spring.io/spring-data/elasticsearch/docs/current/reference/html/[`Spring Data Elasticsearch`] to persist/query/delete data in https://www.elastic.co/products/elasticsearch[`Elasticsearch`]
17
+
`Spring Boot` Web Java application that exposes a REST API to manages products. The information about products is stored in `Elasticsearch`. `product-api` uses https://docs.spring.io/spring-data/elasticsearch/reference/[`Spring Data Elasticsearch`] to persist/query/delete data in https://www.elastic.co/products/elasticsearch[`Elasticsearch`].
* Open a terminal and navigate to `springboot-elasticsearch-thymeleaf` root folder run
30
+
* Open a terminal and navigate to `springboot-elasticsearch-thymeleaf` root folder run:
31
31
+
32
32
[source]
33
33
----
34
34
docker compose up -d
35
35
----
36
36
37
-
* Wait for `Elasticsearch` Docker container to be up and running. To check it, run
37
+
* Wait for `Elasticsearch` Docker container to be up and running. To check it, run:
38
38
+
39
39
[source]
40
40
----
@@ -45,23 +45,23 @@ docker compose ps
45
45
46
46
NOTE: In the following steps, we will create an index, an alias and do a reindex using pre-defined scripts. In case you prefer to do it step-by-step calling `Elasticsearch` API, refer to link:create-index-alias-reindex.adoc[Creating indexes, alias and reindexing using Elasticsearch API].
47
47
48
-
* In a terminal, make sure you are in `springboot-elasticsearch-thymeleaf` root folder
48
+
* In a terminal, make sure you are in `springboot-elasticsearch-thymeleaf` root folder;
49
49
50
-
* Run the following script to create the index `ecommerce.products.v1` with the alias `ecommerce.products` (you can use the default values by just pressing `Enter` on every user input)
50
+
* Run the following script to create the index `ecommerce.products.v1` with the alias `ecommerce.products` (you can use the default values by just pressing `Enter` on every user input):
51
51
+
52
52
[source]
53
53
----
54
54
./create-index.sh
55
55
----
56
56
57
-
* If you want to insert some products, run
57
+
* If you want to insert some products, run:
58
58
+
59
59
[source]
60
60
----
61
61
./insert-products.sh
62
62
----
63
63
64
-
* If you want to fix the `reference` property mapping error (explained below), run
64
+
* If you want to fix the `reference` property mapping error (explained below), run:
65
65
+
66
66
[source]
67
67
----
@@ -95,8 +95,8 @@ Below are the steps to start and run the applications using `Maven`. We will nee
95
95
== Running applications as Docker containers
96
96
97
97
* Build Docker Images
98
-
** In a terminal, make sure you are in `springboot-elasticsearch-thymeleaf` root folder
99
-
** Run the following script
98
+
** In a terminal, make sure you are in `springboot-elasticsearch-thymeleaf` root folder;
99
+
** Run the following script:
100
100
+
101
101
[source]
102
102
----
@@ -126,8 +126,8 @@ Below are the steps to start and run the applications using `Maven`. We will nee
126
126
|===
127
127
128
128
* Run Docker containers
129
-
** In a terminal, make sure you are in `springboot-elasticsearch-thymeleaf` root folder
130
-
** Run the following script
129
+
** In a terminal, make sure you are in `springboot-elasticsearch-thymeleaf` root folder;
130
+
** Run the following script:
131
131
+
132
132
[source]
133
133
----
@@ -148,21 +148,21 @@ Below are the steps to start and run the applications using `Maven`. We will nee
148
148
149
149
== Demo
150
150
151
-
* Below is a simple demo that shows a user interacting with `product-ui`
151
+
* Below is a simple demo that shows a user interacting with `product-ui`:
152
152
+
153
153
image::documentation/demo-user-interaction.gif[]
154
154
155
155
== Shutdown
156
156
157
-
* To stop applications
158
-
** If they were started with `Maven`, go to `product-api` and `product-ui` terminals and press `Ctrl+C`
159
-
** If they were started as Docker containers, go to a terminal and, inside `springboot-elasticsearch-thymeleaf` root folder, run the script below
157
+
* To stop applications:
158
+
** If they were started with `Maven`, go to `product-api` and `product-ui` terminals and press `Ctrl+C`;
159
+
** If they were started as Docker containers, go to a terminal and, inside `springboot-elasticsearch-thymeleaf` root folder, run the script below:
160
160
+
161
161
[source]
162
162
----
163
163
./stop-apps.sh
164
164
----
165
-
* To stop and remove docker compose containers, network and volumes, go to a terminal and, inside `springboot-elasticsearch-thymeleaf` root folder, run the following command
165
+
* To stop and remove docker compose containers, network and volumes, go to a terminal and, inside `springboot-elasticsearch-thymeleaf` root folder, run the following command:
166
166
+
167
167
[source]
168
168
----
@@ -171,7 +171,7 @@ docker compose down -v
171
171
172
172
== Cleanup
173
173
174
-
To remove the Docker images created by this project, go to a terminal and, inside `springboot-elasticsearch-thymeleaf` root folder, run the script below
174
+
To remove the Docker images created by this project, go to a terminal and, inside `springboot-elasticsearch-thymeleaf` root folder, run the script below:
0 commit comments