<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<h3 dir="auto">Environment</h3>
<ul dir="auto">
<li>Dubbo version: 2.7.4.1</li>
<li>Operating System version:Linux version 4.15.0-88-generic 16.04.1-Ubuntu</li>
<li>Java version: java version "1.8.0_201"</li>
</ul>
<h3 dir="auto">Steps to reproduce this issue</h3>
<ol dir="auto">
<li>invoke the remote method in consumer side.</li>
<li>always throw a exception in the method implementation of server side.</li>
<li>catch the exception in consumer side, and print stacktrace of the exception.</li>
</ol>
<h3 dir="auto">Expected Result</h3>
<p dir="auto">stacktrace of consumer side can not be obtained.</p>
<h3 dir="auto">Actual Result</h3>
<p dir="auto">only stacktrace of server side was printed, we can not find where we invoked the remote method.</p>
<p dir="auto">I have read related the code, it's in <code class="notranslate">org.apache.dubbo.rpc.AppResponse#recreate</code></p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="@Override
    public Object recreate() throws Throwable {
        if (exception != null) {
            // fix issue#619
            try {
                // get Throwable class
                Class clazz = exception.getClass();
                while (!clazz.getName().equals(Throwable.class.getName())) {
                    clazz = clazz.getSuperclass();
                }
                // get stackTrace value
                Field stackTraceField = clazz.getDeclaredField(&quot;stackTrace&quot;);
                stackTraceField.setAccessible(true);
                Object stackTrace = stackTraceField.get(exception);
                if (stackTrace == null) {
                    exception.setStackTrace(new StackTraceElement[0]);
                }
            } catch (Exception e) {
                // ignore
            }
            throw exception;
        }
        return result;
    }"><pre class="notranslate"><code class="notranslate">@Override
    public Object recreate() throws Throwable {
        if (exception != null) {
            // fix issue#619
            try {
                // get Throwable class
                Class clazz = exception.getClass();
                while (!clazz.getName().equals(Throwable.class.getName())) {
                    clazz = clazz.getSuperclass();
                }
                // get stackTrace value
                Field stackTraceField = clazz.getDeclaredField("stackTrace");
                stackTraceField.setAccessible(true);
                Object stackTrace = stackTraceField.get(exception);
                if (stackTrace == null) {
                    exception.setStackTrace(new StackTraceElement[0]);
                }
            } catch (Exception e) {
                // ignore
            }
            throw exception;
        }
        return result;
    }
</code></pre></div>
<p dir="auto">while recreating the result,  <code class="notranslate">AppResponse</code> only deserialize the exception of server side, so stacktrace of consumer side is ignored.<br>
maybe we can modify <code class="notranslate">throw exception</code> to <code class="notranslate">new RpcException(exception)</code>.</p>
<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<h3 dir="auto">Environment</h3>
<ul dir="auto">
<li>Dubbo version: 2.6.0</li>
<li>Operating System version: centos 6</li>
<li>Java version: jdk 1.8</li>
</ul>
<h3 dir="auto">Steps to reproduce this issue</h3>
<ol dir="auto">
<li>服务端dubbo 2.7 客户端使用2.6.0 由于集群原因升级到2.7之后zk的curator客户端会造成任务卡住，所以无法升级</li>
<li>ause: java.lang.NumberFormatException: For input string: ""<br>
java.lang.NumberFormatException: For input string: ""<br>
at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)<br>
at java.lang.Integer.parseInt(Integer.java:592)<br>
at java.lang.Integer.parseInt(Integer.java:615)<br>
at org.apache.dubbo.common.Version.parseInt(Version.java:128)<br>
at org.apache.dubbo.common.Version.getIntVersion(Version.java:113)<br>
at org.apache.dubbo.common.Version.isSupportResponseAttachment(Version.java:102)</li>
</ol>