I just had a play around with Umbraco 9 beta and start coming to terms with the models builder.
The good news is this was quite easy to get up and running and I also didn't find any issues. Here's how I got up and running...
What's changes since Umbraco 7 and Umbraco 8?
1. It appears the types of model builder settings have been renamed.
The model builder settings now have new names.
PureLive => InMemoryAuto
AppData => SourceCodeManual
LiveAppData => SourceCodeAuto
2. The model builder settings are stored in a different location.
As you probably now already know there is no web.config with Umbraco 9. So where are the appSettings stored? These are now stored in the appsettings.json file stored in the project root.
3. Models are now stored in a new directory.
If you are using SourceCodeManual or SourceCodeAuto you will find the models stored within /umbraco/models/.
Using Umbraco 9 Models Builder
So I tested both the SourceCodeManual and the SourceCodeAuto and both worked great. I found no issues. I think I will be using the SourceCodeAuto so I dont have to keep remembering to go into Umbraco Backed / Settings / Models builder to re-build the models.
Changing Umbraco 9 Model Builder Directory
If you are like me and used to storing your models in a different folder or even a different project then you will want to be able to change the models builder directory. The good news this is still available in Umbraco 9. I figured it out of a little trial and error. it works great and I have had no issue since I got up and running.
To change the directory simply add a new property to the appsettings.json file.
I read a comment somewhere in the Umbraco documentation that said....
- Fix for unsafe project names; these are no longer unsafe for namespaces.
- E.g. "Umbraco 9" will now use namespace "Umbraco_9"
I think this is saying that if your other project namespace contains "Umbraco_9" then this will be considered a safe path. This has not been tested so don't hold me to that. I didn't find any documentation around AcceptUnsafeModelsDirectory but I am guessing the old setting will probably work.
I am just adding a further note on the bottom of here since I found some other code references regarding storing your models in a different folder. This is how to set the namespace.