public class DomainClassLoaderBuilder extends AbstractArtifactClassLoaderBuilder<DomainClassLoaderBuilder>
ArtifactClassLoader builder for class loaders required by Domain artifactsartifactDescriptor, artifactPluginClassLoaders, logger| Constructor and Description |
|---|
DomainClassLoaderBuilder(ArtifactClassLoader parentClassLoader,
DeployableArtifactClassLoaderFactory<DomainDescriptor> artifactClassLoaderFactory,
RegionPluginClassLoadersFactory pluginClassLoadersFactory)
Creates a new builder for creating
Domain artifacts. |
| Modifier and Type | Method and Description |
|---|---|
MuleDeployableArtifactClassLoader |
build()
Creates a new
ArtifactClassLoader using the provided configuration. |
protected ArtifactClassLoader |
createArtifactClassLoader(String artifactId,
RegionClassLoader regionClassLoader)
Creates the class loader for the artifact being built.
|
protected String |
getArtifactId(ArtifactDescriptor artifactDescriptor) |
static String |
getDomainId(String domainName) |
protected ArtifactClassLoader |
getParentClassLoader()
Implementation must redefine this method and it should provide the root class loader which is going to be used as parent
class loader for every other class loader created by this builder.
|
addArtifactPluginDescriptors, createRegionClassLoader, getParentLookupPolicy, setArtifactDescriptor, setArtifactIdpublic DomainClassLoaderBuilder(ArtifactClassLoader parentClassLoader, DeployableArtifactClassLoaderFactory<DomainDescriptor> artifactClassLoaderFactory, RegionPluginClassLoadersFactory pluginClassLoadersFactory)
Domain artifacts.parentClassLoader - classloader that will be the parent of the created classloaders. Non nullartifactClassLoaderFactory - factory for the classloader specific to the artifact resource and classespluginClassLoadersFactory - creates the class loaders for the plugins included in the domain's region. Non nullpublic MuleDeployableArtifactClassLoader build() throws IOException
ArtifactClassLoader using the provided configuration. It will create the proper class loader hierarchy
and filters so domain classes, resources and plugins are resolve correctly.build in class AbstractArtifactClassLoaderBuilder<DomainClassLoaderBuilder>MuleDeployableArtifactClassLoader created from the provided configuration.IOException - exception cause when it was not possible to access the file provided as dependenciesprotected ArtifactClassLoader createArtifactClassLoader(String artifactId, RegionClassLoader regionClassLoader)
AbstractArtifactClassLoaderBuildercreateArtifactClassLoader in class AbstractArtifactClassLoaderBuilder<DomainClassLoaderBuilder>artifactId - identifies the artifact being created. Non empty.regionClassLoader - class loader containing the artifact and dependant class loaders. Non null.protected String getArtifactId(ArtifactDescriptor artifactDescriptor)
getArtifactId in class AbstractArtifactClassLoaderBuilder<DomainClassLoaderBuilder>protected ArtifactClassLoader getParentClassLoader()
getParentClassLoader in class AbstractArtifactClassLoaderBuilder<DomainClassLoaderBuilder>Copyright © 2003–2019 MuleSoft, Inc.. All rights reserved.