migrating-ravens / RavenMigrations

A small migrations framework to help you manage your RavenDB Instance.
MIT License
53 stars 24 forks source link

Add more extension points for customization #46

Closed lahma closed 5 years ago

lahma commented 5 years ago

This PR seems to address most of our migration from FluentMigrator based custom made migration framework. We can now use conventions to tell which document ids we are using and then handle storage of record of our own type. This also allows as to circument the current shortcoming that migration record is inserted in different UoW, we just use custom repository that never stores, it's our migration attributes Up logic that handles storage as part of the UoW.

This should be quite backwards compatible, adding more customization points and tweaking internal logic.

One important thing here is to allow customization of Database, now running against specific database supplied from outside is easy. This is why I also obsoleted Db as property for document store at it's confusing, DocumentStore + Database tell you the story.

Tests are green.

JudahGabriel commented 5 years ago

Thanks!

lahma commented 5 years ago

Thanks for taking this in! Any chance of NuGet release for easier consumption?

JudahGabriel commented 5 years ago

Done. Should be visible in the NuGet gallery shortly.

lahma commented 5 years ago

Thanks, very much appreciated! I hope we can improve even more with collaboration if issues rise.

lahma commented 5 years ago

I've tried to change to new NuGet package instead of my custom built one and I get an error about requirement of .NET Core App 2.1, also on NuGet page it shown as dependency https://www.nuget.org/packages/RavenMigrations/4.0.0 . @JudahGabriel do you have ideas why could this be even though csproj targets netstandard and Appveyor uses standard packaging commands?

lahma commented 5 years ago

Ping @JudahGabriel 😃

JudahGabriel commented 5 years ago

Actually, the NuGet package was built with my old repository, not this centralized one.

I'm rebuilding it now, along with NuGet package, so as to include your PR and the .NET Standard targeting.

JudahGabriel commented 5 years ago

OK, it's done. Raven.Migrations 4.1.0 is on NuGet and includes your PR.

lahma commented 5 years ago

Great, thank you!