Quantcast
Channel: User Phil Sandler - Stack Overflow
Browsing latest articles
Browse All 43 View Live

Comment by Phil Sandler on NLog - how to configure to conditionally write to...

@user13116244 I'm sorry--I'm not sure I understand your question. I don't think there is any relationship or dependency between FallBackGroup and throwExceptions. ThrowExceptions=true means that a...

View Article



Comment by Phil Sandler on How to troubleshoot Azure SQL Database performance...

In your edit: your two queries are not remotely equivalent. The first is forcing an INNER JOIN, not a LEFT JOIN.

View Article

Comment by Phil Sandler on Distribute events over the network

If you are recommending a product in your answer, and especially if you are claiming it's only one of two reasonable options, you should absolutely disclose any relationship you have to that product....

View Article

Comment by Phil Sandler on How to fix this error: Msg 50000, Level 17, State...

Show the stored procedure code. This is very likely a custom error.

View Article

Comment by Phil Sandler on why Implementing request/response pattern is not...

My answer explains why it's not recommended--it's much more complicated to try to do request/response using a queue/stream. It's just not designed for that purpose. Also, when you say "why .net core...

View Article


Comment by Phil Sandler on Convert Working Postman Request to C# (HttpClient)

@ESG I considered redirects--I have turned off "Automatically follow redirects" in Postman and still get a success response (200).

View Article

Comment by Phil Sandler on HttpClient (C#) Intercept Unauthorized (401) and...

That question/answer is for .Net Core 2.x. Using a modified version of the the answer's code, redirecting still gives me the same error.

View Article

Comment by Phil Sandler on HttpClient (C#) Intercept Unauthorized (401) and...

Looks like this is going to work! Thanks for your help.

View Article


Comment by Phil Sandler on EF 6 SqlConnection does not support parallel...

Doesn't look like you've said anywhere which line of code it fails on. Does it fail when you start the transaction? When the query tries to run? When the method completes and the transaction goes out...

View Article


Comment by Phil Sandler on Contiguous Gaps and Islands with Integers and...

"This won't work if you have very overlapping things that cross multiple groups boundaries, but if they don't, then you're good to go." I think this is possible. I'll find out and update the question...

View Article

Comment by Phil Sandler on Contiguous Gaps and Islands with Integers and...

I've updated the question.

View Article

Answer by Phil Sandler for Seeding microservices databases

There are two hard things in Computer Science, and one of them is cache invalidation.Solution 2 is absolutely my default position, and you should generally only consider implementing caching if you run...

View Article

Answer by Phil Sandler for LLBLGen load a distinct item by fields that are...

You can also fetch by unique...

View Article


Answer by Phil Sandler for Grouping by last day of each month—inefficient...

Your absolute first step should be to view the execution plan for the query and determine why the query is slow.The following explains how to see a graphical execution plan:Display an Actual Execution...

View Article

Answer by Phil Sandler for What is the correct usage for persistence using...

Yes, this is totally fine. The first line:endpointConfiguration.UsePersistence<NHibernatePersistence>();sets the persistence for all storage types to NHibernate. The subsequent lines "override"...

View Article


Answer by Phil Sandler for C# Continuous Ping

Put this line:bool boCheckbox = cbContinuousPing.Checked;inside your while loop.

View Article

Answer by Phil Sandler for In microservices, should a data be store in one...

In general, I recommend that you don't cache/duplicate data unless you have a reason to. Cache invalidation is considered one of the two hard thing in Computer Science. Having downstream services...

View Article


Answer by Phil Sandler for Is there a way to keep messages somewhere in...

I have used RabbitMQ, but am not an expert, so can't answer that aspect of your question.However, what you are considering is very likely a bad idea. If you are using RabbitMQ as a queue, you should be...

View Article

Answer by Phil Sandler for Generic DBContext Injection with Autofac

I don't think this has anything to do with dependency injection or autofac. Look at the stack trace--the top of the trace says:at...

View Article

Answer by Phil Sandler for Is there an allowed maximum number of AddTransient...

You very likely have a circular dependency. Examine the new class you are trying to register and review its dependencies. Better yet, remove all its dependencies temporarily and try again to register.

View Article

Answer by Phil Sandler for SqlException: The INSERT statement conflicted with...

I don't see in the cshtml where you would be setting CategoryId, which means it is likely getting set to 0, which would cause a foreign key constraint violation.Set a breakpoint in your controller code...

View Article


Answer by Phil Sandler for Moq - Mock DbSet.AddAsync throws no invocations...

You declare and setup _mockArtistDbSet, but you don't use/attach it to the _mockContext. I think you need to add something like:_mockContext.Setup(m => m.Artist).Returns(_mockArtistDbSet.Object);

View Article


MSBuild Using Wrong Version of Assembly to Compile RDLC File

I am using the reportviewer control from VS 2010 to create client side reports (rdlc). Everything is working fine on my development machine, and when I manually compile (via VS2010) and manually deploy...

View Article

Json.Net Deserialization Constructor vs. Property Rules

I was troubleshooting a (de)serialization issue with the following class using Json.Net:public class CoinsWithdrawn{ public DateTimeOffset WithdrawlDate { get; private set; } public...

View Article

Answer by Phil Sandler for How does this NOT IN in a Having statement in...

If either SUM equals 99 or -99, filter that (aggregated) row out.It may make more sense if you add the SUM values to your SELECT list if they are not there already, and then (temporarily) reverse the...

View Article


Answer by Phil Sandler for Distribute events over the network

You are correct that sharing the database between services would violate the principles of SOA and thus the principles of Microservices. Surprising that they suggest this in their documentation.Here is...

View Article

C# Libraries for CouchDB? [closed]

I haven't seen the question asked/answered for over a year, and I'm sure there have a been a lot of changes in that time.If you are using CouchDB in a .Net/C# environment (in production), I'd like to...

View Article

Detecting/Diagnosing Thread Starvation

I am doing some performance/scalability testing of an IIS application that occasionally seems to slow down to a crawl in production. I'm able to reproduce the slowness consistently using NUnit. CPU and...

View Article

Image may be NSFW.
Clik here to view.

Answer by Phil Sandler for Problem with DTD error - some xml method does not...

I was finally able to find a solution to this problem. The question originally didn't tag "Okta" or "C#", but I believe this error was encountered when trying to follow the setup instructions...

View Article



Simple (I think) Horizontal Line in WPF?

Creating a relatively simple data entry form, and just want to separate certain sections with a horizontal line (not unlike an HR tag in HTML) that stretches the full length of the form.I have tried...

View Article

Aggregate Self-Referencing Table

I've seen several questions/answers on how to recursively query a self-referencing table, but I am struggling to apply the answers I've found to aggregate up to each parent, grandparent, etc....

View Article

Answer by Phil Sandler for Using structuremap with log4net wrapper

If the type parameter is context-specific, I don't think this is going to work as shown. If you need to pass something context specific in the constructor, you are likely going to have to create a...

View Article

Authentication/Authorization in Blazor with Some Unsecured Pages

I am struggling to get Authentication/Authorization working in Blazor in combination with having some public pages (like login, privacy policy, error pages, etc.). After much tinkering it seems to be...

View Article


Comment by Phil Sandler on How Can I Add an Extensions to a Linux-based Azure...

The extension is called Let's Encrypt.

View Article

Comment by Phil Sandler on How Do I Configure Azure App Service Support for...

Thanks for your response. I believe I completed all of the steps you listed before posting the question--is there a specific step you think I missed? Should both www.mycustomdomain.com and...

View Article

Can I Ignore Warnings about Overriding Inherited Automatic Tuning Settings...

Azure SQL Automatic Tuning has these three options with Azure defaults:Force Plan--OnCreate Index--OffDrop Index--OffWhen attempting to enable all three options, I got the following warning:It is...

View Article


How Do I Configure Azure App Service Support for Root/Naked Domain?

I have an Azure App Service hosting an asp.net website. I have a custom domain via GoDaddy, which I manage via a DNS Zone in Azure. I can't find any documentation on how to support traffic to the root,...

View Article

Browsing latest articles
Browse All 43 View Live




Latest Images