You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "code4wt (GitHub)" <gi...@apache.org> on 2018/11/07 14:18:45 UTC

[GitHub] [incubator-dubbo] code4wt opened pull request #2754: Fix the bug that ReferenceBean refers service more than once when debugging.

## What is the purpose of the change

Fix the bug that ReferenceBean refers service more than once when debugging.
please visit http://t.cn/EAhta27 for more detail

## Brief changelog

dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/AbstractConfig.java

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org


[GitHub] [incubator-dubbo] beiwei30 closed pull request #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "beiwei30 (GitHub)" <gi...@apache.org>.
[ pull request closed by beiwei30 ]

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org


[GitHub] [incubator-dubbo] code4wt commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "code4wt (GitHub)" <gi...@apache.org>.
Hi @zonghaishang. 我觉得你的方法可以解决二次引用服务的问题。但是这个只能规避问题,但是无法完全解决问题。原因如下:
1. 大部分开发者会使用 IDEA 的默认配置,这个问题仍然会出现(这个问题再 Eclipse 下也可以复现)
2. 这个本身是个小问题,但是却会引起让人诧异的问题,问题的根源是 Dubbo 打印的不该打印的信息。我们不能告诉框架使用者说,请设置xxx规避这个问题。
3.就如 @carryxyh  所说的,object=xxx 是无意义信息,不应该打印出来

所以,综上所述,我觉得应该修复一下这个问题,而不是规避。

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org

[GitHub] [incubator-dubbo] code4wt commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "code4wt (GitHub)" <gi...@apache.org>.
> @code4wt
> 把这个pr也提交到2.6.x分支吧,谢谢。

已经提交 #2759 

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org

[GitHub] [incubator-dubbo] cvictory commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "cvictory (GitHub)" <gi...@apache.org>.
This issue happened on debug mode in intellij idea.

This optimize can make toString better.

yì jí <no...@github.com> 于2018年11月8日周四 上午10:51写道:

> em...
>
> please just set Intellij idea -> Preferences ->
> Build,Execution,Deployment -> Debugger -> DataViews -> Java, uncheck Enable
> toString() object view.
>
> [image: image]
> <https://user-images.githubusercontent.com/15549777/48174734-171f2b00-e344-11e8-8600-765f637fdd4c.png>
>
> I don't think that's a problem, because in debug mode it triggers the
> toString itself
>
> —
> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/incubator-dubbo/pull/2754#issuecomment-436854995>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AD5mbB36FBg1LCyjIH08jcsVVqzMu-mEks5us5w6gaJpZM4YSg4U>
> .
>


-- 

Best Regard!
cvitory


[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org

[GitHub] [incubator-dubbo] beiwei30 commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "beiwei30 (GitHub)" <gi...@apache.org>.
I agree with @carryxyh, and have merged this PR proposed from @code4wt. It is helpful for dev experience.

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org


[GitHub] [incubator-dubbo] carryxyh commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "carryxyh (GitHub)" <gi...@apache.org>.
@zonghaishang 
我倒是觉得他的修改方式是可以的,bug可能算不上,这个问题并不会导致程序出现不符合预期的结果,但是作为一个优化是不错的。
目前toString方法中会打印  object='xxxx' 一个代理对象这种信息,但是其实这个对象的信息是没有什么意义的。
你认为呢? :)

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org

[GitHub] [incubator-dubbo] beiwei30 commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "beiwei30 (GitHub)" <gi...@apache.org>.
I agree with @carryxyh, and have merged this PR proposed from @code4wt. It is helpful for DEV experience.

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org


[GitHub] [incubator-dubbo] zonghaishang commented on issue #2754: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "zonghaishang (GitHub)" <gi...@apache.org>.
em...

please just set `Intellij idea -> Preferences -> Build,Execution,Deployment -> Debugger -> DataViews -> Java`, uncheck `Enable toString() object view`.

![image](https://user-images.githubusercontent.com/15549777/48174734-171f2b00-e344-11e8-8600-765f637fdd4c.png)

I don't think that's a problem, because in debug mode it triggers the toString itself


[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org


[GitHub] [incubator-dubbo] beiwei30 commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "beiwei30 (GitHub)" <gi...@apache.org>.
I agree with @carryxyh, and have merged this PR proposed from @code4wt 

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org


[GitHub] [incubator-dubbo] code4wt commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "code4wt (GitHub)" <gi...@apache.org>.
Hi @zonghaishang. 我觉得你的方法可以解决二次引用服务的问题。但是这样做只能规避问题,无法完全解决问题。原因如下:
1. 大部分开发者会使用 IDEA 的默认配置,这个问题仍然会出现(这个问题在 Eclipse 下也可以复现)
2. 这个本身是个小问题,但是却会造成让人诧异的结果。我们不能告诉框架使用者说,请设置xxx规避这个问题。
3. 就如 @carryxyh  所说的,object=xxx 是无意义信息,不应该打印出来

所以,综上所述,我觉得应该修复一下这个问题。

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org

[GitHub] [incubator-dubbo] carryxyh commented on issue #2754: [DUBBO-2757]: Fix the bug that ReferenceBean refers service more than once when debugging.

Posted by "carryxyh (GitHub)" <gi...@apache.org>.
@code4wt 
把这个pr也提交到2.6.x分支吧,谢谢。

[ Full content available at: https://github.com/apache/incubator-dubbo/pull/2754 ]
This message was relayed via gitbox.apache.org for notifications@dubbo.apache.org