简体   繁体   English

Azure SQL V12的最佳流利NHibernate配置?

[英]Best fluent NHibernate configuration for Azure SQL V12?

I am looking to configure Fluent NHibernate with Azure SQL V12. 我想用Azure SQL V12配置Fluent NHibernate。 In the various posts online that I have seen, the configuration seems to be using MsSqlConfiguration.MsSql2008 . 在网上看到的各种帖子中,配置似乎正在使用MsSqlConfiguration.MsSql2008 If I understand it correctly, the newer MsSqlConfiguration.MsSql2012 should make use of some of the new features in SQL Server 2012+. 如果我正确理解,则较新的MsSqlConfiguration.MsSql2012应该利用SQL Server 2012+中的一些新功能。 Could you please advise if this works correctly without issues? 您能告诉我这是否可以正常工作吗? Could you please point me at some documentation if available or provide full session factory configuration for comparison? 您能否指出一些可用的文档,或者提供完整的会话工厂配置以进行比较?

I have tested this basic configuration which seems to be ok with simple SQL statements: 我已经测试了这种基本配置,使用简单的SQL语句似乎可以:

var sessionfactory = Fluently.Configure()
            .Database(MsSqlConfiguration.MsSql2012.ConnectionString(_databaseSettings.ConnectionString))
            .Mappings(m => m.AutoMappings
                .Add(AutoMap.AssemblyOf<TestEntity>()
                .Where(a => a.Namespace.EndsWith("Entities"))
                .UseOverridesFromAssemblyOf<TestEntityMappingOverride>()))
            .BuildSessionFactory();

I am using FluentNHibernate version="2.0.3.0" and NHibernate version="4.0.4.4000" 我正在使用FluentNHibernate version="2.0.3.0"NHibernate version="4.0.4.4000"

对于那些仍然感兴趣的人来说,这只是一个更新,接近问题中显示的配置的配置已在生产中正常工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 使用适用于 .Net 的 Azure Bob Storage v12 SDK 进行加密 - Encryption with Azure Bob Storage v12 SDK for .Net Azure Blob 存储 SDK v12 - BlobClient DownloadAsync 消失了吗? - Azure Blob Storage SDK v12 - BlobClient DownloadAsync gone? 如何使用 Azure.Storage v12 SDK 从 Azure Blob 中删除元数据? - How can I remove metadata from an Azure Blob using Azure.Storage v12 SDK? 在Azure Studio V12数据库的Visual Studio 2012中未加载SSDT项目 - SSDT project not loading in visual studio 2012 for azure v12 database v12 .NET SDK 中的 Azure Storage BlobClient 和 BlockBlobClient 有什么区别? - What is the difference between the Azure Storage BlobClient and BlockBlobClient in v12 .NET SDK? 使用 .NET v12 SDK 获取发送到 Azure 队列的消息的 messageId - Get messageId of message sent to Azure queue with .NET v12 SDK Azure Blob 存储使用 Key Vault.Net v12 解密 SDK - Azure Blob Storage Decrypt Using Key Vault .Net v12 SDK 上传大文件 Azure Blob .net SDK v12 问题 - Upload Larget File Azure Blob .net SDK v12 Problem 使用 Azure 下载 Blob Blob 存储客户端库 v12 for .NET - Download blob using Azure Blob storage client library v12 for .NET 使用Fluent NHibernate执行Sql语句 - Executing Sql statements with Fluent NHibernate
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM