Correct grammer, misspellings and wording in the Docker chapter.

This commit is contained in:
John Blum
2020-06-05 08:56:31 -07:00
parent 9333f72850
commit 80c34d2198

View File

@@ -34,15 +34,14 @@ Let's get started.
[[geode-docker-image]]
=== Acquiring the {geode-name} Docker Image
To run an {geode-name} cluster inside a Docker Container you must first acquire the Docker Image.
To run an {geode-name} cluster inside a Docker Container you must first acquire the Docker Image. The {geode-name}
Docker Image can be acquired from https://hub.docker.com/r/apachegeode/geode/[Docker Hub].
While {geode-name}'s official {apache-geode-docs}[documentation] is less than clear on how to use {geode-name} in Docker,
we find a bit of relief in the {apache-geode-wiki}/How+to+use+Geode+on+Docker[Wiki]. However, for a complete write up,
please refer to the instructions in the https://github.com/markito/geode-docker#building-the-container-image[README]
we find a bit of relief in the {apache-geode-wiki}/How+to+use+Geode+on+Docker[Wiki]. However, for a complete and
comprehensive write up, please refer to the instructions in the https://github.com/markito/geode-docker#building-the-container-image[README]
from this https://github.com/markito/geode-docker[GitHub Repo].
The {geode-name} Docker Image can be acquired from https://hub.docker.com/r/apachegeode/geode/[Docker Hub].
NOTE: You must have {docker-docs-url}/get-docker[Docker] installed on your local system to complete the following steps.
Effectively, the high-level steps are as follows:
@@ -60,8 +59,8 @@ Status: Image is up to date for apachegeode/geode:latest
docker.io/apachegeode/geode:latest
----
Instead of pulling from the `nightly` TAG as suggested, the Spring Team highly recommends that you pull from the
`latest` TAG, which pulls a stable, production-grade {geode-name} Docker Image based on the latest {geode-name}
Instead of pulling from the `nightly` TAG as suggested, the Spring team highly recommends that you pull from the
`latest` TAG, which pulls a stable, production-ready {geode-name} Docker Image based on the latest {geode-name}
GA version.
2) Verify the {geode-name} Docker Image was downloaded and installed successfully:
@@ -82,8 +81,8 @@ Now, you are ready to run {geode-name} in a Docker Container.
[[geode-docker-container]]
=== Running {geode-name} in a Docker Container
Now that we have acquired the Docker Image, we can run {geode-name} in a Docker Container. Use the following
`docker run` command to start the {geode-name} Docker Container:
Now that we have acquired the {geode-name} Docker Image, we can run {geode-name} in a Docker Container. Use the
following `docker run` command to start {geode-name} in a Docker Container:
.Start the {geode-name} Docker Container
[source,text]
@@ -132,13 +131,13 @@ server-side, cluster processes, such as Locators and Cache Servers.
|===
It is unfortunate that the {geode-name} Docker Image only gives you a _Gfsh_ command prompt, leaving you to provision a
cluster. It would have been more useful to provide preconfigured Docker Images with different {geode-name} cluster
configurations, such as 1 Locator + 1 Server, or 2 Locators + 4 Servers, etc. But, no matter, we can start the cluster
ourselves.
It is unfortunate that the {geode-name} Docker Image only gives you a _Gfsh_ command prompt, leaving you with the task
of provisioning a cluster. It would have been more useful to provide preconfigured Docker Images with different
{geode-name} cluster configurations, such as 1 Locator + 1 Server, or 2 Locators + 4 Servers, etc. But, no matter, we
can start the cluster ourselves.
[[geode-docker-cluster]]
=== Run an {geode-name} Cluster
=== Start an {geode-name} Cluster in Docker
From inside the {geode-name} Docker Container we can start a Locator and a Server.
@@ -236,10 +235,10 @@ the configuration of the {geode-name} cluster running in the Docker Container as
Let's have a quick look at our Spring Boot application.
[[geode-docker-application]]
=== The Spring Boot, {geode-name} client application explained
=== Spring Boot, {geode-name} client application explained
The Spring Boot, {geode-name} `ClientCache` application we will use to connect to our {geode-name} cluster running in
the Docker Container, appears as follows:
the Docker Container appears as follows:
.Spring Boot, {geode-name} Docker client application
[source,java]
@@ -263,8 +262,7 @@ class Customer {
}
----
And, we define a Spring Data CRUD _Repository_ to persist and access `Customers` stored in {geode-name},
"/Customers" Region:
And, we define a Spring Data CRUD _Repository_ to persist and access `Customers` stored in the "/Customers" Region:
.`CustomerRepository` interface
[source,java]
@@ -288,18 +286,18 @@ on the `Customer` application domain model class, exists on the server(s) in the
We use the SDG `@EnableEntityDefinedRegions` annotation to define the matching, client `PROXY` "Customers" Region.
Optionally, we have also annotated our main class with SBDG's `@UseMemberName` annotation to give the `ClientCache`
a name, which will assert in the `assertClientCacheAndConfigureMappingPdxSerializer(:ClientCache)` method.
a name, which we assert in the `assertClientCacheAndConfigureMappingPdxSerializer(:ClientCache)` method.
The primary work performed by this application is done in the Spring Boot `ApplicationRunner` bean definition. We
essentially create a `Customer` instance, "Jon Doe", save "Jon Doe" to the "Customers" Region on the server(s) in
the cluster, and then query for "Jon Doe" using OQL, asserting that the result is equal to the expected.
essentially create a `Customer` instance, "Jon Doe", save "Jon Doe" to the "Customers" Region managed by the server(s)
in the cluster, and then query for "Jon Doe" using OQL, asserting that the result is equal to the expected.
We log the output from the application's operations to see the application in action.
[[geode-docker-application-run]]
=== Running the Spring Boot, {geode-name} client application
When you run the Spring Boot, {geode-name} client, application, you should see output similar to:
When you run the Spring Boot, {geode-name} client application, you should see output similar to:
.Application log output
[source,text]
@@ -348,7 +346,8 @@ Region | size | 1
----
Our "/Customers" Region contains a value, "Jon Doe", and we can verify this by running an OQL Query using _Gfsh_:
Our "/Customers" Region contains a value, "Jon Doe", and we can verify this by running the following OQL Query
with _Gfsh_:
.Query the "/Customers" Region
[source,text]