Skip to content

Commit

Permalink
HDDS-11848. Serialization bug in Recon listKeys API (apache#7524)
Browse files Browse the repository at this point in the history
  • Loading branch information
siddhantsangwan authored Dec 4, 2024
1 parent faab1e8 commit d66c088
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions hadoop-ozone/dist/src/main/smoketest/recon/recon-api.robot
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ ${API_ENDPOINT_URL} ${ENDPOINT_URL}/api/v1
${ADMIN_API_ENDPOINT_URL} ${API_ENDPOINT_URL}/containers
${UNHEALTHY_ENDPOINT_URL} ${API_ENDPOINT_URL}/containers/unhealthy
${NON_ADMIN_API_ENDPOINT_URL} ${API_ENDPOINT_URL}/clusterState
${VOLUME} vol1
${BUCKET} bucket1

*** Keywords ***
Check if Recon picks up container from OM
Expand Down Expand Up @@ -57,6 +59,15 @@ Check http return code
Should contain ${result} 200
END

Check if the listKeys api responds OK
[Arguments] ${volume} ${bucket}
Run Keyword if '${SECURITY_ENABLED}' == 'true' Kinit as ozone admin
${result} = Execute curl --negotiate -u : -LSs ${API_ENDPOINT_URL}/keys/listKeys?startPrefix=/${volume}/${bucket}&limit=1000
Should contain ${result} "OK"
Should contain ${result} "keys"
Should contain ${result} "${volume}"
Should contain ${result} "${bucket}"

*** Test Cases ***
Check if Recon picks up OM data
Execute ozone sh volume create recon
Expand All @@ -67,6 +78,7 @@ Check if Recon picks up OM data
Execute ozone sh bucket create recon/api --layout=LEGACY
Freon OCKG n=10 args=-s 1025 -v recon -b api
Wait Until Keyword Succeeds 90sec 10sec Check if Recon picks up container from OM
Wait Until Keyword Succeeds 90sec 10sec Check if the listKeys api responds OK recon api

Check if Recon picks up DN heartbeats
${result} = Execute curl --negotiate -u : -LSs ${API_ENDPOINT_URL}/datanodes
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ public long getModificationTime() {
}

@JsonProperty("isKey")
public boolean isKey() {
public boolean getIsKey() {
return keyInfoProto.getIsFile();
}

Expand Down

0 comments on commit d66c088

Please sign in to comment.