<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/incubator-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/incubator-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.1</li>
<li>Operating System version: macbook 10.14.3</li>
<li>Java version: 1.7</li>
</ul>
<h3 dir="auto">Steps to reproduce this issue</h3>
<p dir="auto">这个问题依然存在，2.7.1，spring:UNKOWN<br>
// [Issue] SpringStatusChecker execute errors on non-XML Spring configuration // issue : <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="418205619" data-permission-text="Title is private" data-url="https://github.com/apache/dubbo/issues/3615" data-hovercard-type="issue" data-hovercard-url="/apache/dubbo/issues/3615/hovercard" href="https://github.com/apache/dubbo/issues/3615">#3615</a> if(c instanceof GenericWebApplicationContext) { // ignore GenericXmlApplicationContext continue; }<br>
c是一个GenericWebApplicationContext但被忽略了，右侧的注释是说忽略GenericXmlApplicationContext？</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.7.7</li>
<li>Operating System version: macOs Mojave 10.14.5</li>
<li>Java version: 1.8</li>
</ul>
<h3 dir="auto">Steps to reproduce this issue</h3>
<ol dir="auto">
<li>使用dubbo启动一个任意grpc Provider进程</li>
<li>关闭进程</li>
</ol>
<h3 dir="auto">Expected Result</h3>
<p dir="auto">进程正常关闭，资源回收，无任何异常</p>
<h3 dir="auto">Actual Result</h3>
<p dir="auto">有NullPointerException报出</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="java.lang.NullPointerException: null
	at org.apache.dubbo.rpc.protocol.grpc.DubboHandlerRegistry.removeService(DubboHandlerRegistry.java:66) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.rpc.protocol.grpc.GrpcProtocol.lambda$doExport$1(GrpcProtocol.java:97) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.rpc.protocol.AbstractProxyProtocol$1.unexport(AbstractProxyProtocol.java:95) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.rpc.listener.ListenerExporterWrapper.unexport(ListenerExporterWrapper.java:71) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.ServiceConfig.unexport(ServiceConfig.java:170) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.lambda$unexportServices$17(DubboBootstrap.java:952) [dubbo-2.7.7.jar:2.7.7]
	at java.util.ArrayList.forEach(ArrayList.java:1257) ~[na:1.8.0_231]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.unexportServices(DubboBootstrap.java:950) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.destroy(DubboBootstrap.java:1072) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap$1.callback(DubboBootstrap.java:193) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.common.function.ThrowableAction.execute(ThrowableAction.java:46) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.common.lang.ShutdownHookCallbacks.lambda$callback$0(ShutdownHookCallbacks.java:70) ~[dubbo-2.7.7.jar:2.7.7]
	at java.lang.Iterable.forEach(Iterable.java:75) ~[na:1.8.0_231]
	at org.apache.dubbo.common.lang.ShutdownHookCallbacks.callback(ShutdownHookCallbacks.java:70) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.DubboShutdownHook.callback(DubboShutdownHook.java:85) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.DubboShutdownHook.run(DubboShutdownHook.java:73) ~[dubbo-2.7.7.jar:2.7.7]
"><pre class="notranslate"><code class="notranslate">java.lang.NullPointerException: null
	at org.apache.dubbo.rpc.protocol.grpc.DubboHandlerRegistry.removeService(DubboHandlerRegistry.java:66) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.rpc.protocol.grpc.GrpcProtocol.lambda$doExport$1(GrpcProtocol.java:97) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.rpc.protocol.AbstractProxyProtocol$1.unexport(AbstractProxyProtocol.java:95) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.rpc.listener.ListenerExporterWrapper.unexport(ListenerExporterWrapper.java:71) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.ServiceConfig.unexport(ServiceConfig.java:170) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.lambda$unexportServices$17(DubboBootstrap.java:952) [dubbo-2.7.7.jar:2.7.7]
	at java.util.ArrayList.forEach(ArrayList.java:1257) ~[na:1.8.0_231]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.unexportServices(DubboBootstrap.java:950) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap.destroy(DubboBootstrap.java:1072) [dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.bootstrap.DubboBootstrap$1.callback(DubboBootstrap.java:193) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.common.function.ThrowableAction.execute(ThrowableAction.java:46) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.common.lang.ShutdownHookCallbacks.lambda$callback$0(ShutdownHookCallbacks.java:70) ~[dubbo-2.7.7.jar:2.7.7]
	at java.lang.Iterable.forEach(Iterable.java:75) ~[na:1.8.0_231]
	at org.apache.dubbo.common.lang.ShutdownHookCallbacks.callback(ShutdownHookCallbacks.java:70) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.DubboShutdownHook.callback(DubboShutdownHook.java:85) ~[dubbo-2.7.7.jar:2.7.7]
	at org.apache.dubbo.config.DubboShutdownHook.run(DubboShutdownHook.java:73) ~[dubbo-2.7.7.jar:2.7.7]

</code></pre></div>