Microsoft now has .NET Core, .NET Framework and Xamarin (Mono) in its .NET family.
微软现在在它的。net家族中有。net核心,。net框架和Xamarin (Mono)。
There seems to be a lot of overlap here. What's the difference between these types of .NET? When should I choose to use .NET Core in my project, instead of .NET Framework or Xamarin?
这里似乎有很多重叠。这些类型的。net有什么不同?什么时候我应该在我的项目中使用。net Core,而不是。net框架或者Xamarin?
4 个解决方案
#1
164
You should use .NET Core, instead of .NET Framework or Xamarin, in the following 6 typical scenarios according to the documentation here.
根据本文的文档,您应该在以下6个典型场景中使用. net Core,而不是. net框架或Xamarin。
1. Cross-Platform needs
Clearly, if your goal is to have an application (web/service) that should be able to run across platforms (Windows, Linux and MacOS), the best choice in the .NET ecosystem is to use .NET Core as its runtime (CoreCLR) and libraries are cross-platform. The other choice is to use the Mono Project.
显然,如果您的目标是拥有一个能够跨平台运行的应用程序(web/服务)(Windows、Linux和MacOS),那么. net生态系统的最佳选择就是使用. net Core作为运行时(CoreCLR),而库是跨平台的。另一个选择是使用Mono项目。
Both choices are open source, but .NET Core is directly and officially supported by Microsoft and will have a heavy investment moving forward.
这两种选择都是开源的,但是。net Core是由微软直接和官方支持的,未来将会有大量的投资。
When using .NET Core across platforms, the best development experience exists on Windows with the Visual Studio IDE which supports many productivity features including project management, debugging, source control, refactoring, rich editing including Intellisense, testing and much more. But rich development is also supported using Visual Studio Code on Mac, Linux and Windows including intellisense and debugging. Even third party editors like Sublime, Emacs, VI and more work well and can get editor intellisense using the open source Omnisharp project.
当跨平台使用。net Core时,最好的开发体验是在Windows上使用Visual Studio IDE,它支持许多生产力特性,包括项目管理、调试、源代码控制、重构、智能感知、测试等等。但富开发也支持在Mac、Linux和Windows上使用Visual Studio代码,包括智能感知和调试。甚至第三方编辑,如崇高,Emacs, VI和更多的工作,可以通过开源的Omnisharp项目得到编辑智能感知。
2. Microservices
When you are building a microservices oriented system composed of multiple independent, dynamically scalable, stateful or stateless microservices, the great advantage that you have here is that you can use different technologies/frameworks/languages at a microservice level. That allows you to use the best approach and technology per micro areas in your system, so if you want to build very performant and scalable microservices, you should use .NET Core. Eventually, if you need to use any .NET Framework library that is not compatible with .NET Core, there’s no issue, you can build that microservice with the .NET Framework and in the future you might be able to substitute it with the .NET Core.
当您正在构建一个面向微服务的系统,该系统由多个独立的、动态可伸缩的、有状态的或无状态的微服务组成时,您在这里拥有的最大优势是您可以在微服务级别上使用不同的技术/框架/语言。这使您可以在系统的每个微区域使用最佳的方法和技术,所以如果您想构建非常高性能和可伸缩的微服务,您应该使用。net Core。最终,如果您需要使用任何与。net Core不兼容的。net框架库,那就没有问题了,您可以使用。net框架构建微服务,将来您可能可以用。net核心替代它。
The infrastructure platform you could use are many. Ideally, for large and complex microservice systems, you should use Azure Service Fabric. But for stateless microservices you can also use other products like Azure App Service or Azure Functions.
您可以使用的基础设施平台有很多。理想情况下,对于大型和复杂的微服务系统,应该使用Azure服务结构。但是对于无状态微服务,您还可以使用其他产品,如Azure应用程序服务或Azure函数。
Note that as of June 2016, not every technology within Azure supports the .NET Core, but .NET Core support in Azure will be increasing dramatically now that .NET Core is RTM released.
请注意,到2016年6月,并不是Azure中的每一项技术都支持。net Core,但是随着。net Core RTM的发布,Azure中的。net Core支持将会显著增加。
3. Best performant and scalable systems
When your system needs the best possible performance and scalability so you get the best responsiveness no matter how many users you have, then is where .NET Core and ASP.NET Core really shine. The more you can do with the same amount of infrastructure/hardware, the richer the experience you’ll have for your end users – at a lower cost.
当你的系统需要最好的性能和可扩展性,无论你有多少用户,你都能得到最好的响应,那么。net Core和ASP就在这里。网络核心真的闪闪发光。您对相同数量的基础设施/硬件做的越多,您对最终用户的体验就越丰富,而且成本更低。
The days of Moore’s law performance improvements for single CPUs does not apply anymore; yet you need to do more while your system is growing and need higher scalability and performance for everyday’ s more demanding users which are growing exponentially in numbers. You need to get more efficient, optimize everywhere, and scale better across clusters of machines, VMs and CPU cores, ultimately. It is not just a matter of user’s satisfaction; it can also make a huge difference in cost/TCO. This is why it is important to strive for performance and scalability.
摩尔定律对单个cpu性能的改进不再适用;然而,当您的系统不断增长时,您需要做更多的工作,并且需要更高的可扩展性和性能,以满足日益增长的用户的需求。您需要获得更高的效率,在所有地方进行优化,并最终在机器、vm和CPU内核的集群中更好地扩展。这不仅仅是用户满意度的问题;它也可以在成本/TCO上产生巨大的差异。这就是为什么要为性能和可伸缩性而努力的原因。
As mentioned, if you can isolate small pieces of your system as microservices or any other loosely-coupled approach, it’ll be better as you’ll be able to not just evolve each small piece/microservice independently and have a better long-term agility and maintenance, but also you’ll be able to use any other technology at a microservice level if what you need to do is not compatible with .NET Core. And eventually you’d be able to refactor it and bring it to .NET Core when possible.
正如前面提到的,如果你能隔离系统的小块microservices或任何其他松耦合方法一样,它会更好,你可以不仅仅是发展每个小块/ microservice独立和有一个更好的长期的敏捷性和维护,而且你可以使用任何其他技术在microservice级别如果你需要做的是不兼容的。net核心。最终你将能够重构它并在可能的情况下将它带到。net核心。
4. Command line style development for Mac, Linux or Windows.
This approach is optional when using .NET Core. You can also use the full Visual Studio IDE, of course. But if you are a developer that wants to develop with lightweight editors and heavy use of command line, .NET Core is designed for CLI. It provides simple command line tools available on all supported platforms, enabling developers to build and test applications with a minimal installation on developer, lab or production machines. Editors like Visual Studio Code use the same command line tools for their development experiences. And IDE’s like Visual Studio use the same CLI tools but hide them behind a rich IDE experience. Developers can now choose the level they want to interact with the tool chain from CLI to editor to IDE.
这种方法在使用。net Core时是可选的。当然,您也可以使用完整的Visual Studio IDE。但是,如果您是一个希望使用轻量级编辑器和大量使用命令行进行开发的开发人员,. net Core是为CLI设计的。它提供了在所有受支持平台上都可用的简单命令行工具,使开发人员能够在开发人员、实验室或生产机器上使用最少的安装来构建和测试应用程序。像Visual Studio代码这样的编辑器在开发体验中使用相同的命令行工具。IDE就像Visual Studio使用相同的CLI工具,但是隐藏在丰富的IDE体验之后。开发人员现在可以选择他们想要与从CLI到editor到IDE的工具链交互的级别。
5. Need side by side of .NET versions per application level.
If you want to be able to install applications with dependencies on different versions of frameworks in .NET, you need to use .NET Core which provides 100% side-by side as explained previously in this document.
如果您希望能够在. net中安装依赖于不同版本框架的应用程序,您需要使用. net Core,它提供100%的支持,如本文前面所述。
6. Windows 10 UWP .NET apps.
In addition, you may also want to read:
此外,你也可以阅读:
- When should I NOT use .NET Core?
- 我什么时候不应该使用。net核心?
- When should I still use .NET Framework 4.x, instead of .NET Core?
- 什么时候我还应该使用。net Framework 4。x,而不是。net核心?
- When should I use Xamarin, instead of .NET Core?
- 什么时候应该使用Xamarin而不是。net Core?
#2
121
This is how Microsoft explains it:
微软是这样解释的:
.NET Framework is the "full" or "traditional" flavor of .NET that's distributed with Windows. Use this when you are building a desktop Windows or UWP app, or working with older ASP.NET 4.6+.
. net框架是随Windows一起发布的。net的“完整”或“传统”风格。当您正在构建桌面窗口或UWP应用程序,或使用旧的ASP时,请使用此功能。NET 4.6 +。
.NET Core is cross-platform .NET that runs on Windows, Mac, and Linux. Use this when you want to build console or web apps that can run on any platform, including inside Docker containers. This does not include UWP/desktop apps currently.
. net Core是在Windows、Mac和Linux上运行的跨平台。net。当您想要构建可以在任何平台上运行的控制台或web应用程序(包括Docker容器)时,请使用此功能。目前这还不包括UWP/桌面应用程序。
Xamarin is used for building mobile apps that can run on iOS, Android, or Windows Phone devices.
Xamarin用于开发可以在iOS、Android或Windows Phone设备上运行的移动应用。
Xamarin usually runs on top of Mono, which is a version of .NET that was built for cross-platform support before Microsoft decided to officially go cross-platform with .NET Core. Like Xamarin, the Unity platform also runs on top of Mono.
Xamarin通常运行在Mono之上,Mono是。net的一个版本,在微软决定正式使用。net Core进行跨平台支持之前,它是为跨平台支持而构建的。与Xamarin一样,Unity平台也运行在Mono之上。
A common point of confusion is where ASP.NET Core fits in. ASP.NET Core can run on top of either .NET Framework (Windows) or .NET Core (cross-platform), as detailed in this answer: Difference between ASP.NET Core (.NET Core) and ASP.NET Core (.NET Framework)
混淆的一个共同点是ASP在哪里。网络核心符合。ASP。NET Core可以运行在。NET Framework (Windows)或。NET Core(跨平台)之上,如这个答案所示:ASP之间的差异。核心(净。网络核心)和ASP。核心(净。净框架)
#3
7
You can refer in this line - Difference between ASP.NET Core (.NET Core) and ASP.NET Core (.NET Framework)
您可以在这行中引用ASP之间的差异。核心(净。网络核心)和ASP。核心(净。净框架)
Xamarin is not a debate at all. When you want to build mobile (iOS, Android, and Windows Mobile) apps using C#, Xamarin is your only choice.
海蓝宝石根本不是一场辩论。当你想要使用c#构建移动应用(iOS、Android和Windows mobile)时,Xamarin是你唯一的选择。
The .NET Framework supports Windows and Web applications. Today, you can use Windows Forms, WPF, and UWP to build Windows applications in .NET Framework. ASP.NET MVC is used to build Web applications in .NET Framework.
. net框架支持Windows和Web应用程序。现在,您可以使用Windows窗体、WPF和UWP在. net框架中构建Windows应用程序。ASP。NET MVC用于在。NET框架中构建Web应用程序。
.NET Core is the new open-source and cross-platform framework to build applications for all operating system including Windows, Mac, and Linux. .NET Core supports UWP and ASP.NET Core only. UWP is used to build Windows 10 targets Windows and mobile applications. ASP.NET Core is used to build browser based web applications.
. net Core是一个新的开源和跨平台框架,用于为包括Windows、Mac和Linux在内的所有操作系统构建应用程序。. net Core支持UWP和ASP。网络核心。UWP用于构建针对Windows和移动应用的Windows 10。ASP。NET Core用于构建基于浏览器的web应用程序。
you want more details refer this links
https://blogs.msdn.microsoft.com/dotnet/2016/07/15/net-core-roadmap/ https://docs.microsoft.com/en-us/dotnet/articles/standard/choosing-core-framework-server
您想要了解更多的细节,请参考以下链接:https://blogs.msdn.microsoft.com/dotnet6/07/15/net -core-roadmap/ https://docs.microsoft.com/en-us/dotnet/articles/standard/choosing-core- frameworkserver
#4
1
It's been upgrading the .NET Framework regularly to satisfy the emerging trends in applications creation. However, Microsoft recently redesigned the center design of this .NET Framework to simplify testing, development, and installation of contemporary software programs.
它定期升级。net框架以满足应用程序创建的新趋势。然而,微软最近重新设计了这个。net框架的中心设计,以简化当代软件程序的测试、开发和安装。
Contrary to .NET Framework, .NET Core is equally open source and cross platform. It further will come with various new features to simplify testing and development of desktop, internet cloud, and cellular applications. In addition, it enables developers to set up the software in several of means. However, .NET Core doesn't support all functionalities and features of both .NET Framework. Consequently, it will become essential for programmers to comprehend the significant differences between .NET Framework and also .NET Core before shifting into the latest variant of the popular applications frame.
与。net框架相反,。net核心是开源的,是跨平台的。它还将提供各种新特性,以简化桌面、互联网云和蜂窝应用程序的测试和开发。此外,它还允许开发人员以多种方式设置软件。但是。net Core并不支持这两个。net框架的所有功能和特性。因此,在转换到流行的应用程序框架的最新版本之前,程序员必须了解。net框架和。net Core之间的显著差异。
Recognizing Major Differences involving .NET Core and .NET Framework
认识到。net Core和。net框架的主要区别
Open Source: .NET Framework has been released as a certified and proprietary applications frame. However, the firm has introduced .NET Core within an open source program framework. Consequently, both individual and enterprise programmers can build programs with .NET Core without even paying any licensing fees.
开源:. net框架已经作为一个认证的和私有的应用程序框架发布。然而,该公司在一个开源程序框架中引入了。net Core。因此,个人和企业程序员都可以使用。net Core构建程序,而无需支付任何许可费。
Cross-Platform: .NET Framework enabled programmers to construct applications for one stage -- Windows. The compatibility makes it a lot easier for programmers to construct cross-platform software, and interface their present applications from one platform to the next.
跨平台:. net框架使程序员能够为一个阶段——Windows构建应用程序。兼容性使程序员更容易构建跨平台的软件,并将他们当前的应用程序从一个平台连接到另一个平台。
The programmers are needed to compile Nuget packs within .NET Core. Additionally, the may compile the Nuget packs right into the program or set them in a folder in the program.
需要程序员在。net Core中编译Nuget包。此外,may将Nuget包直接编译到程序中,或者将它们设置在程序中的文件夹中。
Modular Assortment of Libraries: The two .NET Frame and .NET Core Enables programmers to benefit from strong class libraries. However, .NET Core employs a common language runtime named CoreCLR, and comes with a modular selection of libraries known as CoreFX. Thus, the programmers have choice to select and use just the libraries needed by each program, and improve the program's performance by eliminating unnecessary libraries.
模块化的库分类:. net框架和。net核心允许程序员从强大的类库中获益。然而,. net Core使用了一个名为CoreCLR的通用语言运行时,并附带了一个名为CoreFX的模块化库选择。因此,程序员可以选择只选择每个程序所需的库,并通过消除不必要的库来提高程序的性能。
Software Designs: .NET Framework and .NET Core differs from every other in the Class of program versions.
软件设计:. net框架和。net核心在程序版本的类中各不相同。
Each Edition of .NET Framework utilizes a Particular variant of .NET Standard Library.
每个版本的。net框架都使用了。net标准库的一个特殊变体。
ASP.NET: whilst utilizing internet programs with .NET Framework, the programmers have choice to utilize a strong web application framework such as ASP.NET. However, .NET Core Includes a redesigned variant of ASP.NET. The programmers are now able to utilize ASP.NET Core to construct both cloud and web software.
ASP。NET:当使用。NET框架的internet程序时,程序员可以选择使用强大的web应用程序框架,比如ASP.NET。然而,. net核心包含了重新设计的ASP.NET版本。程序员现在可以使用ASP了。NET核心构建云和web软件。
Deployment Options: whilst utilizing .NET Framework, programmers need to set up web software simply on Internet Information Server. However, the net software developed with ASP.NET Core may be hosted in several of means. The programmers may set up the ASP.NET Core software right from your cloud or self-host the program by producing their very own hosting procedure.
部署选项:当使用。net框架时,程序员需要在Internet Information Server上简单地设置web软件。但是,net软件是用ASP开发的。NET Core可以以多种方式承载。程序员可以设置ASP。NET核心软件直接从您的云或自托管程序,通过产生自己的托管过程。
Cloud Ready Configuration: Contrary to .NET Framework, .NET Core is equipped with features to simplify installation and development of cloud-based program. The programmers can utilize ASP.NET to construct many different cloud-based software instantly. Furthermore, they could print the software straight into the cloud from availing the cloud-ready settings contained in ASP.NET Core.
云准备配置:与. net框架相反,. net Core提供的特性简化了基于云的程序的安装和开发。程序员可以使用ASP。立即构建许多不同的基于云的软件。此外,他们还可以将软件直接打印到云上,从而可以从ASP中获取云计算的设置。净的核心。
Mobile App Development: .NET Framework doesn't incorporate any strong frame or applications to simplify mobile program development. However, .NET Core harmonious with Xamarin throughout the .NET Standard Library. Consequently, developers are able to make the most of Xamarin to compose cross mobile programs in C# using a shared code base and also identical group of APIs. They could likewise use the resources supplied by Xamarin to personalize the cell program for different mobile platforms such as iOS, Android and also Windows Phone.
移动应用程序开发:. net框架不包含任何强大的框架或应用程序来简化移动程序开发。然而,在。net标准库中,. net核心与Xamarin是和谐的。因此,开发人员能够充分利用Xamarin,使用共享代码库和相同的api组在c#中编写跨移动程序。他们还可以使用Xamarin提供的资源,为不同的移动平台(如iOS、Android和Windows Phone)定制手机程序。
Microservices: Contrary to .NET Framework, .NET Core makes it a lot easier for programmers to construct microservice oriented programs quickly. Therefore systems incorporate lots of dynamic and independent microservices, the programmers need to concentrate on individual microservices. .NET Core empowers developers to develop custom made microservices utilizing altering programming languages, technology and frameworks. Additionally, the programmers can construct a strong system by blending numerous microservices seamlessly.
微服务:与。net框架相反,. net Core让程序员更容易快速地构建面向微服务的程序。因此,系统集成了大量的动态和独立的微服务,程序员需要专注于单个的微服务。net Core使开发人员能够利用改变的编程语言、技术和框架开发定制的微服务。此外,程序员可以通过无缝地混合许多微服务来构建一个强大的系统。
Performance and Scalability: Scalability .NET Core is significantly more Powerful than .NET Framework to Improve the performance and scalability of software. It empowers programmers to boost the operation of software radically without deploying additional hardware or infrastructure. In addition, it enables programmers to build, deploy and test software directly from the cloud. Thus, the programmers can change to .NET Core to improve the performance and scalability of the applications without placing extra time and energy.
性能和可扩展性:. net核心要比。net框架强大得多,可以提高软件的性能和可扩展性。它使程序员能够在不部署额外硬件或基础设施的情况下从根本上促进软件的操作。此外,它还允许程序员直接从云中构建、部署和测试软件。因此,程序员可以更改为. net Core,以提高应用程序的性能和可扩展性,而无需花费额外的时间和精力。
NET Core doesn't support all the features and functionalities offered by the most recent edition of .NET Framework. However, it may be utilized as a subset of these .NET Framework. Additionally, .NET Core remains compatible with .NET Framework throughout the . Thus, the programmers may still run the software developed with .NET Framework after updating to .NET Core.
NET Core不支持最新版本的。NET Framework提供的所有特性和功能。但是,它可以作为这些。net框架的一个子集使用。此外,. net Core始终与。net框架兼容。因此,在更新到。net Core之后,程序员仍然可以运行使用。net框架开发的软件。
Overall, .NET Core is your upgraded and updated version of .NET Framework. The .Net programmers can update to .NET Core to create an assortment of programs by targeting several platforms and devices. Moreover, they are able to benefit from the newest features and improvements contained in .NET Core to construct, test, and set up the software efficiently and quickly.
总的来说,. net Core是. net框架的升级和更新版本。. net程序员可以更新到。net Core,通过针对多个平台和设备创建各种程序。此外,他们能够从。net Core中包含的最新特性和改进中获益,从而高效、快速地构建、测试和设置软件。
#1
164
You should use .NET Core, instead of .NET Framework or Xamarin, in the following 6 typical scenarios according to the documentation here.
根据本文的文档,您应该在以下6个典型场景中使用. net Core,而不是. net框架或Xamarin。
1. Cross-Platform needs
Clearly, if your goal is to have an application (web/service) that should be able to run across platforms (Windows, Linux and MacOS), the best choice in the .NET ecosystem is to use .NET Core as its runtime (CoreCLR) and libraries are cross-platform. The other choice is to use the Mono Project.
显然,如果您的目标是拥有一个能够跨平台运行的应用程序(web/服务)(Windows、Linux和MacOS),那么. net生态系统的最佳选择就是使用. net Core作为运行时(CoreCLR),而库是跨平台的。另一个选择是使用Mono项目。
Both choices are open source, but .NET Core is directly and officially supported by Microsoft and will have a heavy investment moving forward.
这两种选择都是开源的,但是。net Core是由微软直接和官方支持的,未来将会有大量的投资。
When using .NET Core across platforms, the best development experience exists on Windows with the Visual Studio IDE which supports many productivity features including project management, debugging, source control, refactoring, rich editing including Intellisense, testing and much more. But rich development is also supported using Visual Studio Code on Mac, Linux and Windows including intellisense and debugging. Even third party editors like Sublime, Emacs, VI and more work well and can get editor intellisense using the open source Omnisharp project.
当跨平台使用。net Core时,最好的开发体验是在Windows上使用Visual Studio IDE,它支持许多生产力特性,包括项目管理、调试、源代码控制、重构、智能感知、测试等等。但富开发也支持在Mac、Linux和Windows上使用Visual Studio代码,包括智能感知和调试。甚至第三方编辑,如崇高,Emacs, VI和更多的工作,可以通过开源的Omnisharp项目得到编辑智能感知。
2. Microservices
When you are building a microservices oriented system composed of multiple independent, dynamically scalable, stateful or stateless microservices, the great advantage that you have here is that you can use different technologies/frameworks/languages at a microservice level. That allows you to use the best approach and technology per micro areas in your system, so if you want to build very performant and scalable microservices, you should use .NET Core. Eventually, if you need to use any .NET Framework library that is not compatible with .NET Core, there’s no issue, you can build that microservice with the .NET Framework and in the future you might be able to substitute it with the .NET Core.
当您正在构建一个面向微服务的系统,该系统由多个独立的、动态可伸缩的、有状态的或无状态的微服务组成时,您在这里拥有的最大优势是您可以在微服务级别上使用不同的技术/框架/语言。这使您可以在系统的每个微区域使用最佳的方法和技术,所以如果您想构建非常高性能和可伸缩的微服务,您应该使用。net Core。最终,如果您需要使用任何与。net Core不兼容的。net框架库,那就没有问题了,您可以使用。net框架构建微服务,将来您可能可以用。net核心替代它。
The infrastructure platform you could use are many. Ideally, for large and complex microservice systems, you should use Azure Service Fabric. But for stateless microservices you can also use other products like Azure App Service or Azure Functions.
您可以使用的基础设施平台有很多。理想情况下,对于大型和复杂的微服务系统,应该使用Azure服务结构。但是对于无状态微服务,您还可以使用其他产品,如Azure应用程序服务或Azure函数。
Note that as of June 2016, not every technology within Azure supports the .NET Core, but .NET Core support in Azure will be increasing dramatically now that .NET Core is RTM released.
请注意,到2016年6月,并不是Azure中的每一项技术都支持。net Core,但是随着。net Core RTM的发布,Azure中的。net Core支持将会显著增加。
3. Best performant and scalable systems
When your system needs the best possible performance and scalability so you get the best responsiveness no matter how many users you have, then is where .NET Core and ASP.NET Core really shine. The more you can do with the same amount of infrastructure/hardware, the richer the experience you’ll have for your end users – at a lower cost.
当你的系统需要最好的性能和可扩展性,无论你有多少用户,你都能得到最好的响应,那么。net Core和ASP就在这里。网络核心真的闪闪发光。您对相同数量的基础设施/硬件做的越多,您对最终用户的体验就越丰富,而且成本更低。
The days of Moore’s law performance improvements for single CPUs does not apply anymore; yet you need to do more while your system is growing and need higher scalability and performance for everyday’ s more demanding users which are growing exponentially in numbers. You need to get more efficient, optimize everywhere, and scale better across clusters of machines, VMs and CPU cores, ultimately. It is not just a matter of user’s satisfaction; it can also make a huge difference in cost/TCO. This is why it is important to strive for performance and scalability.
摩尔定律对单个cpu性能的改进不再适用;然而,当您的系统不断增长时,您需要做更多的工作,并且需要更高的可扩展性和性能,以满足日益增长的用户的需求。您需要获得更高的效率,在所有地方进行优化,并最终在机器、vm和CPU内核的集群中更好地扩展。这不仅仅是用户满意度的问题;它也可以在成本/TCO上产生巨大的差异。这就是为什么要为性能和可伸缩性而努力的原因。
As mentioned, if you can isolate small pieces of your system as microservices or any other loosely-coupled approach, it’ll be better as you’ll be able to not just evolve each small piece/microservice independently and have a better long-term agility and maintenance, but also you’ll be able to use any other technology at a microservice level if what you need to do is not compatible with .NET Core. And eventually you’d be able to refactor it and bring it to .NET Core when possible.
正如前面提到的,如果你能隔离系统的小块microservices或任何其他松耦合方法一样,它会更好,你可以不仅仅是发展每个小块/ microservice独立和有一个更好的长期的敏捷性和维护,而且你可以使用任何其他技术在microservice级别如果你需要做的是不兼容的。net核心。最终你将能够重构它并在可能的情况下将它带到。net核心。
4. Command line style development for Mac, Linux or Windows.
This approach is optional when using .NET Core. You can also use the full Visual Studio IDE, of course. But if you are a developer that wants to develop with lightweight editors and heavy use of command line, .NET Core is designed for CLI. It provides simple command line tools available on all supported platforms, enabling developers to build and test applications with a minimal installation on developer, lab or production machines. Editors like Visual Studio Code use the same command line tools for their development experiences. And IDE’s like Visual Studio use the same CLI tools but hide them behind a rich IDE experience. Developers can now choose the level they want to interact with the tool chain from CLI to editor to IDE.
这种方法在使用。net Core时是可选的。当然,您也可以使用完整的Visual Studio IDE。但是,如果您是一个希望使用轻量级编辑器和大量使用命令行进行开发的开发人员,. net Core是为CLI设计的。它提供了在所有受支持平台上都可用的简单命令行工具,使开发人员能够在开发人员、实验室或生产机器上使用最少的安装来构建和测试应用程序。像Visual Studio代码这样的编辑器在开发体验中使用相同的命令行工具。IDE就像Visual Studio使用相同的CLI工具,但是隐藏在丰富的IDE体验之后。开发人员现在可以选择他们想要与从CLI到editor到IDE的工具链交互的级别。
5. Need side by side of .NET versions per application level.
If you want to be able to install applications with dependencies on different versions of frameworks in .NET, you need to use .NET Core which provides 100% side-by side as explained previously in this document.
如果您希望能够在. net中安装依赖于不同版本框架的应用程序,您需要使用. net Core,它提供100%的支持,如本文前面所述。
6. Windows 10 UWP .NET apps.
In addition, you may also want to read:
此外,你也可以阅读:
- When should I NOT use .NET Core?
- 我什么时候不应该使用。net核心?
- When should I still use .NET Framework 4.x, instead of .NET Core?
- 什么时候我还应该使用。net Framework 4。x,而不是。net核心?
- When should I use Xamarin, instead of .NET Core?
- 什么时候应该使用Xamarin而不是。net Core?
#2
121
This is how Microsoft explains it:
微软是这样解释的:
.NET Framework is the "full" or "traditional" flavor of .NET that's distributed with Windows. Use this when you are building a desktop Windows or UWP app, or working with older ASP.NET 4.6+.
. net框架是随Windows一起发布的。net的“完整”或“传统”风格。当您正在构建桌面窗口或UWP应用程序,或使用旧的ASP时,请使用此功能。NET 4.6 +。
.NET Core is cross-platform .NET that runs on Windows, Mac, and Linux. Use this when you want to build console or web apps that can run on any platform, including inside Docker containers. This does not include UWP/desktop apps currently.
. net Core是在Windows、Mac和Linux上运行的跨平台。net。当您想要构建可以在任何平台上运行的控制台或web应用程序(包括Docker容器)时,请使用此功能。目前这还不包括UWP/桌面应用程序。
Xamarin is used for building mobile apps that can run on iOS, Android, or Windows Phone devices.
Xamarin用于开发可以在iOS、Android或Windows Phone设备上运行的移动应用。
Xamarin usually runs on top of Mono, which is a version of .NET that was built for cross-platform support before Microsoft decided to officially go cross-platform with .NET Core. Like Xamarin, the Unity platform also runs on top of Mono.
Xamarin通常运行在Mono之上,Mono是。net的一个版本,在微软决定正式使用。net Core进行跨平台支持之前,它是为跨平台支持而构建的。与Xamarin一样,Unity平台也运行在Mono之上。
A common point of confusion is where ASP.NET Core fits in. ASP.NET Core can run on top of either .NET Framework (Windows) or .NET Core (cross-platform), as detailed in this answer: Difference between ASP.NET Core (.NET Core) and ASP.NET Core (.NET Framework)
混淆的一个共同点是ASP在哪里。网络核心符合。ASP。NET Core可以运行在。NET Framework (Windows)或。NET Core(跨平台)之上,如这个答案所示:ASP之间的差异。核心(净。网络核心)和ASP。核心(净。净框架)
#3
7
You can refer in this line - Difference between ASP.NET Core (.NET Core) and ASP.NET Core (.NET Framework)
您可以在这行中引用ASP之间的差异。核心(净。网络核心)和ASP。核心(净。净框架)
Xamarin is not a debate at all. When you want to build mobile (iOS, Android, and Windows Mobile) apps using C#, Xamarin is your only choice.
海蓝宝石根本不是一场辩论。当你想要使用c#构建移动应用(iOS、Android和Windows mobile)时,Xamarin是你唯一的选择。
The .NET Framework supports Windows and Web applications. Today, you can use Windows Forms, WPF, and UWP to build Windows applications in .NET Framework. ASP.NET MVC is used to build Web applications in .NET Framework.
. net框架支持Windows和Web应用程序。现在,您可以使用Windows窗体、WPF和UWP在. net框架中构建Windows应用程序。ASP。NET MVC用于在。NET框架中构建Web应用程序。
.NET Core is the new open-source and cross-platform framework to build applications for all operating system including Windows, Mac, and Linux. .NET Core supports UWP and ASP.NET Core only. UWP is used to build Windows 10 targets Windows and mobile applications. ASP.NET Core is used to build browser based web applications.
. net Core是一个新的开源和跨平台框架,用于为包括Windows、Mac和Linux在内的所有操作系统构建应用程序。. net Core支持UWP和ASP。网络核心。UWP用于构建针对Windows和移动应用的Windows 10。ASP。NET Core用于构建基于浏览器的web应用程序。
you want more details refer this links
https://blogs.msdn.microsoft.com/dotnet/2016/07/15/net-core-roadmap/ https://docs.microsoft.com/en-us/dotnet/articles/standard/choosing-core-framework-server
您想要了解更多的细节,请参考以下链接:https://blogs.msdn.microsoft.com/dotnet6/07/15/net -core-roadmap/ https://docs.microsoft.com/en-us/dotnet/articles/standard/choosing-core- frameworkserver
#4
1
It's been upgrading the .NET Framework regularly to satisfy the emerging trends in applications creation. However, Microsoft recently redesigned the center design of this .NET Framework to simplify testing, development, and installation of contemporary software programs.
它定期升级。net框架以满足应用程序创建的新趋势。然而,微软最近重新设计了这个。net框架的中心设计,以简化当代软件程序的测试、开发和安装。
Contrary to .NET Framework, .NET Core is equally open source and cross platform. It further will come with various new features to simplify testing and development of desktop, internet cloud, and cellular applications. In addition, it enables developers to set up the software in several of means. However, .NET Core doesn't support all functionalities and features of both .NET Framework. Consequently, it will become essential for programmers to comprehend the significant differences between .NET Framework and also .NET Core before shifting into the latest variant of the popular applications frame.
与。net框架相反,。net核心是开源的,是跨平台的。它还将提供各种新特性,以简化桌面、互联网云和蜂窝应用程序的测试和开发。此外,它还允许开发人员以多种方式设置软件。但是。net Core并不支持这两个。net框架的所有功能和特性。因此,在转换到流行的应用程序框架的最新版本之前,程序员必须了解。net框架和。net Core之间的显著差异。
Recognizing Major Differences involving .NET Core and .NET Framework
认识到。net Core和。net框架的主要区别
Open Source: .NET Framework has been released as a certified and proprietary applications frame. However, the firm has introduced .NET Core within an open source program framework. Consequently, both individual and enterprise programmers can build programs with .NET Core without even paying any licensing fees.
开源:. net框架已经作为一个认证的和私有的应用程序框架发布。然而,该公司在一个开源程序框架中引入了。net Core。因此,个人和企业程序员都可以使用。net Core构建程序,而无需支付任何许可费。
Cross-Platform: .NET Framework enabled programmers to construct applications for one stage -- Windows. The compatibility makes it a lot easier for programmers to construct cross-platform software, and interface their present applications from one platform to the next.
跨平台:. net框架使程序员能够为一个阶段——Windows构建应用程序。兼容性使程序员更容易构建跨平台的软件,并将他们当前的应用程序从一个平台连接到另一个平台。
The programmers are needed to compile Nuget packs within .NET Core. Additionally, the may compile the Nuget packs right into the program or set them in a folder in the program.
需要程序员在。net Core中编译Nuget包。此外,may将Nuget包直接编译到程序中,或者将它们设置在程序中的文件夹中。
Modular Assortment of Libraries: The two .NET Frame and .NET Core Enables programmers to benefit from strong class libraries. However, .NET Core employs a common language runtime named CoreCLR, and comes with a modular selection of libraries known as CoreFX. Thus, the programmers have choice to select and use just the libraries needed by each program, and improve the program's performance by eliminating unnecessary libraries.
模块化的库分类:. net框架和。net核心允许程序员从强大的类库中获益。然而,. net Core使用了一个名为CoreCLR的通用语言运行时,并附带了一个名为CoreFX的模块化库选择。因此,程序员可以选择只选择每个程序所需的库,并通过消除不必要的库来提高程序的性能。
Software Designs: .NET Framework and .NET Core differs from every other in the Class of program versions.
软件设计:. net框架和。net核心在程序版本的类中各不相同。
Each Edition of .NET Framework utilizes a Particular variant of .NET Standard Library.
每个版本的。net框架都使用了。net标准库的一个特殊变体。
ASP.NET: whilst utilizing internet programs with .NET Framework, the programmers have choice to utilize a strong web application framework such as ASP.NET. However, .NET Core Includes a redesigned variant of ASP.NET. The programmers are now able to utilize ASP.NET Core to construct both cloud and web software.
ASP。NET:当使用。NET框架的internet程序时,程序员可以选择使用强大的web应用程序框架,比如ASP.NET。然而,. net核心包含了重新设计的ASP.NET版本。程序员现在可以使用ASP了。NET核心构建云和web软件。
Deployment Options: whilst utilizing .NET Framework, programmers need to set up web software simply on Internet Information Server. However, the net software developed with ASP.NET Core may be hosted in several of means. The programmers may set up the ASP.NET Core software right from your cloud or self-host the program by producing their very own hosting procedure.
部署选项:当使用。net框架时,程序员需要在Internet Information Server上简单地设置web软件。但是,net软件是用ASP开发的。NET Core可以以多种方式承载。程序员可以设置ASP。NET核心软件直接从您的云或自托管程序,通过产生自己的托管过程。
Cloud Ready Configuration: Contrary to .NET Framework, .NET Core is equipped with features to simplify installation and development of cloud-based program. The programmers can utilize ASP.NET to construct many different cloud-based software instantly. Furthermore, they could print the software straight into the cloud from availing the cloud-ready settings contained in ASP.NET Core.
云准备配置:与. net框架相反,. net Core提供的特性简化了基于云的程序的安装和开发。程序员可以使用ASP。立即构建许多不同的基于云的软件。此外,他们还可以将软件直接打印到云上,从而可以从ASP中获取云计算的设置。净的核心。
Mobile App Development: .NET Framework doesn't incorporate any strong frame or applications to simplify mobile program development. However, .NET Core harmonious with Xamarin throughout the .NET Standard Library. Consequently, developers are able to make the most of Xamarin to compose cross mobile programs in C# using a shared code base and also identical group of APIs. They could likewise use the resources supplied by Xamarin to personalize the cell program for different mobile platforms such as iOS, Android and also Windows Phone.
移动应用程序开发:. net框架不包含任何强大的框架或应用程序来简化移动程序开发。然而,在。net标准库中,. net核心与Xamarin是和谐的。因此,开发人员能够充分利用Xamarin,使用共享代码库和相同的api组在c#中编写跨移动程序。他们还可以使用Xamarin提供的资源,为不同的移动平台(如iOS、Android和Windows Phone)定制手机程序。
Microservices: Contrary to .NET Framework, .NET Core makes it a lot easier for programmers to construct microservice oriented programs quickly. Therefore systems incorporate lots of dynamic and independent microservices, the programmers need to concentrate on individual microservices. .NET Core empowers developers to develop custom made microservices utilizing altering programming languages, technology and frameworks. Additionally, the programmers can construct a strong system by blending numerous microservices seamlessly.
微服务:与。net框架相反,. net Core让程序员更容易快速地构建面向微服务的程序。因此,系统集成了大量的动态和独立的微服务,程序员需要专注于单个的微服务。net Core使开发人员能够利用改变的编程语言、技术和框架开发定制的微服务。此外,程序员可以通过无缝地混合许多微服务来构建一个强大的系统。
Performance and Scalability: Scalability .NET Core is significantly more Powerful than .NET Framework to Improve the performance and scalability of software. It empowers programmers to boost the operation of software radically without deploying additional hardware or infrastructure. In addition, it enables programmers to build, deploy and test software directly from the cloud. Thus, the programmers can change to .NET Core to improve the performance and scalability of the applications without placing extra time and energy.
性能和可扩展性:. net核心要比。net框架强大得多,可以提高软件的性能和可扩展性。它使程序员能够在不部署额外硬件或基础设施的情况下从根本上促进软件的操作。此外,它还允许程序员直接从云中构建、部署和测试软件。因此,程序员可以更改为. net Core,以提高应用程序的性能和可扩展性,而无需花费额外的时间和精力。
NET Core doesn't support all the features and functionalities offered by the most recent edition of .NET Framework. However, it may be utilized as a subset of these .NET Framework. Additionally, .NET Core remains compatible with .NET Framework throughout the . Thus, the programmers may still run the software developed with .NET Framework after updating to .NET Core.
NET Core不支持最新版本的。NET Framework提供的所有特性和功能。但是,它可以作为这些。net框架的一个子集使用。此外,. net Core始终与。net框架兼容。因此,在更新到。net Core之后,程序员仍然可以运行使用。net框架开发的软件。
Overall, .NET Core is your upgraded and updated version of .NET Framework. The .Net programmers can update to .NET Core to create an assortment of programs by targeting several platforms and devices. Moreover, they are able to benefit from the newest features and improvements contained in .NET Core to construct, test, and set up the software efficiently and quickly.
总的来说,. net Core是. net框架的升级和更新版本。. net程序员可以更新到。net Core,通过针对多个平台和设备创建各种程序。此外,他们能够从。net Core中包含的最新特性和改进中获益,从而高效、快速地构建、测试和设置软件。