Skip to content

Commit 6dcad7d

Browse files
authored
fix getting started (#676)
1 parent d6b2c78 commit 6dcad7d

File tree

3 files changed

+45
-31
lines changed

3 files changed

+45
-31
lines changed

docs/modules/hbase/examples/getting_started/getting_started.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -122,14 +122,14 @@ kubectl rollout status --watch statefulset/simple-hbase-restserver-default --tim
122122
version() {
123123
# tag::cluster-version[]
124124
kubectl exec -n default simple-hbase-restserver-default-0 -- \
125-
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/version/cluster"
125+
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/version/cluster"
126126
# end::cluster-version[]
127127
}
128128

129129
echo "Check cluster version..."
130130
cluster_version=$(version | jq -r '.Version')
131131

132-
if [ "$cluster_version" == "2.6.2" ]; then
132+
if [ "$cluster_version" == "2.6.2-stackable0.0.0-dev" ]; then
133133
echo "Cluster version: $cluster_version"
134134
else
135135
echo "Unexpected version: $cluster_version"
@@ -139,26 +139,26 @@ fi
139139
echo "Check cluster status..."
140140
# tag::cluster-status[]
141141
kubectl exec -n default simple-hbase-restserver-default-0 \
142-
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/status/cluster" | json_pp
142+
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/status/cluster" | json_pp
143143
# end::cluster-status[]
144144

145145
echo "Check table via REST API..."
146146
# tag::create-table[]
147147
kubectl exec -n default simple-hbase-restserver-default-0 \
148148
-- curl -s -XPUT -H "Accept: text/xml" -H "Content-Type: text/xml" \
149-
"http://simple-hbase-restserver-default:8080/users/schema" \
149+
"http://simple-hbase-restserver-default-headless:8080/users/schema" \
150150
-d '<TableSchema name="users"><ColumnSchema name="cf" /></TableSchema>'
151151
# end::create-table[]
152152

153153
# tag::get-table[]
154154
kubectl exec -n default simple-hbase-restserver-default-0 \
155-
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/users/schema" | json_pp
155+
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/users/schema" | json_pp
156156
# end::get-table[]
157157

158158
get_all() {
159159
# tag::get-tables[]
160160
kubectl exec -n default simple-hbase-restserver-default-0 \
161-
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/" | json_pp
161+
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/" | json_pp
162162
# end::get-tables[]
163163
}
164164

docs/modules/hbase/examples/getting_started/getting_started.sh.j2

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -122,14 +122,14 @@ kubectl rollout status --watch statefulset/simple-hbase-restserver-default --tim
122122
version() {
123123
# tag::cluster-version[]
124124
kubectl exec -n default simple-hbase-restserver-default-0 -- \
125-
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/version/cluster"
125+
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/version/cluster"
126126
# end::cluster-version[]
127127
}
128128

129129
echo "Check cluster version..."
130130
cluster_version=$(version | jq -r '.Version')
131131

132-
if [ "$cluster_version" == "2.6.2" ]; then
132+
if [ "$cluster_version" == "2.6.2-stackable0.0.0-dev" ]; then
133133
echo "Cluster version: $cluster_version"
134134
else
135135
echo "Unexpected version: $cluster_version"
@@ -139,26 +139,26 @@ fi
139139
echo "Check cluster status..."
140140
# tag::cluster-status[]
141141
kubectl exec -n default simple-hbase-restserver-default-0 \
142-
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/status/cluster" | json_pp
142+
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/status/cluster" | json_pp
143143
# end::cluster-status[]
144144

145145
echo "Check table via REST API..."
146146
# tag::create-table[]
147147
kubectl exec -n default simple-hbase-restserver-default-0 \
148148
-- curl -s -XPUT -H "Accept: text/xml" -H "Content-Type: text/xml" \
149-
"http://simple-hbase-restserver-default:8080/users/schema" \
149+
"http://simple-hbase-restserver-default-headless:8080/users/schema" \
150150
-d '<TableSchema name="users"><ColumnSchema name="cf" /></TableSchema>'
151151
# end::create-table[]
152152

153153
# tag::get-table[]
154154
kubectl exec -n default simple-hbase-restserver-default-0 \
155-
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/users/schema" | json_pp
155+
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/users/schema" | json_pp
156156
# end::get-table[]
157157

158158
get_all() {
159159
# tag::get-tables[]
160160
kubectl exec -n default simple-hbase-restserver-default-0 \
161-
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/" | json_pp
161+
-- curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/" | json_pp
162162
# end::get-tables[]
163163
}
164164

docs/modules/hbase/pages/getting_started/first_steps.adoc

Lines changed: 33 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -102,31 +102,45 @@ which displays cluster metadata that looks like this (only the first region is i
102102
"Region" : [
103103
{
104104
"currentCompactedKVs" : 0,
105-
"memStoreSizeMB" : 0,
106-
"name" : "U1lTVEVNLkNBVEFMT0csLDE2NjExNjA0NDM2NjcuYmYwMzA1YmM4ZjFmOGIwZWMwYjhmMGNjMWI5N2RmMmUu",
107-
"readRequestsCount" : 104,
108-
"rootIndexSizeKB" : 1,
109-
"storefileIndexSizeKB" : 1,
110-
"storefileSizeMB" : 1,
111-
"storefiles" : 1,
112-
"stores" : 1,
105+
"memStoreSizeMB" : 1,
106+
"name" : "aGJhc2U6bWV0YSwsMQ==",
107+
"readRequestsCount" : 4,
108+
"rootIndexSizeKB" : 0,
109+
"storefileIndexSizeKB" : 0,
110+
"storefileSizeMB" : 0,
111+
"storefiles" : 0,
112+
"stores" : 3,
113113
"totalCompactingKVs" : 0,
114114
"totalStaticBloomSizeKB" : 0,
115-
"totalStaticIndexSizeKB" : 1,
116-
"writeRequestsCount" : 360
115+
"totalStaticIndexSizeKB" : 0,
116+
"writeRequestsCount" : 5
117117
},
118-
...
118+
{
119+
"currentCompactedKVs" : 0,
120+
"memStoreSizeMB" : 1,
121+
"name" : "aGJhc2U6bmFtZXNwYWNlLCwxNzUyNDk0MTQzMDQ0LjA1MTA1NWM1NzhhMDQyOWJmZTIwZTFkYTBiY2M4MWE3Lg==",
122+
"readRequestsCount" : 6,
123+
"rootIndexSizeKB" : 0,
124+
"storefileIndexSizeKB" : 0,
125+
"storefileSizeMB" : 0,
126+
"storefiles" : 0,
127+
"stores" : 1,
128+
"totalCompactingKVs" : 0,
129+
"totalStaticBloomSizeKB" : 0,
130+
"totalStaticIndexSizeKB" : 0,
131+
"writeRequestsCount" : 2
132+
}
119133
],
120-
"heapSizeMB" : 351,
121-
"maxHeapSizeMB" : 11978,
122-
"name" : "simple-hbase-regionserver-default-0.simple-hbase-regionserver-default.default.svc.cluster.local:16020",
123-
"requests" : 395,
124-
"startCode" : 1661156787704
134+
"heapSizeMB" : 108,
135+
"maxHeapSizeMB" : 2458,
136+
"name" : "simple-hbase-regionserver-default-0-listener.default.svc.cluster.local:16020",
137+
"requests" : 16,
138+
"startCode" : 1752494125463
125139
}
126140
],
127-
"averageLoad" : 43,
128-
"regions" : 43,
129-
"requests" : 1716
141+
"averageLoad" : 2,
142+
"regions" : 2,
143+
"requests" : 17
130144
}
131145

132146
You can now create a table like this:

0 commit comments

Comments
 (0)