-
Notifications
You must be signed in to change notification settings - Fork 151
Migration Guide from 2.* to 3
The FubuMVC 3.0 effort was mostly about consolidation of the still-used parts of FubuMVC/FubuTransportation being merged into a single GitHub repository with many fewer libraries. The bootstrapping is significantly faster and many obsolete features were eliminated. In addition, the diagnostics were greatly improved with a mostly new architecture based on React.js & React-Bootstrap
The new topography is:
- FubuMVC.Core - Contains what was FubuTransportation, FubuMVC.StructureMap, FubuMVC.Localization, FubuMVC.Authentication, FubuMVC.Authentication.Windows, FubuMVC.Navigation, FubuMVC.Ajax, FubuMVC.AntiForgery, FubuMVC.Json (Newtonsoft.Json is now the default), part of Bottles, and a replacement for FubuMVC.Instrumentation. FubuMVC.Core also includes what was FubuValidation and FubuLocalization
- FubuMVC.RavenDb -- What was FubuPersistence, FubuMVC.RavenDb, FubuTransportation.RavenDb, and FubuMVC.PersistedMembership
- JasperService -- what was BottleServiceRunner. TopShelf adapter for FubuMVC 3 apps.
In addition, FubuMVC.Katana and FubuMVC.NOWIN were both eliminated in favor of very small IHost
classes that purely use reflection to bootstrap and shutdown Katana or NOWIN embedded servers.
Bootstrapping was considerably streamlined and very much optimized for 3.0. Everything is defined through the FubuRegistry
for your application now. IApplicationSource
, FubuApplication
, and the old IContainerFacility
services were folded into FubuRegistry
. FubuMVC 3 only runs on StructureMap 4.*.
PackageRegistry
is now gone as well, but most of it is exposed off of the FubuRuntime
object for your application.
See this blog post
FubuMVC 3.0 completely discarded all IoC container abstractions (ObjectDef, IContainerFacility, etc) and strictly relies on StructureMap directly. There is still a ServiceRegistry
class that just adds the old FubuMVC-specific registration usages on top of the StructureMap Registry
class.
About half of Bottles was merged into FubuMVC.Core itself. Activators & Deactivators were retained with different namespaces. Anything to do w/ Zip bottles was left behind. You are no longer able to embed content with the old web-package.zip file scheme.
- [Symmetric/AsymmetricJson]
- Field access security
- Content extensions (totally awesome back in '10, almost completely irrelevant now)
- Html conventions
- Doughnut Caching
- Chain forwarding inside of UrlRegistry
- Open template Url patterns -- superseded in 2.0 by the new JavascriptRoutes anyway
- The base class for
Policy
. FubuMVC 3 tried hard to makeBehaviorGraph
easier to work with
View resolution is only done through the view model type now. Actionless views are no longer automatic and have to be explicitly registered with either a [UrlPattern] or [ViewSubject] attribute on the input model for the view you want to be "actionless"
The Serenity model is significantly different (and improved!?!). FubuMvcSystem
was replaced by SerenitySystem
. SerenitySystem
has hooks for BeforeEach
, BeforeAll
, AfterEach
, and AfterAll
for easier setup, cleanup, and performance assertions. The Serenity code is in the FubuMVC repository now in GitHub. What was FubuTransportation.Serenity and FubuMVC.Authentication.Serenity were all merged into Serenity. Serenity now runs each test in an isolated child container to avoid pollution of mocks and stubs in the StructureMap container between tests.