BUG: V9.0.1.3179 - Out-of-Memory Exception multiple times, SSMS did crazy things
PDinCA
Posts: 642 Silver 1
With the default of "Enable Code Analysis" checked, SQL Prompt causes SSMS OOM Exceptions, repeatedly.
The worst occurrence:
The log file appears to state, by this, "ERROR RedGate.SQLPrompt.CommonUI.Utils.ErrorDialog - Report error dialog UI shown", that the dialog to report an error to Red Gate using {sa} was active - not on top, it wasn't... and no evidence of it. (Windows 8.1).
SSMS is 17.3. I had about 14 tabs open (screen is very wide, and I can see all the tab headings). Connected to the usual Dev server, on which I had connected to 5 databases including master. This isn't at all unusual - I'm often connected to 3 or 4 instances, so 8 databases of prompt objects is more like my norm. I also explicitly set SSMS to use Large Memory, via "Large Address Aware.exe". Since doing that when 17.3 came out, I don't get OOM Exceptions until I've retrieved millions of result-set rows over the wire, which doesn't happen very often.
Did I change any Code Smells rules? Yes. I turned off ST008.
Enable Code Analysis is OFF! So far, so good...
Log file attached.
UPDATE: Dec 7th
Turned OFF for over a day and ZERO SSMS incidents. STRONGLY suggest this "feature" is delivered INACTIVE as a default.
The worst occurrence:
- Pasted a table-name in a tab that I'd been using for sp_blitzindex, and F5. It ran for the table I was expecting.
- I looked at another tab, which wasn't visible (i.e., it wasn't in another vertical group - all tabs were in the original group and no split-screen operations of any kind had or were in use). That tab showed TWO pastes of a 3-line comment from several minutes before. The tab had been saved, and it had only one comment block at save-time.
- Going back to the sp_blitzindex tab, the table name had reverted on its own
- Any subsequent attempt to activate a tab, or save anything, or anything at all did not get the typical Management Studio is Busy message - it was just completely unresponsive.
The log file appears to state, by this, "ERROR RedGate.SQLPrompt.CommonUI.Utils.ErrorDialog - Report error dialog UI shown", that the dialog to report an error to Red Gate using {sa} was active - not on top, it wasn't... and no evidence of it. (Windows 8.1).
SSMS is 17.3. I had about 14 tabs open (screen is very wide, and I can see all the tab headings). Connected to the usual Dev server, on which I had connected to 5 databases including master. This isn't at all unusual - I'm often connected to 3 or 4 instances, so 8 databases of prompt objects is more like my norm. I also explicitly set SSMS to use Large Memory, via "Large Address Aware.exe". Since doing that when 17.3 came out, I don't get OOM Exceptions until I've retrieved millions of result-set rows over the wire, which doesn't happen very often.
Did I change any Code Smells rules? Yes. I turned off ST008.
Enable Code Analysis is OFF! So far, so good...
Log file attached.
UPDATE: Dec 7th
Turned OFF for over a day and ZERO SSMS incidents. STRONGLY suggest this "feature" is delivered INACTIVE as a default.
Jesus Christ: Lunatic, liar or Lord?
Decide wisely...
Decide wisely...
Tagged:
Answers
Thanks for getting in touch. We're really sorry to hear that out of memory exceptions stopped you using code analysis. We are trying to improve code analysis and your feedback is really valuable.
I can see from the log file you uploaded that you are using SQL Prompt 9.0.1.3179. That version already had some improvements to issues around out of memory, however it doesn't look like it was enough to handle your scripts/connections.
Do you have other SSMS plugins installed?
How large are your tabs? What is the size of C:\Users\<USERNAME>\AppData\Local\Red Gate\SQL Prompt 9\SavedTabs.db?
Best,
Michael
Technical Lead, SQL Monitor
Thanks for the reply.
db is at 87.7MB, and includes an 11M row resultset as I write.
Other plug-ins, yes, and have had them for almost as long as SQP: ApexSQL Refactor, SentryOne Plan Explorer.
Our database object size may be considered to be on the large size, and with each connection, master is a given, but usually one of these large databases is retrieved for SQP. Raw SELECT COUNT(*) from sys.objects gives 26,237; columns is 52,855; sysconstraints is 11,104, if that's any kind of guide.
I have "Manual Refresh" on, BTW.
Happy to give you any other stats, logs, etc.
I'm now on 9.0.2.3223
Decide wisely...
I'm trying to reproduce this and while I haven't gotten SSMS to actually crash yet, from some testing it seems that Code Analysis may add less overhead in the latest version, v9.0.4.3408- while I continue testing, can you kindly update to this version to confirm that the issue is still present there for you?
Jessica Ramos | Product Support Engineer | Redgate Software
Have you visited our Help Center?
Decide wisely...
Can I just check something - would you be willing to re-enable it one more time and disable Options->Text Editor->Transact-SQL->Intellisense, to see if the problems persist? (the native Intellisense has clashed with Prompt in the past due to excessive memory usage, and we've just had another case where disabling it helped)
Jessica Ramos | Product Support Engineer | Redgate Software
Have you visited our Help Center?
Sorry to disappoint, but it will be a few weeks (the issues are MANY!)
Decide wisely...
One of the releases since you first posted (v9.0.8.3873 on Jan 31st, 2018) addressed some Code Analysis issues- it supports larger scripts without freezing the SSMS/VS UI, by only showing the first 50,000 issues of code analysis- so it's unfortunate that hasn't helped!
I am curious to see if disabling Intellisense has any effect- please do let us know once you have a chance to test.
Jessica Ramos | Product Support Engineer | Redgate Software
Have you visited our Help Center?