Coder Social home page Coder Social logo

nservicebus.mongodb's Introduction

NServiceBus.MongoDB Build Status NuGet Status

MongoDB persistence for NServicBus 7.x

Installation

  • Get the source and build locally

or

Configuration

After adding a reference to it from your project, specify MongoDBPersistence to be used for persistence.

using NServiceBus;
using NServiceBus.MongoDB;

public class EndpointConfig : IConfigureThisEndpoint, AsA_Server
{
  public void Customize(BusConfiguration configuration)
  {
    configuration.UsePersistence<MongoDBPersistence>()
        .SetDatabaseName("MyDatabase");
  }
}

This base configuration connects using NServiceBus/Persistence/MongoDB connection string in the app.config and MyDatabase as the database.

<connectionStrings>
  <add name="NServiceBus/Persistence/MongoDB" connectionString="mongodb://localhost:27017" />
</connectionStrings>

If this connection string is not found NServiceBus/Persistence is used.

<connectionStrings>
  <add name="NServiceBus/Persistence" connectionString="mongodb://localhost:27017" />
</connectionStrings>

or specify the connection string to use:

using NServiceBus;
using NServiceBus.MongoDB;

public class EndpointConfig : IConfigureThisEndpoint, AsA_Server
{
  public void Customize(BusConfiguration configuration)
  {
    configuration.UsePersistence<MongoDBPersistence>()
        .SetConnectionString("mongodb://localhost:27017")
        .SetDatabaseName("MyDatabase");
  }
}

DataBus Configuration

To configure NServiceBus to use MongoDB GridFS as the persistence for DataBus use the following configuration.

using NServiceBus;
using NServiceBus.MongoDB;

public class EndpointConfig : IConfigureThisEndpoint, AsA_Server
{
  public void Customize(BusConfiguration configuration)
  {
    configuration.UsePersistence<MongoDBPersistence>();
    configuration.UseDataBus<MongoDBDataBus>();
  }
}

Sagas

Saga data needs to be defined the normal way NSB requires with the additional interface IHaveDocumentVersion to work appropriately with NServiceBus.MongoDB. This interface adds two additional properties, a version number and ETag property. Alternatively you can just inherit from ContainMongoSagaData as follows:

using NServiceBus.MongoDB;
using NServiceBus.Saga;

public class MySagaData : ContainMongoSagaData
{
    public string SomeId { get; set; }

    public int Count { get; set; }
}

Samples

See Simple sample

Build Instructions

  • Prerequisistes
  • Run make from the root directory

nservicebus.mongodb's People

Contributors

aman-shahid avatar craigkennedy avatar mancku avatar michellechen01 avatar sbmako avatar simoncropp avatar wespday avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nservicebus.mongodb's Issues

Remove subscription versioning based on assembly version

We've recently concluded that including the major version of the assembly containing the message contracts could lead to message loss for users not aware of this behavior. NServiceBus core 5.2.17 was released to fix this Particular/NServiceBus#4177.

Looking at the code I think the same problem exists here. I even think it could be worse since SubscriptionKey stores both the type name and the full version. And I guess that both are compared and not just the major part of the version.

What can we do to only story the type name and ignore the version completely?

Unable to Update Saga Document

After upgrading to MongoCSharpDriver 2.0.1 and NServiceBus.MongoDb 5.2 we experienced total failure to update our sagas. The exception experienced was: "Unable to save with id ..."

https://github.com/sbmako/NServiceBus.MongoDB/blob/master/src/NServiceBus.MongoDB/SagaPersister/MongoSagaPersister.cs#L89

After pulling the source down and debugging we identified that the cast of saga.Id to a string was resulting in a failed query because our Id is a GUID and stored as a LUUID in MongoDb.

https://github.com/sbmako/NServiceBus.MongoDB/blob/master/src/NServiceBus.MongoDB/Extensions/DocumentVersionExtensions.cs#L59

The version of NServiceBus.MongoDb we updated from was 2.0.3 and the MongoCSharpDriver was 1.10.0. A hotfix would be much appreciated.

Update to NServiceBus v7?

With v7 just right around the corner are there any plans to update the persister to support it? (there should not be any dramatic changes on the persistence seam)

Let let me know if you need any help

Refactor 7 lines occurring 2 times in ConfigureMongoPersistence.cs

I've selected for refactoring 7 lines of code which are duplicated in 1 file(s) (1, 2). Addressing this will make our codebase more maintainable and improve Better Code Hub's Write Code Once guideline rating! ๐Ÿ‘

Here's the gist of this guideline:

  • Definition ๐Ÿ“–
    Do not copy code.
  • Whyโ“
    When code is copied, bugs need to be fixed in multiple places. This is both inefficient and a source of regression bugs.
  • How ๐Ÿ”ง
    Avoid duplication by never copy/pasting blocks of code and reduce duplication by extracting shared code, either to a new unit or introduce a superclass if the language permits.

You can find more info about this guideline in Building Maintainable Software. ๐Ÿ“–


โ„น๏ธ To know how many other refactoring candidates need addressing to get a guideline compliant, select some by clicking on the ๐Ÿ”ฒ next to them. The risk profile below the candidates signals (โœ…) when it's enough! ๐Ÿ


Good luck and happy coding! :shipit: โœจ ๐Ÿ’ฏ

Element name 'NServiceBus.MessageId' is not valid'

mongocsharpdriver" version="2.0.1" targetFramework="net451"
MongoDB.Bson" version="2.0.1" targetFramework="net45"
MongoDB.Driver" version="2.0.1" targetFramework="net45"
MongoDB.Driver.Core" version="2.0.1" targetFramework="net45"
NServiceBus" version="5.2.4" targetFramework="net451"
NServiceBus.MongoDB" version="2.1.0" targetFramework="net45"

using msmq. after upgrading nservicebus from 5.2.2 and the mongo drivers to 2.0+ i'm getting an error after my 'RequestTimeout' call. if i use InMemoryPersistence, this error goes away which suggests it's something with the nservicebus mongo driver. has anyone have any ideas?

2015-08-10 12:08:46.471 INFO NServiceBus.Unicast.Transport.TransportReceiver Failed to process message
MongoDB.Bson.BsonSerializationException: Element name 'NServiceBus.MessageId' is not valid'.
at MongoDB.Bson.IO.BsonWriter.WriteName(String name)
at MongoDB.Bson.Serialization.Serializers.BsonDocumentSerializer.SerializeValue(BsonSerializationContext context, BsonSerializationArgs args, BsonDocument value)

Improve build

The build script needs to be improved:

  • Add unit test target
  • Base all assembly and nuget package version numbers from what is in default.ps1

Unclear Error message, Unable to update saga with id

Could be a clearer error message regarding why not be able to update Saga, in this case it seemed (not sure if the Saga was deleted) that there was no object with that ID.

Here is full call stack

Failed to process message System.InvalidOperationException: Unable to update saga with id 6d285930-6e5b-489d-be76-a50c00967ba4
   at NServiceBus.MongoDB.SagaPersister.MongoSagaPersister.Update(IContainSagaData saga) in d:\Development\NServiceBus.MongoDB\src\NServiceBus.MongoDB\SagaPersister\MongoSagaPersister.cs:line 106
   at NServiceBus.SagaPersistenceBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Sagas\SagaPersistenceBehavior.cs:line 117
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at ServiceControl.Plugin.SagaAudit.CaptureSagaStateBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\f7bdf8147ca393ba\src\ServiceControl.Plugin.Nsb5.SagaAudit\CaptureSagaStateBehavior.cs:line 39
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.SetCurrentMessageBeingHandledBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Behaviors\SetCurrentMessageBeingHandledBehavior.cs:line 17
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.LoadHandlersBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Behaviors\LoadHandlersBehavior.cs:line 45
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.InvokeSagaNotFoundBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Behaviors\InvokeSagaNotFoundBehavior.cs:line 19
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.ApplyIncomingMessageMutatorsBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\MessageMutator\ApplyIncomingMessageMutatorsBehavior.cs:line 23
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.ExecuteLogicalMessagesBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Messages\ExecuteLogicalMessagesBehavior.cs:line 24
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.CallbackInvocationBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Behaviors\CallbackInvocationBehavior.cs:line 22
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.DeserializeLogicalMessagesBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Messages\DeserializeLogicalMessagesBehavior.cs:line 47
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.ApplyIncomingTransportMessageMutatorsBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\MessageMutator\ApplyIncomingTransportMessageMutatorsBehavior.cs:line 20
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.SubscriptionReceiverBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Subscriptions\MessageDrivenSubscriptions\SubscriptionReceiverBehavior.cs:line 32
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.UnitOfWorkBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\UnitOfWork\UnitOfWorkBehavior.cs:line 42
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.ChildContainerBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Behaviors\ChildContainerBehavior.cs:line 17
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.ProcessingStatisticsBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Monitoring\ProcessingStatisticsBehavior.cs:line 23
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.<>c__DisplayClass5.<InvokeNext>b__2() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 95
   at NServiceBus.AuditBehavior.Invoke(IncomingContext context, Action next) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Audit\AuditBehavior.cs:line 20
   at NServiceBus.BehaviorChain`1.InvokeNext(T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 107
   at NServiceBus.BehaviorChain`1.Invoke() in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\BehaviorChain.cs:line 58
   at NServiceBus.Pipeline.PipelineExecutor.Execute[T](BehaviorChain`1 pipelineAction, T context) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Pipeline\PipelineExecutor.cs:line 129
   at NServiceBus.Unicast.Transport.TransportReceiver.ProcessMessage(TransportMessage message) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Transport\TransportReceiver.cs:line 344
   at NServiceBus.Unicast.Transport.TransportReceiver.TryProcess(TransportMessage message) in c:\BuildAgent\work\3206e2123f54fce4\src\NServiceBus.Core\Unicast\Transport\TransportReceiver.cs:line 230
   at NServiceBus.Azure.Transports.WindowsAzureServiceBus.AzureServiceBusDequeueStrategy.TryProcessMessage(Object obj) in c:\BuildAgent\work\2f57832e2eee436e\src\Transport\Receiving\AzureServiceBusDequeueStrategy.cs:line 137

Cannot connect to Mongo after upgrade to 2.1

Tried to upgrade from NServiceBus.MongoDB 2.0.3 to 2.1. Get an exception:

2015-07-08 11:29:16,589 [1] WARN NServiceBus.MongoDB.Internals.MongoHelpers [(null)] <(null)> - Mongo could not be contacted using: server201.localco.test:27017. If you are using a Replica Set, please ensure that all the Mongo instance(s) server201.localco.test:27017 are available. To configure NServiceBus to use a different connection string add a connection string named "NServiceBus/Persistence" in your config file. Reason: System.InvalidOperationException: There is no current primary. at MongoDB.Driver.MongoServer.Ping() at NServiceBus.MongoDB.Internals.MongoHelpers.VerifyConnectionToMongoServer(MongoClientAccessor mongoClientAccessor) in d:\Development\NServiceBus.MongoDB\src\NServiceBus.MongoDB\Internals\MongoHelpers.cs:line 50

My config code:
configuration.AssembliesToScan(AppDomain.CurrentDomain.GetAssemblies()); configuration.UseTransport<RabbitMQTransport>(); configuration.UsePersistence<MongoDBPersistence>();

Using NserviceBus 5.2/ NServiceBus.MongoDB 2.1 / mongo-csharp-driver 2.0.1. As you can see we also use RabbitMQ for transport if that's relevant. If I remove the latest nuget and run the previous version (Install-Package NServiceBus.MongoDB -Version 2.0.3) no exception occurs.

I also have this issue posted over at SO: http://stackoverflow.com/questions/31301105/mongo-csharp-driver-2-0-nservicebus-mongodb-2-1-can-no-longer-connect-to-mongo

Releases not updated

Hi, The Releases in github has not been updated since 5.2.1 and I would like to identify code changes with releases in order to update

Adjust to changes in timeouts persistence interface in NServiceBus

Recently we discovered an edge case scenario in timeouts persistence that might lead to a message loss. To address this issue we decided to introduce a breaking change (new interface across versions 4.4-5.3) and adapt all persistence providers we support.
You can find more details on the issue here Particular/NServiceBus#2885.
Please, contact as asap so we can provide further details ([email protected]), walk you through the changes we're making and explain what is the impact for this project.

Weronika ลabaj
Particular Software

Contact Request

Hey sbmako, I had a question about your repo and wanted to discuss working on this project together. Do you have an e-mail I can use to discuss?

Remove References to Legacy MongoDB Driver

Should fix this build warning:

Internals\MongoHelpers.cs(46,26): warning CS0618:
'MongoDB.Driver.MongoClientExtensions.GetServer(MongoDB.Driver.MongoClient)'
is obsolete: 'Use the new API instead.'

Also, remove references to MongoDB.Driver.Legacy.dll

Create unique collection for each saga state (F.I: using full namespace)

To be able to use a single mongoDB database to store the persistence of all or different NSB services. It would be goo to make sure every service state is stored into separate collection. So no possible collusion of two different states situation could arise.

Now if two different services uses the same state name (f.i. OrderState) and same identifier, which is probable(f.i. OrderId). we can be hit by issues of loading or modifying different states.

To solve this we might use full namespace to identify saga collections.
Also we could set up a prefix per service that could be use to prefix all states into the service (if full namespace is too long)

By having this we could reduce the admin tasks. As if you are embracing a microservices architecture soon you'll have quite a lot of services which might have it's own repository plus the persistence DB in mongo. That will create a lot of different similar DB in mongoDB to look after.

Related to this topic:
https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/particularsoftware/V99-0Rjq8Fk/v6PNb1SdBAAJ

Configuration per StorageType in .config-file

About configuration of the Connection String, would be nice if it followed similar naming convention as NHibernate example, so

  cfg.UsePersistence<MongoDBPersistence, StorageType.Sagas>()
    .SetDatabaseName("x_sagas");

Would look for,

  <add name="NServiceBus/Persistence/MongoDB/Saga"
      connectionString="mongodb://..."/>

This would be useful when mixing Persistence types

Full documentation and example in NHibernate
http://docs.particular.net/nservicebus/nhibernate/configuration

Refactor 7 lines occurring 2 times in 2 files: ConfigureMongoPersistence.cs, MongoHelpers.cs

I've selected for refactoring 7 lines of code which are duplicated in 2 file(s) (1, 2). Addressing this will make our codebase more maintainable and improve Better Code Hub's Write Code Once guideline rating! ๐Ÿ‘

Here's the gist of this guideline:

  • Definition ๐Ÿ“–
    Do not copy code.
  • Whyโ“
    When code is copied, bugs need to be fixed in multiple places. This is both inefficient and a source of regression bugs.
  • How ๐Ÿ”ง
    Avoid duplication by never copy/pasting blocks of code and reduce duplication by extracting shared code, either to a new unit or introduce a superclass if the language permits.

You can find more info about this guideline in Building Maintainable Software. ๐Ÿ“–


โ„น๏ธ To know how many other refactoring candidates need addressing to get a guideline compliant, select some by clicking on the ๐Ÿ”ฒ next to them. The risk profile below the candidates signals (โœ…) when it's enough! ๐Ÿ


Good luck and happy coding! :shipit: โœจ ๐Ÿ’ฏ

Refactor MongoTimeoutStorage.cs

I've selected MongoTimeoutStorage.cs for refactoring, which is a module that has 1 instance(s) of code in comments (1). Addressing this will make our codebase more maintainable and improve Better Code Hub's Write Clean Code guideline rating! ๐Ÿ‘

Here's the gist of this guideline:

  • Definition ๐Ÿ“–
    Apply The Boy Scout Rule and fix "code smells" in the codebase.
  • Whyโ“
    Clean code is maintainable code.
  • How ๐Ÿ”ง
    Remove useless comments, commented code blocks, and dead code. Refactor poorly handled exceptions, magic constants, and poorly named units or variables.

You can find more info about this guideline in Building Maintainable Software. ๐Ÿ“–


โ„น๏ธ To know how many other refactoring candidates need addressing to get a guideline compliant, select some by clicking on the ๐Ÿ”ฒ next to them. The risk profile below the candidates signals (โœ…) when it's enough! ๐Ÿ


Good luck and happy coding! :shipit: โœจ ๐Ÿ’ฏ

Unable to build and include in other projects

I attempted to build this and add it as a file reference in another project for debugging. Unfortunately I don't have CodeContracts installed and there is insufficient documentation out on how to set it up with VS2013.

Could you please update your README with your configuration as part of the build process.

Refactor MongoSagaPersister.cs

I've selected MongoSagaPersister.cs for refactoring, which is a module that has 1 instance(s) of code in comments (1). Addressing this will make our codebase more maintainable and improve Better Code Hub's Write Clean Code guideline rating! ๐Ÿ‘

Here's the gist of this guideline:

  • Definition ๐Ÿ“–
    Apply The Boy Scout Rule and fix "code smells" in the codebase.
  • Whyโ“
    Clean code is maintainable code.
  • How ๐Ÿ”ง
    Remove useless comments, commented code blocks, and dead code. Refactor poorly handled exceptions, magic constants, and poorly named units or variables.

You can find more info about this guideline in Building Maintainable Software. ๐Ÿ“–


โ„น๏ธ To know how many other refactoring candidates need addressing to get a guideline compliant, select some by clicking on the ๐Ÿ”ฒ next to them. The risk profile below the candidates signals (โœ…) when it's enough! ๐Ÿ


Good luck and happy coding! :shipit: โœจ ๐Ÿ’ฏ

I just tried to install the nuget package with Nservicebus 5.1.2

Looking at the upgrade from 4 to 5. The interfaces classes have been either dropped or folded into the nservicebus nuget package.

I am interested as we are moving 100% off of SQL and MSMQ in favor of more geographically distributed friendly tools like mongo.

Attempting to resolve dependency 'mongocsharpdriver (โ‰ฅ 1.9.2)'.
Attempting to resolve dependency 'NServiceBus (โ‰ฅ 4.7.1 && < 5.0)'.
Attempting to resolve dependency 'NServiceBus.Interfaces (โ‰ฅ 4.7.1 && < 5.0.0.0)'.
Installing 'NServiceBus.Interfaces 4.7.1'.
Successfully installed 'NServiceBus.Interfaces 4.7.1'.
Installing 'NServiceBus 4.7.1'.
Successfully installed 'NServiceBus 4.7.1'.
Installing 'NServiceBus.MongoDB 1.0.3'.
Successfully installed 'NServiceBus.MongoDB 1.0.3'.
Install failed. Rolling back...
Updating 'NServiceBus 5.1.2' to 'NServiceBus 4.7.1' failed. Unable to find a version of 'NServiceBus.Host' that is compatible with 'NServiceBus 4.7.1'.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.