我可以说这是连接泄漏吗?

发布于 2024-10-03 10:17:12 字数 761 浏览 3 评论 0原文

Web 服务器环境:Windows 2008 R2

数据库服务器环境:SQL Server 2008

背景:我想使用 sql profiler 来跟踪哪个连接导致连接泄漏。

我使用的 SQL Server Profiler 事件:

  1. 审核登录(列:EventSubClass、EventClass、EventSequence、SPID)
  2. 审核注销(列:EventSubClass、EventClass、EventSequence、SPID)
  3. PRC:Complete(列:TextData、EventSequence、SPID)

我发现了一个奇怪的日志记录记录,我猜测是连接泄漏,但不太确定,记录是:

SPID 65,

When Audit Login, EventSubClass is 2-pooled (meaning it is pooled connection) and EventSequence is 69354

When Audit Logout, EventSubClass is 1-non pooled (meaning it is non-pooled connection) and EventSequence is 69848 (from 69354 to 69848 meaning there are some other event logs)

Can I say that this connection isleaking?

先感谢您。

Web Server Environment : Windows 2008 R2

Database Server Environment : SQL Server 2008

Background : I want to use sql profiler to trace which connection cause connection leak.

SQL server Profiler events I used:

  1. Audit Login (columns : EventSubClass, EventClass, EventSequence, SPID)
  2. Audit Logout (columns : EventSubClass, EventClass, EventSequence, SPID)
  3. PRC:Complete (columns : TextData, EventSequence, SPID)

I found a weird logged record, I guess it is connection leak, but not very sure, the records are:

SPID 65,

When Audit Login, EventSubClass is 2-pooled (meaning it is pooled connection) and EventSequence is 69354

When Audit Logout, EventSubClass is 1-non pooled (meaning it is non-pooled connection) and EventSequence is 69848 (from 69354 to 69848 meaning there are some other event logs)

Can I say that this connection is leaking?

Thank you in advance.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

轻拂→两袖风尘 2024-10-10 10:17:12

池连接是在应用程序和数据库之间管理的连接。这意味着当您关闭连接时,中间管理器会收回连接,但保持其与数据库的打开状态。这意味着当您请求新连接时,可以比从头开始创建新连接更快、更高效。

A pooled connection is one that is being managed between your application and the database. It means when you close your connection, the intermediate manager takes the connection back, but keeps it open with the database. This means that when you request a new connection, it can be provided much more quickly and efficiently than creating a new one from scratch.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文