You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2022/08/02 10:22:04 UTC

[GitHub] [dubbo-go] huangjun0124 opened a new issue, #2005: how to know if a Filter is running in Consumer or Provider?

huangjun0124 opened a new issue, #2005:
URL: https://github.com/apache/dubbo-go/issues/2005

   For a common Filter, how to know is it invoked as a Provider by other clients, or it is invoked as a consumer before calling to other service?
   For exmaple, below filter is configured both in provider and consumer in dubbo.yaml, how do i know which side i'm on when running?
   `myCommonFilter(ctx context.Context, invoker filter.Invoker, invocation filter.Invocation) filter.ServiceResult`


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-go] justxuewei commented on issue #2005: how to know if a Filter is running in Consumer or Provider?

Posted by GitBox <gi...@apache.org>.
justxuewei commented on issue #2005:
URL: https://github.com/apache/dubbo-go/issues/2005#issuecomment-1202340522

   The filter does not distinguish client and provider, and it only providers its own functionality. For example, if we want to encrypt data at client side, and decrypt data at server side, you should implement two filters, named "EncryptingFilter" and "DecryptFilter" respectively. The "EncryptingFilter" should be deployed on client side, and another should be deployed on server side. Note that neither "EncryptingFilter" nor "DecryptFilter" knows which side they are deployed on.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org