A
A
alexxxey_code2020-12-19 10:32:26
.NET
alexxxey_code, 2020-12-19 10:32:26

I'm reading a richter, I can't understand "cross-domain interaction with link promotion" how to understand this process?

in the main domain, we created another domain and loaded our assembly there. And in the assembly (which we transferred to another domain) there is a specified type in which there is an object. I want
to transfer this object back to the main domain. "CLR determines the representative type in the loader heap of this domain" - is it in the new domain? And how to understand the source domain and the target one?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
sus_scrofa, 2021-01-08
@alexxxey_code

Richter is not at hand, but I will try to answer.
Here we are talking about the fact that data from one domain is not directly available in another . There are two mechanisms to do this:
1) Serialization (i.e. we pass a copy of the object)
2) Through the link (object reference) - which cannot be done directly (this is a limitation purely for security reasons - domain data must be separated) and to get around this restriction, in the recipient domain (target, destination, target) an intermediary object (representative, object proxy) is created that "knows" how to "reach out" to an object created in another domain (source) through the mechanisms provided by the CLR.
As I understand it, the phrase "CLR determines the representative type in the loader heap of this domain" describes the process of automatically generating a type for an intermediary object, since this type is initially absent in the recipient domain (old domain).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question