.net Core 内存过高问题解决方案

  <PropertyGroup>
    <ServerGarbageCollection>false</ServerGarbageCollection>
    <!--- ServerGarbageCollection : 服务器垃圾收集 :不会让内存无限增长 -->
    <ConcurrentGarbageCollection>true</ConcurrentGarbageCollection>
     <!--- ServerGarbageCollection : 并发垃圾收集 :不会让内存无限增长 -->
    <TargetFramework>netcoreapp2.1</TargetFramework>
  </PropertyGroup>

我们简单讲解一下。

ServerGarbageCollection:false
内存不会无限制增长

ConcurrentGarbageCollection:true
高并发垃圾回收,我们写True就行了

大家不知道写哪里的,看下面截图教程
dotNet Core 内存占用过高的解决方案

节点:Project -> PropertyGroup -> 设置GC

  <PropertyGroup>
    <ServerGarbageCollection>false</ServerGarbageCollection>
    <ConcurrentGarbageCollection>true</ConcurrentGarbageCollection>
    <TargetFramework>netcoreapp2.1</TargetFramework>
  </PropertyGroup>

dotNet Core 内存占用过高的解决方案

相关文章:

  • 2021-11-06
  • 2021-09-06
  • 2021-08-05
  • 2022-12-23
  • 2021-09-18
  • 2021-11-18
  • 2021-06-03
  • 2022-12-23
猜你喜欢
  • 2021-07-05
  • 2022-12-23
  • 2021-05-30
  • 2021-11-27
  • 2022-12-23
  • 2021-08-18
  • 2021-11-18
相关资源
相似解决方案