Last post Apr 16, 2019 09:16 AM by Fei Han - MSFT
Apr 12, 2019 11:50 AM|Blazej Porwol|LINK
We have problems with SignalR solution hosted on Sharepoint. Everything was working fine on dev environment, where there is one machine, problems started when we decided to use SQL scaleout to deal with multiple frontends.
Currently OwinStartup looks like this:
string sqlConnectionString = @"....";
GlobalHost.DependencyResolver.Register(typeof(IAssemblyLocator), () => new AssemblyLocator());
Unfortunately it seems like SQL server is ignored - no tables are created, there are also no entries in logging file concerning sql bus. How to figure out what's going on?
Apr 15, 2019 07:33 AM|Fei Han - MSFT|LINK
Hi Blazej Porwol,
Welcome to ASP.NET forums.
Everything was working fine on dev environment, where there is one machine, problems started when we decided to use SQL scaleout
I'd like to know whether the application throw any exceptions/errors on prod environment. Besides, please check whether the database user (that you use to access the database) has permissions to log in, create schemas, and create tables.
Apr 15, 2019 07:54 AM|Blazej Porwol|LINK
When running a sample SignalR project (https://docs.microsoft.com/en-us/aspnet/signalr/overview/getting-started/tutorial-getting-started-with-signalr
) with SQL scaleout everything works fine. The scaleout in our app doesn't work anywhere, on any environment.
The user has access, we're using trusted connection for a domain user on db. The user is dbo on the db. We'd tested the user with management studio.
There are no exceptions\errors regarding SQL scaleout. Depending on configuration in OwinStartup there either were no errors, or some, in console when running page, regarding SignalR startup. But whatever the options set, SQL scaleout never worked.
We have added following lines for logging, in web.config:
<add name="SignalR-Bus" />
<add name="SignalR-Transports" />
<add name="SignalR-Init" />
<!-- Sets the trace verbosity level -->
<add name="SignalRSwitch" value="Verbose" />
<!-- Specifies the trace writer for output -->
<!-- Listener for transport events -->
<add name="SignalR-Transports" type="System.Diagnostics.TextWriterTraceListener" initializeData="D:\LOG\transports.log.txt" />
<!-- Listener for scaleout provider events -->
<add name="SignalR-Bus" type="System.Diagnostics.TextWriterTraceListener" initializeData="D:\LOG\bus.log.txt" />
<!-- Listener for hub discovery events -->
<add name="SignalR-Init" type="System.Diagnostics.TextWriterTraceListener" initializeData="D:\LOG\init.log.txt" />
<trace autoflush="true" />
Only transports.log.txt is created.
Apr 16, 2019 09:16 AM|Fei Han - MSFT|LINK
I did a test to implement [scale out with SQL Server](https://docs.microsoft.com/en-us/aspnet/signalr/overview/performance/scaleout-with-sql-server#configure-the-database),
and the backplane can help create the necessary tables for me.
The user has access, we're using trusted connection for a domain user on db. The user is dbo on the db.
If possible, please share the detailed sqlConnectionString you are using in Startup.cs (and please hide your User ID and
Password etc information), so that we will help check if something wrong with it.