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

feat(api): support embedded arthas agent in hugegraph-server #2278

Merged
merged 18 commits into from
Oct 20, 2023

Conversation

SunnyBoy-WYH
Copy link
Contributor

@SunnyBoy-WYH SunnyBoy-WYH commented Aug 12, 2023

目的:增加 Arthas server 内嵌服务接口 (也就是说启动 HG Server 后可以直接使用 Arthas 动态观测/perf/debug, 无需单独安装)

流程:
image

好处:
1.一键启动Arthas后,可使用 Arthas 动态观测,无需单独安装
2.docker版本hugeGraph实现内嵌arthas

测试:
启动
image
http api方式与arthas交互
image

@SunnyBoy-WYH SunnyBoy-WYH changed the title Feat:server集成server feat:server内嵌集成Arthas Aug 12, 2023
@imbajin
Copy link
Member

imbajin commented Aug 12, 2023

also refer the contribution-doc in website to fix the 3rd-party info (fix ci problems)

@codecov
Copy link

codecov bot commented Aug 12, 2023

Codecov Report

Merging #2278 (f3f9d48) into master (30ef2f7) will increase coverage by 0.24%.
Report is 2 commits behind head on master.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##             master    #2278      +/-   ##
============================================
+ Coverage     64.70%   64.95%   +0.24%     
+ Complexity      989      987       -2     
============================================
  Files           501      505       +4     
  Lines         41601    41902     +301     
  Branches       5799     5817      +18     
============================================
+ Hits          26917    27216     +299     
+ Misses        12002    11994       -8     
- Partials       2682     2692      +10     
Files Coverage Δ
...ava/org/apache/hugegraph/api/arthas/ArthasAPI.java 100.00% <100.00%> (ø)
...ava/org/apache/hugegraph/config/ServerOptions.java 100.00% <100.00%> (ø)

... and 10 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@SunnyBoy-WYH SunnyBoy-WYH changed the title feat:server内嵌集成Arthas feat:hugegraph-server embedded arthas dependency Aug 13, 2023
@imbajin
Copy link
Member

imbajin commented Aug 16, 2023

also refer the contribution-doc in website to fix the 3rd-party info (fix ci problems)

we need handle the 3rd-party issues~

image

@imbajin imbajin changed the title feat:hugegraph-server embedded arthas dependency feat(api): support embedded arthas agent in hugegraph-server Aug 16, 2023
@SunnyBoy-WYH
Copy link
Contributor Author

also refer the contribution-doc in website to fix the 3rd-party info (fix ci problems)

we need handle the 3rd-party issues~

image

noted, thanks jin, i am learning how to solve it~

@imbajin
Copy link
Member

imbajin commented Aug 21, 2023

need handle the conflicts now. so as another PR
image

# Conflicts:
#	hugegraph-api/src/main/java/org/apache/hugegraph/config/ServerOptions.java
@imbajin
Copy link
Member

imbajin commented Aug 22, 2023

seems the PG CI always failed
image

@SunnyBoy-WYH
Copy link
Contributor Author

seems the PG CI always failed image

seems time exceeded?https://github.com/apache/incubator-hugegraph/actions/runs/5927042184?pr=2278
image

@imbajin
Copy link
Member

imbajin commented Aug 24, 2023

seems the PG CI always failed image

seems time exceeded?apache/incubator-hugegraph/actions/runs/5927042184?pr=2278 image

Could ignore RocksDB-Raft test, but it's strange that the PG tests always failed..

BTW, add the related doc in website-repo to help others know how to use it THX

@SunnyBoy-WYH
Copy link
Contributor Author

@imbajin

seems pass ci?

simon824
simon824 previously approved these changes Sep 5, 2023
Copy link
Member

@simon824 simon824 left a comment

Choose a reason for hiding this comment

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

Overall LGTM

public static final ConfigOption<String> ARTHAS_DISABLED_COMMANDS =
new ConfigOption<>(
"arthas.disabledCommands",
"arthas disabled commands",
Copy link
Contributor

Choose a reason for hiding this comment

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

could you please add more details for the description, since it will be as a guide for users.

@imbajin
Copy link
Member

imbajin commented Sep 20, 2023

BTW, remember to resolve the outdated conversation:
image

imbajin
imbajin previously approved these changes Sep 22, 2023
Copy link
Member

@imbajin imbajin left a comment

Choose a reason for hiding this comment

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

LGTM, Thanks for your contribution (remember add the related doc~)

javeme
javeme previously approved these changes Sep 22, 2023
@javeme
Copy link
Contributor

javeme commented Sep 23, 2023

please note the CI Error when Running org.apache.hugegraph.api.ApiTestSuite:
https://github.com/apache/incubator-hugegraph/actions/runs/6262763117/job/17047018545?pr=2278

@SunnyBoy-WYH
Copy link
Contributor Author

SunnyBoy-WYH commented Sep 23, 2023

please note the CI Error when Running org.apache.hugegraph.api.ApiTestSuite: https://github.com/apache/incubator-hugegraph/actions/runs/6262763117/job/17047018545?pr=2278

seems from rest-server.properties,but i am not changed configure item about auth?

image

java.lang.AssertionError: Response with status 500 and content {"exception":"class java.lang.IllegalStateException","message":"Unconfigured authenticator, please config auth.authenticator option in rest-server.properties","cause":""}
image

@javeme
Copy link
Contributor

javeme commented Sep 24, 2023

"Unconfigured authenticator, please config auth.authenticator option in rest-server.properties"

You need to enable auth feature to build the test environment if want to run tests locally.

@SunnyBoy-WYH
Copy link
Contributor Author

"Unconfigured authenticator, please config auth.authenticator option in rest-server.properties"

You need to enable auth feature to build the test environment if want to run tests locally.

"Unconfigured authenticator, please config auth.authenticator option in rest-server.properties"

You need to enable auth feature to build the test environment if want to run tests locally.

got it,thanks
but ci faild because apiTestSuite :

image

i run it local, seems all pass except userapi/loginapi
image

maybe we need debug mode for github ci?

@javeme
Copy link
Contributor

javeme commented Sep 30, 2023

we can log case name or something for every api test case by a @Before method

# Conflicts:
#	hugegraph-api/src/main/java/org/apache/hugegraph/config/ServerOptions.java
@SunnyBoy-WYH SunnyBoy-WYH dismissed stale reviews from javeme and imbajin via 8d11607 October 7, 2023 13:11
@javeme
Copy link
Contributor

javeme commented Oct 7, 2023

The ApiTestSuite still fails, there may be some package conflicts with jraft

@SunnyBoy-WYH
Copy link
Contributor Author

SunnyBoy-WYH commented Oct 15, 2023

Do we have any method to see some log abort the reason for backend-rocksdb raft test failure? i run locally with rocksdb but not found useful info

image
image

Copy link
Member

@imbajin imbajin left a comment

Choose a reason for hiding this comment

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

Seems could ignore raft-test? And it always failed now (should handle it separatly)

@SunnyBoy-WYH
Copy link
Contributor Author

handle

it's a common problem? i see 【rocksdb raft ci problem (critical, usually 360min+)】from hg tasks.

Copy link
Contributor

@javeme javeme left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants