Skip to content

Commit

Permalink
Remove unused tmp directory creation
Browse files Browse the repository at this point in the history
  • Loading branch information
Jean Francois Denise committed Apr 3, 2024
1 parent 6a36655 commit 466ef8a
Showing 1 changed file with 1 addition and 11 deletions.
12 changes: 1 addition & 11 deletions api/src/main/java/org/jboss/galleon/api/ProvisioningImpl.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2016-2023 Red Hat, Inc. and/or its affiliates
* Copyright 2016-2024 Red Hat, Inc. and/or its affiliates
* and other contributors as indicated by the @author tags.
*
* Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -16,7 +16,6 @@
*/
package org.jboss.galleon.api;

import java.io.IOException;
import java.io.InputStream;
import java.net.URLClassLoader;
import java.nio.file.Files;
Expand All @@ -42,7 +41,6 @@
import org.jboss.galleon.progresstracking.ProgressCallback;
import org.jboss.galleon.progresstracking.ProgressTracker;
import org.jboss.galleon.universe.UniverseResolver;
import org.jboss.galleon.util.IoUtils;
import org.jboss.galleon.core.builder.ProvisioningContextBuilder;
import org.jboss.galleon.diff.FsDiff;
import org.jboss.galleon.impl.ProvisioningUtil;
Expand All @@ -61,7 +59,6 @@ class ProvisioningImpl implements Provisioning {
private boolean recordState;
private final Map<String, ProgressTracker<?>> progressTrackers = new HashMap<>();

private final Path tmp;
private final Map<FPID, LocalFP> locals;

private final String coreVersion;
Expand All @@ -78,12 +75,6 @@ class ProvisioningImpl implements Provisioning {
this.locals = builder.getLocals();
this.recordState = builder.isRecordState();
loader = GalleonBuilder.getCallerClassLoader(coreVersion, universeResolver);
try {
tmp = Files.createTempDirectory("galleon-tmp");
} catch (IOException ex) {
throw new ProvisioningException(ex);
}

}

/**
Expand Down Expand Up @@ -169,7 +160,6 @@ private ProvisioningContext buildProvisioningContext() throws ProvisioningExcept

@Override
public void close() {
IoUtils.recursiveDelete(tmp);
try {
for (ProvisioningContext ctx : contexts) {
ctx.close();
Expand Down

0 comments on commit 466ef8a

Please sign in to comment.