DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Thu, 19 Jul 2007 16:32:03 -0700,    posted on: microsoft.public.dotnet.framework.adonet        back       

Thread Index
  1    Seen The Bean


SqlDependency.Start - Getting intermittent KeyNotFoundException   
I'm working heavily with query notifications in SQL Server 2005 and I 
intermittently get the following exception:

System.Collections.Generic.KeyNotFoundException: The given key was not 
present in the dictionary.

No one on the Internet seems to have ever encountered this.

A partial stack trace appears below.  It's partial in that I've ommitted a 
long set of calls from our interal app framework that are orthogonal to the 
problem.

The NT user making these calls is a local administrator on the database 
server.  The calls work a lot of the time, but break and seemingly random 
moments.

We use a preconfigured SQL Server Service Broker Queue named 
QueryChangeMessages and a service called QueryChangeNotifications.

Please help.

Server stack trace: 
   at System.ThrowHelper.ThrowKeyNotFoundException()
   at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
   at 
SqlDependencyProcessDispatcher.SqlConnectionContainer.ProcessNotificationResults(SqlDataReader reader)
   at 
SqlDependencyProcessDispatcher.SqlConnectionContainer.SynchronouslyQueryServiceBrokerQueue()
   at 
SqlDependencyProcessDispatcher.SqlConnectionContainer..ctor(SqlConnectionContainerHashHelper hashHelper, String appDomainKey, Boolean useDefaults)
   at SqlDependencyProcessDispatcher.Start(String connectionString, String& 
server, DbConnectionPoolIdentity& identity, String& user, String& database, 
String& queueService, String appDomainKey, 
SqlDependencyPerAppDomainDispatcher dispatcher, Boolean& errorOccurred, 
Boolean& appDomainStart, Boolean useDefaults)
   at SqlDependencyProcessDispatcher.Start(String connectionString, String 
queue, String appDomainKey, SqlDependencyPerAppDomainDispatcher dispatcher)
   at 
System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr 
md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, 
Object[]& outArgs)
   at 
System.Runtime.Remoting.Messaging.StackBuilderSink.PrivateProcessMessage(RuntimeMethodHandle 
md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, 
Object[]& outArgs)
   at 
System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg, Int32 methodPtr, Boolean fExecuteInContext)

Exception rethrown at [0]: 
   at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage 
reqMsg, IMessage retMsg)
   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& 
msgData, Int32 type)
   at SqlDependencyProcessDispatcher.Start(String connectionString, String 
queue, String appDomainKey, SqlDependencyPerAppDomainDispatcher dispatcher)
   at System.Data.SqlClient.SqlDependency.Start(String connectionString, 
String queue, Boolean useDefaults)
   at System.Data.SqlClient.SqlDependency.Start(String connectionString, 
String queue)
Date:Thu, 19 Jul 2007 16:32:03 -0700   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us