I've downloaded and installed NServiceBus 4.0, but I'm having some difficulty when the bus starts up...
2013-09-18 15:53:40,887 [1] WARN NServiceBus.Persistence.Raven.RavenUserInstall
er [(null)] <(null)> - Failed to add user to raven. Processing will continue
System.MissingMethodException: Method not found: 'Raven.Abstractions.Data.PutRes
ult Raven.Client.Connection.IDatabaseCommands.Put(System.String, System.Nullable
`1, Raven.Json.Linq.RavenJObject, Raven.Json.Linq.RavenJObject)'.
at NServiceBus.Persistence.Raven.RavenUserInstaller.AddUserToDatabase(String
identity, DocumentStore documentStore)
at NServiceBus.Persistence.Raven.RavenUserInstaller.Install(String identity)
in c:\BuildAgent\work\d4de8921a0aabf04\src\NServiceBus.Core\Persistence\Raven\Ra
venUserInstaller.cs:line 40
also when I try to persist changes to the document store...
public class RavenUnitOfWork: IManageUnitsOfWork
{
public IDocumentSession Session { get; set; }
public void Begin()
{
}
public void End(Exception ex = null)
{
if (ex == null && Session != null)
{
Console.WriteLine("Saving Changes to DB.");
Session.SaveChanges();
}
}
}
produces
2013-09-18 15:57:38,007 [13] INFO NServiceBus.Unicast.Transport.TransportReceiv
er [(null)] <(null)> - Failed to process message
System.InvalidOperationException: Url: "/bulk_docs"
System.FormatException: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xx
xx-xxxx-xxxx-xxxxxxxxxxxx).
at System.Guid.GuidResult.SetFailure(ParseFailureKind failure, String failure
MessageID, Object failureMessageFormatArgument, String failureArgumentName, Exce
ption innerException)
at System.Guid.TryParseGuidWithDashes(String guidString, GuidResult& result)
at System.Guid.TryParseGuid(String g, GuidStyles flags, GuidResult& result)
at System.Guid..ctor(String g)
at Raven.Database.Server.AbstractRequestResponder.GetRequestTransaction(IHttp
Context context)
at Raven.Database.Server.Responders.DocumentBatch.Respond(IHttpContext contex
t)
at Raven.Database.Server.HttpServer.DispatchRequest(IHttpContext ctx)
at Raven.Database.Server.HttpServer.HandleActualRequest(IHttpContext ctx)
---> System.Net.WebException: The remote server returned an error: (500) Intern
al Server Error.
at System.Net.HttpWebRequest.GetResponse()
at Raven.Client.Connection.HttpJsonRequest.ReadJsonInternal(Func`1 getRespons
e) in c:\Builds\RavenDB-Stable\Raven.Client.Lightweight\Connection\HttpJsonReque
st.cs:line 340
--- End of inner exception stack trace ---
at NServiceBus.Unicast.Transport.TransportReceiver.ProcessMessage(TransportMe
ssage message) in c:\BuildAgent\work\d4de8921a0aabf04\src\NServiceBus.Core\Unica
st\Transport\TransportReceiver.cs:line 357
at NServiceBus.Unicast.Transport.TransportReceiver.TryProcess(TransportMessag
e message) in c:\BuildAgent\work\d4de8921a0aabf04\src\NServiceBus.Core\Unicast\T
ransport\TransportReceiver.cs:line 235
at NServiceBus.Transports.Msmq.MsmqDequeueStrategy.ProcessMessage(TransportMe
ssage message) in c:\BuildAgent\work\d4de8921a0aabf04\src\NServiceBus.Core\Trans
ports\Msmq\MsmqDequeueStrategy.cs:line 262
at NServiceBus.Transports.Msmq.MsmqDequeueStrategy.Action() in c:\BuildAgent\
work\d4de8921a0aabf04\src\NServiceBus.Core\Transports\Msmq\MsmqDequeueStrategy.c
s:line 197
2013-09-18 15:57:38,129 [29] INFO NServiceBus.Unicast.Transport.TransportReceiv
er [(null)] <(null)> - Failed to process message
System.InvalidOperationException: Url: "/bulk_docs"
System.FormatException: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xx
xx-xxxx-xxxx-xxxxxxxxxxxx).
at System.Guid.GuidResult.SetFailure(ParseFailureKind failure, String failure
MessageID, Object failureMessageFormatArgument, String failureArgumentName, Exce
ption innerException)
at System.Guid.TryParseGuidWithDashes(String guidString, GuidResult& result)
at System.Guid.TryParseGuid(String g, GuidStyles flags, GuidResult& result)
at System.Guid..ctor(String g)
at Raven.Database.Server.AbstractRequestResponder.GetRequestTransaction(IHttp
Context context)
at Raven.Database.Server.Responders.DocumentBatch.Respond(IHttpContext contex
t)
at Raven.Database.Server.HttpServer.DispatchRequest(IHttpContext ctx)
at Raven.Database.Server.HttpServer.HandleActualRequest(IHttpContext ctx)
---> System.Net.WebException: The remote server returned an error: (500) Intern
al Server Error.
at System.Net.HttpWebRequest.GetResponse()
at Raven.Client.Connection.HttpJsonRequest.ReadJsonInternal(Func`1 getRespons
e) in c:\Builds\RavenDB-Stable\Raven.Client.Lightweight\Connection\HttpJsonReque
st.cs:line 340
--- End of inner exception stack trace ---
at NServiceBus.Unicast.Transport.TransportReceiver.ProcessMessage(TransportMe
ssage message) in c:\BuildAgent\work\d4de8921a0aabf04\src\NServiceBus.Core\Unica
st\Transport\TransportReceiver.cs:line 357
at NServiceBus.Unicast.Transport.TransportReceiver.TryProcess(TransportMessag
e message) in c:\BuildAgent\work\d4de8921a0aabf04\src\NServiceBus.Core\Unicast\T
ransport\TransportReceiver.cs:line 235
at NServiceBus.Transports.Msmq.MsmqDequeueStrategy.ProcessMessage(TransportMe
ssage message) in c:\BuildAgent\work\d4de8921a0aabf04\src\NServiceBus.Core\Trans
ports\Msmq\MsmqDequeueStrategy.cs:line 262
at NServiceBus.Transports.Msmq.MsmqDequeueStrategy.Action() in c:\BuildAgent\
work\d4de8921a0aabf04\src\NServiceBus.Core\Transports\Msmq\MsmqDequeueStrategy.c
s:line 197
2013-09-18 15:57:38,262 [30] INFO NServiceBus.Unicast.Transport.TransportReceiv
er [(null)] <(null)> - Failed to process message
System.InvalidOperationException: Url: "/bulk_docs"
I've configured Raven as follows:
Configure.Instance.Configurer.ConfigureComponent<IDocumentStore>(() =>
{
var store = new DocumentStore
{
Url = "" // <-- Points to my machine at port 8080
};
store.Initialize();
store.JsonRequestFactory.DisableRequestCompression = true;
return store;
}, DependencyLifecycle.SingleInstance);
Configure.Instance.Configurer.ConfigureComponent<IDocumentSession>(() => { return Configure.Instance.Builder.Build<IDocumentStore>().OpenSession(); }, DependencyLifecycle.InstancePerUnitOfWork);
Configure.Instance.Configurer.ConfigureComponent<RavenUnitOfWork>(DependencyLifecycle.InstancePerUnitOfWork);
What am I missing here?
Thanks.
It's a known issue. See #1518. It's been fixed in #1551, but hasn't yet made it into a release. Either try building yourself from source, or wait for it to be included in a release.
Please make sure you are running Raven v2.
Raven v2.5 has not been tested against NServiceBus v4!
I fixed the MissingMethodException I was getting when using Raven Client 2.5 and NServiceBus 4.4.2 by adding an assembly binding redirect
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Raven.Client.Lightweight" publicKeyToken="37f41c7f99471593" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.5.0.0" newVersion="2.5.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
Related
While trying to use Mono on Linux, we are running into following exception and it is our understanding that the issue here is that System.Core.dll available with Mono (from The latest Stable Mono release 6.12.0) does not have this type implemented. As shown below, System.Core.dll available with .Net Framework 4.0 from my Windows Machine has this type. Since even the latest available release 6.12.0 doesn’t have this method implemented, we are not sure how to address this issue. Is there a way to get around this?
-Error-: exportLocalDbToBacpac failed with error [System.TypeInitializationException: The type initializer for 'Microsoft.SqlServer.Dac.DacServices' threw an exception. ---> System.TypeLoadException: Could not load type of field 'Microsoft.Data.Tools.Schema.Common.Diagnostics.EtwProvider:m_provider' (1) due to: Could not resolve type with token 01000013 from typeref (expected class 'System.Diagnostics.Eventing.EventProvider' in assembly 'System.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089') assembly:System.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 type:System.Diagnostics.Eventing.EventProvider member:(null)
at Microsoft.Data.Tools.Diagnostics.Tracer.TraceEvent (System.Diagnostics.TraceEventType eventType, Microsoft.Data.Tools.Diagnostics.TraceId traceId, System.String message) [0x0002e] in <23dd43cc13d44fc0a086e3dcc59d56fb>:0
at Microsoft.Data.Tools.Schema.Sql.SchemaModel.SqlSchemaModel.InitializeModelSchema () [0x00020] in <77e18559f1da49d98aba113ae5a8f9e1>:0
at Microsoft.SqlServer.Dac.DacServices.Initialize () [0x00000] in <2c61c847f6404054945b90f540b7b548>:0
at Microsoft.SqlServer.Dac.DacServices..cctor () [0x00000] in <2c61c847f6404054945b90f540b7b548>:0
--- End of inner exception stack trace ---
at (wrapper managed-to-native) System.Object.__icall_wrapper_mono_generic_class_init(intptr)
at CvAzureSQL.AzureSQL.doExportLocalDbToBacpac (System.String exportFilePath, System.String sLocalFullServerName, System.String sDbName, System.Boolean bOverwriteExistingDb, System.Boolean& bIsCompatible) [0x00022] in :0
].
public bool doExportLocalDbToBacpac(string exportFilePath, string sLocalFullServerName, string sDbName, bool bOverwriteExistingDb, out bool bIsCompatible)
{
bIsCompatible = true;
try
{
bool ret = true;
string connectionString = "data source = " + sLocalFullServerName + "; Trusted_Connection=yes;";
**DacServices ds = new DacServices(connectionString);**
ds.ExportBacpac(exportFilePath, sDbName);
return ret;
}
catch (Exception e)
{
m_sErrorMsg += e.ToString();
m_sErrorMsg += "\n";
return false;
}
}
DotPeek tool showing details of System.Core.dll from .Net Framework
DotPeek tool showing details of mscorlib.dll available with Mono (from The latest Stable Mono release 6.12.0)
I am trying some edge cases in my software. So I have created a very simple test environment:
RabbitMQ server running on CentOS 7
Message consumer written against .NETCore 2.1 in C# running under CentOS 7
Message sender written against .NETCore 2.1 in C# running under CentOS 7
I send a simple text message every 5 seconds. The sender and receiver run on the same UNIX box, while the RabbitMQ server runs on a different machine in the network.
So far so good. Now I stop my RabbitMQ server with systemctl stop rabbitmq-server.
I get errors on the sender and the receiver which was expected.
I restart the RabbitMQ server using systemctl start rabbitmq-server.
And now the fun starts! The sender can recover and continues to send messages but the consumer CANNOT recover and does not receive messages. They are accumulated on the RabbitMQ server!
Here are my log entries from the sender (which works as expected):
2019-01-22 21:18:25.628 +01:00 [ERR] [EasyNetQ.PersistentConnection] [ThreadId 10] Failed to connect to broker infraserver-tbws2, port 5672, vhost testvh
RabbitMQ.Client.Exceptions.BrokerUnreachableException: None of the specified endpoints were reachable ---> System.AggregateException: One or more errors occurred. (Connection failed) ---> RabbitMQ.Client.Exceptions.ConnectFailureException: Connection failed ---> System.Net.Internals.SocketExceptionFactory+ExtendedSocketException: Connection refused 172.16.63.239:5672
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw(Exception source)
at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)
at System.Net.Sockets.Socket.<>c.<ConnectAsync>b__272_0(IAsyncResult iar)
--- End of stack trace from previous location where exception was thrown ---
at RabbitMQ.Client.TcpClientAdapter.ConnectAsync(String host, Int32 port)
at RabbitMQ.Client.Impl.TaskExtensions.TimeoutAfter(Task task, Int32 millisecondsTimeout)
at RabbitMQ.Client.Impl.SocketFrameHandler.ConnectOrFail(ITcpClient socket, AmqpTcpEndpoint endpoint, Int32 timeout)
--- End of inner exception stack trace ---
at RabbitMQ.Client.Impl.SocketFrameHandler.ConnectUsingAddressFamily(AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 timeout, AddressFamily family)
at RabbitMQ.Client.Impl.SocketFrameHandler.ConnectUsingIPv4(AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 timeout)
at RabbitMQ.Client.Impl.SocketFrameHandler..ctor(AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 connectionTimeout, Int32 readTimeout, Int32 writeTimeout)
at RabbitMQ.Client.Framing.Impl.IProtocolExtensions.CreateFrameHandler(IProtocol protocol, AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 connectionTimeout, Int32 readTimeout, Int32 writeTimeout)
at RabbitMQ.Client.ConnectionFactory.CreateFrameHandler(AmqpTcpEndpoint endpoint)
at RabbitMQ.Client.EndpointResolverExtensions.SelectOne[T](IEndpointResolver resolver, Func`2 selector)
--- End of inner exception stack trace ---
at RabbitMQ.Client.EndpointResolverExtensions.SelectOne[T](IEndpointResolver resolver, Func`2 selector)
at RabbitMQ.Client.ConnectionFactory.CreateConnection(IEndpointResolver endpointResolver, String clientProvidedName)
--- End of inner exception stack trace ---
at RabbitMQ.Client.ConnectionFactory.CreateConnection(IEndpointResolver endpointResolver, String clientProvidedName)
at RabbitMQ.Client.ConnectionFactory.CreateConnection(String clientProvidedName)
at EasyNetQ.ConnectionFactoryWrapper.CreateConnection()
at EasyNetQ.PersistentConnection.TryToConnect()
2019-01-22 21:18:25.632 +01:00 [ERR] [EasyNetQ.PersistentConnection] [ThreadId 10] Failed to connect to any Broker. Retrying in 00:00:05
2019-01-22 21:18:35.444 +01:00 [INF] [] [ThreadId 1] Sucessfully sent Message 'Message: 'This is test message number 7.' | Num: 7 | Guid: 5345c7e4-61e6-4c79-8179-d4bef7864420'.
2019-01-22 21:18:40.452 +01:00 [INF] [] [ThreadId 1] Sucessfully sent Message 'Message: 'This is test message number 8.' | Num: 8 | Guid: 3cd8635c-cdfa-45f3-8495-2acb0713d47b'.
2019-01-22 21:18:45.457 +01:00 [INF] [] [ThreadId 1] Sucessfully sent Message 'Message: 'This is test message number 9.' | Num: 9 | Guid: 099462b8-cd66-40b9-ac10-89c3246819ec'.
2019-01-22 21:18:50.470 +01:00 [INF] [] [ThreadId 1] Sucessfully sent Message 'Message: 'This is test message number 10.' | Num: 10 | Guid: c25139b2-8e45-4771-9544-830014382e0c'.
2019-01-22 21:18:55.515 +01:00 [INF] [] [ThreadId 1] Sucessfully sent Message 'Message: 'This is test message number 11.' | Num: 11 | Guid: 90049d91-3805-4aaa-ac18-b61c09164afd'.
2019-01-22 21:19:00.526 +01:00 [INF] [] [ThreadId 1] Sucessfully sent Message 'Message: 'This is test message number 12.' | Num: 12 | Guid: 108ff318-6a34-4e64-94bd-dafa67aa6717'.
This shows the last error message and then one can see that EasyNetQ recovered and can deliver messages again.
The message consumer does NOT work! Here my log entries:
2019-01-22 21:18:25.623 +01:00 [ERR] [EasyNetQ.PersistentConnection] [ThreadId 12] Failed to connect to broker infraserver-tbws2, port 5672, vhost testvh
RabbitMQ.Client.Exceptions.BrokerUnreachableException: None of the specified endpoints were reachable ---> System.AggregateException: One or more errors occurred. (Connection failed) ---> RabbitMQ.Client.Exceptions.ConnectFailureException: Connection failed ---> System.Net.Internals.SocketExceptionFactory+ExtendedSocketException: Connection refused 172.16.63.239:5672
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw(Exception source)
at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)
at System.Net.Sockets.Socket.<>c.<ConnectAsync>b__272_0(IAsyncResult iar)
--- End of stack trace from previous location where exception was thrown ---
at RabbitMQ.Client.TcpClientAdapter.ConnectAsync(String host, Int32 port)
at RabbitMQ.Client.Impl.TaskExtensions.TimeoutAfter(Task task, Int32 millisecondsTimeout)
at RabbitMQ.Client.Impl.SocketFrameHandler.ConnectOrFail(ITcpClient socket, AmqpTcpEndpoint endpoint, Int32 timeout)
--- End of inner exception stack trace ---
at RabbitMQ.Client.Impl.SocketFrameHandler.ConnectUsingAddressFamily(AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 timeout, AddressFamily family)
at RabbitMQ.Client.Impl.SocketFrameHandler.ConnectUsingIPv4(AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 timeout)
at RabbitMQ.Client.Impl.SocketFrameHandler..ctor(AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 connectionTimeout, Int32 readTimeout, Int32 writeTimeout)
at RabbitMQ.Client.Framing.Impl.IProtocolExtensions.CreateFrameHandler(IProtocol protocol, AmqpTcpEndpoint endpoint, Func`2 socketFactory, Int32 connectionTimeout, Int32 readTimeout, Int32 writeTimeout)
at RabbitMQ.Client.ConnectionFactory.CreateFrameHandler(AmqpTcpEndpoint endpoint)
at RabbitMQ.Client.EndpointResolverExtensions.SelectOne[T](IEndpointResolver resolver, Func`2 selector)
--- End of inner exception stack trace ---
at RabbitMQ.Client.EndpointResolverExtensions.SelectOne[T](IEndpointResolver resolver, Func`2 selector)
at RabbitMQ.Client.ConnectionFactory.CreateConnection(IEndpointResolver endpointResolver, String clientProvidedName)
--- End of inner exception stack trace ---
at RabbitMQ.Client.ConnectionFactory.CreateConnection(IEndpointResolver endpointResolver, String clientProvidedName)
at RabbitMQ.Client.ConnectionFactory.CreateConnection(String clientProvidedName)
at EasyNetQ.ConnectionFactoryWrapper.CreateConnection()
at EasyNetQ.PersistentConnection.TryToConnect()
2019-01-22 21:18:25.625 +01:00 [ERR] [EasyNetQ.PersistentConnection] [ThreadId 12] Failed to connect to any Broker. Retrying in 00:00:05
Here it sits and waits forever! Looks like the thing is deadlocked in a way while the messages are accumulating on the RabbitMQ server:
When I stop my consumer application and restart it, the messages are picked up.
I connect in both applications (sender and consumer) with the following code:
private static IBus SetupRabbitMqConnection(string rabbitServer, string rabbitVHost, ushort rabbitPort, string rabbitUser, string rabbitPwd)
{
Log.Logger.Debug($"Creating a connection to RabbitMQ server '{rabbitServer}' on port {rabbitPort.ToString()} " +
$"using the EasyNetQ library....");
try
{
var connStr = $"host={rabbitServer}:{rabbitPort.ToString()};virtualHost={rabbitVHost};username={rabbitUser};" +
$"password={rabbitPwd};publisherConfirms=true;timeout=30;prefetchcount=1;requestedHeartbeat=30";
var msgBus = RabbitHutch.CreateBus(connStr, x => { });
if (!msgBus.IsConnected)
{
var errMsg = $"Currently not connected to RabbitMQ server '{rabbitServer}'.";
Log.Logger.Error(errMsg);
}
Log.Logger.Debug("Successfully connected to RabbitMQ server.");
return msgBus;
}
catch (Exception ex)
{
Log.Logger.Error($"Error to establish a connection to RabbitMQ server '{rabbitServer}'. Error: {ex}");
throw;
}
}
The consumer program registers the listeners as follows:
var msgBus = SetupRabbitMqConnection(rabbitServer, vhost, rabbitPort, rabbitUser, rabbitPwd);
RegisterMsgSubscriptions(msgBus);
private static void RegisterMsgSubscriptions(IBus msgBus)
{
Log.Logger.Debug("Starting to register RabbitMQ message subscriptions...");
try
{
#region Queue declarations
var advancedBus = msgBus.Advanced;
var testQueueOne = new EasyNetQ.Topology.Queue(TestQueueOneName, true);
Log.Logger.Debug("Finished declaring queues.");
#endregion
#region Message Queue Handler registrations
advancedBus.Consume(testQueueOne, registration => registration
.Add<RabbitMessage<TestTextMessageDto>>(MessageProcessor.ProcessRabbitTestMessage));
Log.Logger.Debug("Finished registration of message handlers for several queues.");
#endregion
}
catch (Exception ex)
{
Log.Logger.Error($"Error registering message handler. Error: {ex}");
}
}
Any idea what might go wrong here?? In production we have more than 100 servers consuming messages. These servers are on premise spread all over the country. The RabbitMQ server is in the data center. So the consuming servers MUST recover if the connection gets lost, otherwise this is not usable!
Just add subscription logic on connected event (It will be fired on every broker connected event).
advancedBus.Connected += (sender, args) => {
// subscribe logic
};
Of course You should handle not to call subscribe logice twice on any connect etc.
I am trying to integrate SonarQube MSBuild runner with TFS 2013 and I am using SonarQube 5.2 version and MSBuild.SonarQube.Runner-1.0.2 with all the required plug-ins for LDAP, .NET and C#. I get this error when I run the TFS Build:
Unhandled Exception: System.Net.WebException: The remote server returned an error: (401) Unauthorized.
at System.Net.WebClient.DownloadDataInternal(Uri address, WebRequest& request)
at System.Net.WebClient.DownloadString(Uri address)
at System.Net.WebClient.DownloadString(String address)
at SonarQube.TeamBuild.PreProcessor.WebClientDownloader.Download(String url)
at SonarQube.TeamBuild.PreProcessor.SonarWebService.GetProperties(String projectKey, ILogger logger)
at SonarQube.TeamBuild.PreProcessor.PropertiesFetcher.FetchProperties(SonarWebService ws, String sonarProjectKey, ILogger logger)
at SonarQube.TeamBuild.PreProcessor.TeamBuildPreProcessor.FetchArgumentsAndRulesets(ProcessedArgs args, String configDir, ILogger logger, IDictionary`2& serverSettings)
at SonarQube.TeamBuild.PreProcessor.TeamBuildPreProcessor.DoExecute(ProcessedArgs args, ILogger logger)
at SonarQube.TeamBuild.PreProcessor.TeamBuildPreProcessor.Execute(String[] args, ILogger logger)
at SonarQube.TeamBuild.PreProcessor.Program.Main(String[] args)
Exception Message: TF270015: 'MSBuild.SonarQube.Runner.exe' returned an unexpected exit code. Expected '0'; actual '-532462766'. See the build logs for more details. (type UnexpectedExitCodeException)Exception Stack Trace: at System.Activities.Statements.Throw.Execute(CodeActivityContext context) at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager) at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)
Only technical users are supported for authentication from MSBuild.SonarQube.Runner.exe or SonarQube Runner against SonarQube 5.2 with LDAP plugin 1.5.1(and Windows Authentication mode enabled).
When my endpoint does Bus.Reply() to I a message sent with Bus.SendLocal(), I get the following error message which causes the message to fail:
2013-02-28 13:54:16,994 [Worker.15] WARN NServiceBus.Unicast.Transport.Transact
ional.TransactionalTransport [(null)] <(null)> - Failed raising 'transport messa
ge received' event for message with ID=42e4b3ed-d0a2-4ab0-acfb-3531d8dafa3e\2056
7
NServiceBus.Unicast.Transport.TransportMessageHandlingFailedException: Exception
of type 'NServiceBus.Unicast.Transport.TransportMessageHandlingFailedException'
was thrown.
at NServiceBus.Unicast.UnicastBus.HandleTransportMessage(IBuilder childBuilde
r, TransportMessage msg) in c:\BuildAgent\work\nsb.master_6\src\unicast\NService
Bus.Unicast\UnicastBus.cs:line 1331
at NServiceBus.Unicast.UnicastBus.TransportMessageReceived(Object sender, Tra
nsportMessageReceivedEventArgs e) in c:\BuildAgent\work\nsb.master_6\src\unicast
\NServiceBus.Unicast\UnicastBus.cs:line 1248
at System.EventHandler`1.Invoke(Object sender, TEventArgs e)
at NServiceBus.Unicast.Transport.Transactional.TransactionalTransport.OnTrans
portMessageReceived(TransportMessage msg) in c:\BuildAgent\work\nsb.master_6\src
\impl\unicast\transport\NServiceBus.Unicast.Transport.Transactional\Transactiona
lTransport.cs:line 480
Here's my configuration:
Configure
.With(AllAssemblies.Except("evointernal.dll")) // This is a COM assembly and should not be scanned.
.StructureMapBuilder(ObjectFactory.Container)
.JsonSerializer()
.UnicastBus().DoNotAutoSubscribe()
.Sagas();
When I try & start one of my services I get this error:
There is no index named: RavenTimeoutPersistence/TimeoutDataSortedByTime
Stacktrace:
Unhandled Exception: Magnum.StateMachine.StateMachineException:
Exception occurred in Topshelf.Internal.ServiceControlle
r1[[NServiceBus.Hosting.Windows.WindowsHost, NServiceBus.Host,
Version=3.2.0.0, Culture=neutral, PublicKeyToken=9fc3864 79f8a226c]]
during state Initial while handling OnStart ---> System.Exception:
Exception when starting endpoint, error h as been logged. Reason:
There is no index named: RavenTimeoutPersistence/TimeoutDataSortedByTime --->
System.InvalidOper ationException: There is no index named:
RavenTimeoutPersistence/TimeoutDataSortedByTime at
Raven.Client.Connection.ServerClient.DirectQuery(String index,
IndexQuery query, String operationUrl, String[] inc ludes) at
Raven.Client.Connection.ServerClient.<>c__DisplayClass37.<Query>b__36(String
u) at Raven.Client.Connection.ServerClient.TryOperation[T](Func2
operation, String operationUrl, Boolean avoidThrowing, T& result)
at
Raven.Client.Connection.ServerClient.ExecuteWithReplication[T](String
method, Func2 operation) at
Raven.Client.Connection.ServerClient.Query(String index, IndexQuery
query, String[] includes) at
Raven.Client.Document.AbstractDocumentQuery2.ExecuteActualQuery()
at Raven.Client.Document.AbstractDocumentQuery2.get_QueryResult()
at
Raven.Client.Linq.RavenQueryProviderProcessor1.ExecuteQueryTProjection
at Raven.Client.Linq.RavenQueryProviderProcessor1.Execute(Expression
expression) at
Raven.Client.Linq.RavenQueryProvider1.Execute(Expression expression)
at
Raven.Client.Linq.RavenQueryProvider1.System.Linq.IQueryProvider.Execute(Expression
expression) at
Raven.Client.Linq.RavenQueryInspector1.GetEnumerator() at
System.Collections.Generic.List1.InsertRange(Int32 index,
IEnumerable1 collection) at
NServiceBus.Timeout.Hosting.Windows.Persistence.RavenTimeoutPersistence.GetAll()
at NServiceBus.Timeout.Core.TimeoutRunner.CacheExistingTimeouts()
at NServiceBus.Timeout.Core.TimeoutRunner.Run() at
System.Collections.Generic.List1.ForEach(Action1 action) at
NServiceBus.Unicast.UnicastBus.NServiceBus.IStartableBus.Start(Action
startupAction) at NServiceBus.Hosting.GenericHost.Start() in
c:\TeamCity\buildAgent\work\nsb.master_6\src\hosting\NServiceBus.Hostin
g\GenericHost.cs:line 34
Configuration of the host is:
var container = new WindsorContainer();
container.Install(FromAssembly.This());
Configure.With()
.DefiningEventsAs(t => t.Namespace != null && t.Namespace.StartsWith("Events"))
.DefiningCommandsAs(t => t.Namespace != null && t.Namespace.StartsWith("Messages"))
.CastleWindsorBuilder(container)
.XmlSerializer()
.MsmqTransport()
.IsTransactional(true)
.IsolationLevel(IsolationLevel.ReadUncommitted)
.UnicastBus()
.RavenSagaPersister()
.RavenSubscriptionStorage()
.UseRavenTimeoutPersister()
.RunTimeoutManager()
.ForInstallationOn<NServiceBus.Installation.Environments.Windows>().Install();
I have other services on this machine that are running without error. I've tried restarting the ravendb service.
Running Nservicebus 3.2.5
You are missing an index: RavenTimeoutPersistence/TimeoutDataSortedByTime
You need to create it, or NSB needs to create it, I am not sure where this index came from.