asp.net mvc - How attach NServiceBus to SQL Server -


i try use nservicebus sql server transport in project. asp.net mvc application. downloaded test example here https://docs.particular.net/samples/sqltransport-nhpersistence/ , use endpoint configuration described in example.

code configurate endpoint:

var hibernateconfig = new configuration(); hibernateconfig.databaseintegration(x =>             {                 x.connectionstringname = "nservicebus/persistence";                 x.dialect<mssql2012dialect>();             });  hibernateconfig.setproperty("default_schema", "sender");  var endpointconfiguration = new endpointconfiguration("samples.sqlnhibernateoutboxef.sender"); nservicebus.logging.logmanager.use<defaultfactory>().directory(server.mappath("~/").trim('/') + "/logs");  endpointconfiguration.licensepath(server.mappath("~/").trim('\\').trim('/') + "/license.xml"); endpointconfiguration.useserialization<jsonserializer>(); endpointconfiguration.enableinstallers();  #region senderconfiguration var transport = endpointconfiguration.usetransport<sqlservertransport>(); transport.defaultschema("sender"); transport.useschemaforqueue("error", "dbo"); transport.useschemaforqueue("audit", "dbo");  endpointconfiguration.usepersistence<nhibernatepersistence>(); endpointconfiguration.enableoutbox();  #endregion  var endpoint = await endpoint.start(endpointconfiguration).configureawait(false);  var news = new sendnewsevent             {                 newsid = 1,                 sendtoall = true             };  var r = endpoint.publish(news ).configureawait(false);  await nbusendpoint.stop().configureawait(false); 

bad thing here there no activity happened after publish. looks event totally ignored. if use test receiver vendor example can't catch events. don't receive error message wrong connection or this. how find reason of behaviour , resolve issue?


Comments

Popular posts from this blog

php - How to add and update images or image url in Volusion using Volusion API -

javascript - jQuery UI Splitter/Resizable for unlimited amount of columns -

javascript - IE9 error '$'is not defined -