Skip to content
This repository has been archived by the owner on Jul 23, 2024. It is now read-only.

HAWQ-1276. The error message is not friendly when ranger plugin servi… #1088

Closed
wants to merge 3 commits into from

Conversation

stanlyxiang
Copy link
Member

…ce is unavailable.

@stanlyxiang
Copy link
Member Author

@@ -366,7 +365,7 @@ static size_t write_callback(char *contents, size_t size, size_t nitems,
if (curl->response.buffer == NULL)
{
/* out of memory! */
elog(WARNING, "not enough memory for Ranger response");
elog(WARNING, "cannot allocate memory for ranger response");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do you modify the out of memory error message. I think the original one is more specified, and may be better.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm, IMO , not enough memory is not the only error that will occur. There maybe other errors in the repalloc implementation. So I changed the messages.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So should the comment be consistent with the code?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure. fixed.

@interma
Copy link
Member

interma commented Jan 16, 2017

+1

Copy link
Contributor

@wcl14 wcl14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Copy link
Contributor

@ictmalili ictmalili left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. +1

@@ -294,7 +294,7 @@ static json_object *create_ranger_request_json(List *request_list, List *result_
break;
}
default:
elog(ERROR, "unrecognized objkind: %d", (int) kind);
elog(ERROR, "unrecognized object kind : %d", (int) kind);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since this is a message to users, we should map this "kind" to string, so that users can know which kind is not supported.

@stanlyxiang
Copy link
Member Author

merged into master. closed.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants