Thanks to visit codestin.com
Credit goes to github.com

Skip to content

gozero framework plugin support.#209

Closed
zjh129 wants to merge 1 commit intoapache:mainfrom
zjh129:main
Closed

gozero framework plugin support.#209
zjh129 wants to merge 1 commit intoapache:mainfrom
zjh129:main

Conversation

@zjh129
Copy link

@zjh129 zjh129 commented Oct 16, 2024

feat(go-zero): framework plugin support.

@wu-sheng
Copy link
Member

Please clean up your commits, rebase them to one commit.

@zjh129 zjh129 force-pushed the main branch 5 times, most recently from 2b2f063 to 45f0534 Compare October 17, 2024 02:58
@zjh129 zjh129 force-pushed the main branch 2 times, most recently from a117692 to ea11323 Compare October 17, 2024 06:55
Copy link
Contributor

@mrproliu mrproliu left a comment

Choose a reason for hiding this comment

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

There seem to be some license and style check issues, please fix them.

tags:
- { key: url, value: not null }
- { key: rpc.type, value: Unary }
- operationName: /user.User/UserFind
Copy link
Contributor

Choose a reason for hiding this comment

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

I think zrpc should be a framework similar to grpc, mainly used for communication between multiple processes, right? Then why is the RPC-related span still local? As I understand it, there should be entry and exit spans.

Copy link
Author

Choose a reason for hiding this comment

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

The method enhanced by zrpc is to add a unary interceptor. The underlying service is still a gRPC service. The purpose of adding this unary interceptor is to extend the RPC service provided by go-zero, such as logging parameters, responses, errors, etc. Currently, due to proxy restrictions, additional packages cannot be introduced, so the span can be considered local. Additionally, can you explain the issue of not being able to introduce additional packages in the interceptor? Otherwise, it will be impossible to complete some more distinctive tag reporting.

Copy link
Contributor

@mrproliu mrproliu Oct 18, 2024

Choose a reason for hiding this comment

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

For the additional package import, please read this document to know the implementation key principles. The short version is because the package import mechanism of golang compiler, we cannot add more package, that's why we have tools operator to let plugin do more operation without package import.

Copy link
Contributor

Choose a reason for hiding this comment

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

If all of spans still in one single segment(only create local rather entry and exit span), we cannot building the topology, because OAP don't know which one is exit span to communicate with other application.

Copy link
Contributor

Choose a reason for hiding this comment

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

Also, I cannot see any exit span by building grpc or zrpc, could you help to explain this?

- serviceName: gozero
segmentSize: ge 1
segments:
- segmentId: not null
Copy link
Contributor

Choose a reason for hiding this comment

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

Why is there just a single segment, if they are cross-process, it should have two segments. Please correct me if I'm wrong.

Copy link
Contributor

@mrproliu mrproliu left a comment

Choose a reason for hiding this comment

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

Please fix the CI problem.

tags:
- { key: url, value: not null }
- { key: rpc.type, value: Unary }
- operationName: /user.User/UserFind
Copy link
Contributor

Choose a reason for hiding this comment

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

Also, I cannot see any exit span by building grpc or zrpc, could you help to explain this?

@zjh129 zjh129 closed this Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request plugin

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants