草庐IT

report_callback_exception

全部标签

.net - 如何优雅地关闭 TCP 连接而无一异常(exception)?

模式是什么和/或您将如何更改以下代码,以便可以从服务器或客户端优雅地关闭连接,而无需异常处理。TcpClient与套接字:我不局限于使用TcpClient客户端类。我写了以下内容代码来尝试演示最简单的情况可能。我曾使用Socket和SocketAsyncEventArgs但事情变得太复杂的处理这个问题。阻塞与异步:因为阻止调用这可能很困难或不可能。如果是这样,那很好,但是你是怎么解决的异步情况?QuitToken?:我尝试过向另一方发送某种“Quit”token,以便它知道要关闭,但还没有让它工作,我想在这里展示一个最小的例子。无论如何都需要异常处理:我知道在真实应用程序中异常处理是必

java - 骡子 ESB 3.4.0 CE : Redeliver message through TCP Endpoint upon Socket Exception

我有一个需要持久TCP连接的应用程序。所以我在Tcp连接器上设置了一些适当的属性来支持它。我遇到的问题是,如果外部应用程序关闭并重新启动,Mule将继续尝试将消息发送到套接字,而不是尝试重新建立连接。这是我的错误日志:ERROR2014-04-3017:11:35,436[[chatroomexample].connector.VM.mule.default.receiver.04]org.mule.exception.DefaultMessagingExceptionStrategy:**************************************************

Android Gradle 项目升级构建工具到 21.0.1 : aapt throws Exception

我们有一个androidgradle项目。今天想把androidbuildtools版本从20升级到21.0.1,但是现在aapt失败了。*Whatwentwrong:Executionfailedfortask':myproject-android:processDebugResources'.>com.android.ide.common.internal.LoggedErrorException:Failedtoruncommand:c:\_DEVELOP\AndroidSDK\sdk\build-tools\21.0.1\aapt.exepackage-f--no-crunch

Android Gradle 项目升级构建工具到 21.0.1 : aapt throws Exception

我们有一个androidgradle项目。今天想把androidbuildtools版本从20升级到21.0.1,但是现在aapt失败了。*Whatwentwrong:Executionfailedfortask':myproject-android:processDebugResources'.>com.android.ide.common.internal.LoggedErrorException:Failedtoruncommand:c:\_DEVELOP\AndroidSDK\sdk\build-tools\21.0.1\aapt.exepackage-f--no-crunch

c - libnids 样本中从未调用过 tcp_callback

我正致力于从pcap文件中提取http数据。我必须重新组装片段,所以我找到了nidslib。我在Macos10.9.564位中安装了带有自制软件的libnids1.24。我尝试运行printallsample.我稍微修改了代码以适应我的环境,例如将“nids.h”更改为,添加nids_params.filename=filename;打开脱机文件进行分析。样本可以开始了。但问题是它什么都不打印。我将print添加到tcp_callback函数的第一行。再一次,什么都没有。这表明回调从未被调用。证明问题与我的cap文件无关我将其设置为捕获实时数据包。打开网页后,我什么也得不到。我自己用l

java - Haproxy + 网络 : Way to prevent exceptions on connection reset?

我们在运行netty-3.6的后端前使用haproxy。我们正在处理大量的连接,其中一些可能是长期存在的。现在的问题是,当haproxy关闭连接以重新平衡时,它通过发送tcp-RST来实现。当netty使用的sun.nio.ch-class看到这一点时,它会抛出一个IOException:“Connectionresetbypeer”。跟踪:sun.nio.ch.FileDispatcherImpl.read0(NativeMethod):1in""sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:39):1in""sun.n

SwiftLint Rule for Braces 在下一行,但有一些异常(exception)

我想修改.swiftlint.yml以添加一些自定义规则以在下一行强制执行大括号。这对我有用......opening_braces:name:"OpeningBracesnotonNextLine"message:"Openingbracesshouldbeplacedonthenextline."include:"*.swift"regex:'\S[\t]*\{'severity:warning但是在某些情况下我希望在同一行上允许大括号,例如像这样:overridevarcornerRadius:CGFloat{get{returnlayer.cornerRadius}set{la

ios - (Swift) 将按钮移动到有异常(exception)的随机位置

我正在尝试将标签移动到一个随机位置,我已经能够使用此代码做到这一点。letbuttonWidth=self.samea.frame.widthletbuttonHeight=self.samea.frame.height//FindthewidthandheightoftheenclosingviewletviewWidth=self.samea.superview!.bounds.widthletviewHeight=self.samea.superview!.bounds.height//Computewidthandheightoftheareatocontainthebutto

swift - 2 个域异常(exception)的 NSAppTransportSecurity

因为我的域没有SSL证书atm,所以我使用NSExceptionDomains来允许域加载。我在Info.plist中使用以下代码来允许域及其子域NSAppTransportSecurityNSExceptionDomainsinfever.comNSIncludesSubdomainsNSTemporaryExceptionAllowsInsecureHTTPLoads但是,这次我想通过2个域,因为应用程序的某些部分来自不同的域。我试着像这样添加另一个键:NSAppTransportSecurityNSExceptionDomainsinfever.comgentsgroup.com

ios - EXC_SOFTWARE/UNCAUGHT_NS_EXCEPTION

我的生活应用程序发生崩溃,我无法在我的设备上重现。我一直无法弄清楚是什么原因造成的。我研究了崩溃报告,但似乎无法理解造成这种情况的原因。1CoreFoundation__exceptionPreprocess+12415362libobjc.A.dylibobjc_exception_throw+341363CoreFoundation-[NSObject(NSObject)doesNotRecognizeSelector:]+12703884CoreFoundation___forwarding___+12581005CoreFoundation_CF_forwarding_prep