Assembly Probing

Shared assemblies don’t have to be installed in the GAC; as an alternative, assembly probing specifies a set of application subdirectories to search when attempting to locate an assembly. The probing information is included in the application configuration file.

More Info

For more general information about configuration files, consult Appendix C.

The following configuration file demonstrates the use of probing:

<configuration>
    <runtime>
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
            <probing privatePath="dir1;dir2subdirectory;dir3"/>
        </assemblyBinding>
    </runtime>
</configuration>

This example specifies that assemblies should be searched for in the dir1, dir2subdirectory, and dir3 directories, relative to the location of the application; the shared assemblies that an application uses must be included in the distribution that is installed on the system. Including shared assemblies with an application distribution means that a single copy cannot be shared among multiple applications unless applications share the same installation directory. The techniques that are described in the Assembly Version Policies section earlier in this appendix cannot be applied to applications that rely on assembly probing but can be used to locate private, as well as shared, assemblies.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset