Search in sources :

Example 1 with DefaultModuleArtifactsCache

use of org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactsCache in project gradle by gradle.

the class DependencyManagementBuildScopeServices method createModuleRepositoryCacheProvider.

ModuleRepositoryCacheProvider createModuleRepositoryCacheProvider(BuildCommencedTimeProvider timeProvider, CacheLockingManager cacheLockingManager, ImmutableModuleIdentifierFactory moduleIdentifierFactory, ArtifactCacheMetadata artifactCacheMetadata, AttributeContainerSerializer attributeContainerSerializer, MavenMutableModuleMetadataFactory mavenMetadataFactory, IvyMutableModuleMetadataFactory ivyMetadataFactory) {
    ModuleRepositoryCaches caches = new ModuleRepositoryCaches(new DefaultModuleVersionsCache(timeProvider, cacheLockingManager, moduleIdentifierFactory), new DefaultModuleMetadataCache(timeProvider, cacheLockingManager, artifactCacheMetadata, moduleIdentifierFactory, attributeContainerSerializer, mavenMetadataFactory, ivyMetadataFactory), new DefaultModuleArtifactsCache(timeProvider, cacheLockingManager), new DefaultModuleArtifactCache("module-artifact", timeProvider, cacheLockingManager));
    ModuleRepositoryCaches inMemoryCaches = new ModuleRepositoryCaches(new InMemoryModuleVersionsCache(timeProvider), new InMemoryModuleMetadataCache(timeProvider), new InMemoryModuleArtifactsCache(timeProvider), new InMemoryModuleArtifactCache(timeProvider));
    return new ModuleRepositoryCacheProvider(caches, inMemoryCaches);
}
Also used : InMemoryModuleArtifactsCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.InMemoryModuleArtifactsCache) ModuleRepositoryCaches(org.gradle.api.internal.artifacts.ivyservice.modulecache.ModuleRepositoryCaches) DefaultModuleArtifactCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactCache) InMemoryModuleVersionsCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.dynamicversions.InMemoryModuleVersionsCache) InMemoryModuleMetadataCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.InMemoryModuleMetadataCache) DefaultModuleVersionsCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.dynamicversions.DefaultModuleVersionsCache) DefaultModuleMetadataCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.DefaultModuleMetadataCache) DefaultModuleArtifactsCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactsCache) InMemoryModuleArtifactCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.InMemoryModuleArtifactCache) ModuleRepositoryCacheProvider(org.gradle.api.internal.artifacts.ivyservice.modulecache.ModuleRepositoryCacheProvider)

Example 2 with DefaultModuleArtifactsCache

use of org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactsCache in project gradle by gradle.

the class DependencyManagementBuildScopeServices method prepareModuleRepositoryCaches.

private ModuleRepositoryCaches prepareModuleRepositoryCaches(ArtifactCacheMetadata artifactCacheMetadata, ArtifactCacheLockingManager artifactCacheLockingManager, BuildCommencedTimeProvider timeProvider, ImmutableModuleIdentifierFactory moduleIdentifierFactory, AttributeContainerSerializer attributeContainerSerializer, MavenMutableModuleMetadataFactory mavenMetadataFactory, IvyMutableModuleMetadataFactory ivyMetadataFactory, SimpleMapInterner stringInterner, ArtifactIdentifierFileStore artifactIdentifierFileStore, ModuleSourcesSerializer moduleSourcesSerializer, ChecksumService checksumService) {
    DefaultModuleVersionsCache moduleVersionsCache = new DefaultModuleVersionsCache(timeProvider, artifactCacheLockingManager, moduleIdentifierFactory);
    PersistentModuleMetadataCache moduleMetadataCache = new PersistentModuleMetadataCache(timeProvider, artifactCacheLockingManager, artifactCacheMetadata, moduleIdentifierFactory, attributeContainerSerializer, mavenMetadataFactory, ivyMetadataFactory, stringInterner, moduleSourcesSerializer, checksumService);
    DefaultModuleArtifactsCache moduleArtifactsCache = new DefaultModuleArtifactsCache(timeProvider, artifactCacheLockingManager);
    DefaultModuleArtifactCache moduleArtifactCache = new DefaultModuleArtifactCache("module-artifact", timeProvider, artifactCacheLockingManager, artifactIdentifierFileStore.getFileAccessTracker(), artifactCacheMetadata.getCacheDir().toPath());
    return new ModuleRepositoryCaches(moduleVersionsCache, moduleMetadataCache, moduleArtifactsCache, moduleArtifactCache);
}
Also used : ModuleRepositoryCaches(org.gradle.api.internal.artifacts.ivyservice.modulecache.ModuleRepositoryCaches) PersistentModuleMetadataCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.PersistentModuleMetadataCache) DefaultModuleArtifactCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactCache) DefaultModuleVersionsCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.dynamicversions.DefaultModuleVersionsCache) DefaultModuleArtifactsCache(org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactsCache)

Aggregations

ModuleRepositoryCaches (org.gradle.api.internal.artifacts.ivyservice.modulecache.ModuleRepositoryCaches)2 DefaultModuleArtifactCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactCache)2 DefaultModuleArtifactsCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.DefaultModuleArtifactsCache)2 DefaultModuleVersionsCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.dynamicversions.DefaultModuleVersionsCache)2 DefaultModuleMetadataCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.DefaultModuleMetadataCache)1 InMemoryModuleMetadataCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.InMemoryModuleMetadataCache)1 ModuleRepositoryCacheProvider (org.gradle.api.internal.artifacts.ivyservice.modulecache.ModuleRepositoryCacheProvider)1 PersistentModuleMetadataCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.PersistentModuleMetadataCache)1 InMemoryModuleArtifactCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.InMemoryModuleArtifactCache)1 InMemoryModuleArtifactsCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.artifacts.InMemoryModuleArtifactsCache)1 InMemoryModuleVersionsCache (org.gradle.api.internal.artifacts.ivyservice.modulecache.dynamicversions.InMemoryModuleVersionsCache)1