Skip to content

blazor big project: build perf downgrade #64784

@AdmiralSnyder

Description

@AdmiralSnyder

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

our blazor project in our 180 project solution takes ages to compile which is very painful for debugging.
after an inital build after deleting bin and obj folders, which took 145 seconds,
a consecutive build takes 122 seconds.
Without any changes between those builds.

This is especially painful since when i did changes in source, it takes 4+ minutes every time i hit F5 in Visual studio.

We already tried inspecting the binlogs to find the causes, but didn't get to anything specific

Here, i'm linking .binlog files that got created immediatly one after the other
firstbuild
secondbuild

Any help is greatly appreciated

this might be a hint to start the investigation:

Image

(in the second build)

Expected Behavior

when there's no source changes, the second call for dotnet build should take almost no time

Steps To Reproduce

i am very happy to show anybody around the project on discord, please ping me. since this is our closed source commercial product, i cannot share it, though.
and since the extend of the problem only hits with a big project like this (that's our theory, at least), i don't know how to create a minimal solution

Exceptions (if any)

no exceptions, sadly. it is just super slow

.NET Version

10.0.101

Anything else?

We first started noticing slowdown when fingerprinting assets was introduced in blazor, last year.
also, this might not be relevant, but it became way worse when i turned a number of of intermediate projects from being netstandard2.0 to multitargeting net10.0 and net48, a couple months ago

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs: Author FeedbackThe author of this issue needs to respond in order for us to continue investigating this issue.area-blazorIncludes: Blazor, Razor Components

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions