Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7941305
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T23:37:47+00:00 2026-06-03T23:37:47+00:00

I need to create multiple AppDomains in my .NET in-process COM server (it’s a

  • 0

I need to create multiple AppDomains in my .NET in-process COM server (it’s a Windows Explorer namespace extension).

In my test Console Application, i am able to create 10 domains + WPF windows in 40 seconds, which is unacceptable.
Adding LoaderOptimization.MultiDomainHost speeds this up to 2-5 seconds, which is OK.

However, there is no Main method in a COM server, and specifying LoaderOptimization in AppDomainSetup only affects loading 2 or more additional domains (i.e. first additional AppDomain starts 3-4 seconds, others in 0.1-0.3 sec)

So, Can I specify LoaderOptimization for an in-process COM server, and if yes, how?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T23:37:49+00:00Added an answer on June 3, 2026 at 11:37 pm

    You cannot get this option set as long as you write your code in C#. You’d need to host the CLR yourself so you can configure the appdomain and that requires C++ code. The core MSDN library article set starts here.

    Trying to figure out why it takes so dang long ought to produce some results. It certainly doesn’t sound like a cold start problem, associated with the cost of finding the assemblies on disk for the first time. That perf hit is only relevant on the very first appdomain, later ones should be quick since they’ll find the assemblies in the file system cache.

    Which leaves a warm start problem, associated with just-in-time compiling the IL to machine code. The quick fix for this is running ngen.exe on your assembly.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Why do I need to create Multiple SSPs in MOSS? My manager (sharepoint administrator)
I'm new to GUI programming, but need to create a multiple window GUI. Does
I`v come across a need where I want to create multiple list items from
I need to create an ASN.1 BER encoded file with multiple records. I've been
I need to create multiple tar files in a tar-by-environment package. Every different environment
I need to create multiple divs like below based on how many objects are
I need to create multiple /testcontainer: parameters to feed into a task that exec's
I need to create multiple threads when a button is clicked and i've done
The questions is pretty straightforward and I need to know how to create multiple
For me there is no need/intention to create multiple index names for a same

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.