Skip to content

fix(docs): Update getting-started script pre-25.7.0 #676

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions docs/modules/hbase/examples/getting_started/getting_started.sh
Original file line number Diff line number Diff line change
Expand Up @@ -122,14 +122,14 @@ kubectl rollout status --watch statefulset/simple-hbase-restserver-default --tim
version() {
# tag::cluster-version[]
kubectl exec -n default simple-hbase-restserver-default-0 -- \
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/version/cluster"
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/version/cluster"
# end::cluster-version[]
}

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

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

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

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

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

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,14 +122,14 @@ kubectl rollout status --watch statefulset/simple-hbase-restserver-default --tim
version() {
# tag::cluster-version[]
kubectl exec -n default simple-hbase-restserver-default-0 -- \
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default:8080/version/cluster"
curl -s -XGET -H "Accept: application/json" "http://simple-hbase-restserver-default-headless:8080/version/cluster"
# end::cluster-version[]
}

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

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

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

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

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

Expand Down
52 changes: 33 additions & 19 deletions docs/modules/hbase/pages/getting_started/first_steps.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -102,31 +102,45 @@ which displays cluster metadata that looks like this (only the first region is i
"Region" : [
{
"currentCompactedKVs" : 0,
"memStoreSizeMB" : 0,
"name" : "U1lTVEVNLkNBVEFMT0csLDE2NjExNjA0NDM2NjcuYmYwMzA1YmM4ZjFmOGIwZWMwYjhmMGNjMWI5N2RmMmUu",
"readRequestsCount" : 104,
"rootIndexSizeKB" : 1,
"storefileIndexSizeKB" : 1,
"storefileSizeMB" : 1,
"storefiles" : 1,
"stores" : 1,
"memStoreSizeMB" : 1,
"name" : "aGJhc2U6bWV0YSwsMQ==",
"readRequestsCount" : 4,
"rootIndexSizeKB" : 0,
"storefileIndexSizeKB" : 0,
"storefileSizeMB" : 0,
"storefiles" : 0,
"stores" : 3,
"totalCompactingKVs" : 0,
"totalStaticBloomSizeKB" : 0,
"totalStaticIndexSizeKB" : 1,
"writeRequestsCount" : 360
"totalStaticIndexSizeKB" : 0,
"writeRequestsCount" : 5
},
...
{
"currentCompactedKVs" : 0,
"memStoreSizeMB" : 1,
"name" : "aGJhc2U6bmFtZXNwYWNlLCwxNzUyNDk0MTQzMDQ0LjA1MTA1NWM1NzhhMDQyOWJmZTIwZTFkYTBiY2M4MWE3Lg==",
"readRequestsCount" : 6,
"rootIndexSizeKB" : 0,
"storefileIndexSizeKB" : 0,
"storefileSizeMB" : 0,
"storefiles" : 0,
"stores" : 1,
"totalCompactingKVs" : 0,
"totalStaticBloomSizeKB" : 0,
"totalStaticIndexSizeKB" : 0,
"writeRequestsCount" : 2
}
],
"heapSizeMB" : 351,
"maxHeapSizeMB" : 11978,
"name" : "simple-hbase-regionserver-default-0.simple-hbase-regionserver-default.default.svc.cluster.local:16020",
"requests" : 395,
"startCode" : 1661156787704
"heapSizeMB" : 108,
"maxHeapSizeMB" : 2458,
"name" : "simple-hbase-regionserver-default-0-listener.default.svc.cluster.local:16020",
"requests" : 16,
"startCode" : 1752494125463
}
],
"averageLoad" : 43,
"regions" : 43,
"requests" : 1716
"averageLoad" : 2,
"regions" : 2,
"requests" : 17
}

You can now create a table like this:
Expand Down