Skip to content
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

refactor hgraph_params to solve static value leak #221

Merged
merged 1 commit into from
Dec 20, 2024

Conversation

LHT129
Copy link
Collaborator

@LHT129 LHT129 commented Dec 17, 2024

fixed: #222

@LHT129 LHT129 added the kind/improvement Code improvements (variable/function renaming, refactoring, etc. ) label Dec 17, 2024
@LHT129 LHT129 self-assigned this Dec 17, 2024
@LHT129 LHT129 added the kind/bug Something isn't working label Dec 17, 2024
@LHT129 LHT129 force-pushed the fix_leak branch 2 times, most recently from 1788206 to 8bab914 Compare December 18, 2024 03:04
{HGRAPH_GRAPH_MAX_DEGREE, {HGRAPH_GRAPH_KEY, GRAPH_PARAMS_KEY, GRAPH_PARAM_MAX_DEGREE}},
{HGRAPH_BUILD_EF_CONSTRUCTION, {BUILD_PARAMS_KEY, BUILD_EF_CONSTRUCTION}}};

static const std::string DEFAULT_HGRAPH_PARAMS_STR =
Copy link
Collaborator

Choose a reason for hiding this comment

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

DEFAULT_HGRAPH_PARAMS_STR -> HGRAPH_PARAMS_TEMPLATE ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

done

: common_param_(common_param) {
: common_param_(common_param),
default_hgraph_params_(format_map(DEFAULT_HGRAPH_PARAMS_STR, DEFAULT_MAP)),
hgraph_param_mapping_(EXTERNAL_MAPPING) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why need an EXTERNAL_MAPPING object copy ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

remove the value now.

@LHT129 LHT129 force-pushed the fix_leak branch 3 times, most recently from 1619268 to 6735e20 Compare December 18, 2024 10:35
Copy link
Collaborator

@jiaweizone jiaweizone 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
Collaborator

@jiaweizone jiaweizone left a comment

Choose a reason for hiding this comment

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

LGTM

Signed-off-by: LHT129 <tianlan.lht@antgroup.com>
Copy link
Collaborator

@inabao inabao left a comment

Choose a reason for hiding this comment

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

LGTM

@LHT129 LHT129 merged commit 22dccdb into antgroup:main Dec 20, 2024
7 checks passed
@LHT129 LHT129 deleted the fix_leak branch December 20, 2024 03:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working kind/improvement Code improvements (variable/function renaming, refactoring, etc. ) size/L
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Still have 2k memory leak after removing hgraph
3 participants