Skip to content

Commit

Permalink
Delete unused logger.
Browse files Browse the repository at this point in the history
  • Loading branch information
dkocher committed Nov 26, 2024
1 parent 3e80474 commit 2ddd684
Show file tree
Hide file tree
Showing 37 changed files with 6 additions and 141 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,12 @@
import org.apache.commons.lang3.StringUtils;
import org.apache.http.HttpStatus;
import org.apache.http.client.HttpResponseException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.time.Duration;

import synapticloop.b2.exception.B2ApiException;

public class B2ExceptionMappingService extends AbstractExceptionMappingService<B2ApiException> {
private static final Logger log = LogManager.getLogger(B2ExceptionMappingService.class);

private final B2VersionIdProvider fileid;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,12 @@

import ch.cyberduck.core.Path;
import ch.cyberduck.core.exception.BackgroundException;
import ch.cyberduck.core.features.Upload;
import ch.cyberduck.core.features.Write;
import ch.cyberduck.core.http.HttpUploadFeature;
import ch.cyberduck.core.io.Checksum;
import ch.cyberduck.core.preferences.HostPreferences;

import org.apache.commons.lang3.StringUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.io.IOException;
import java.io.InputStream;
Expand All @@ -37,15 +34,12 @@
import synapticloop.b2.response.BaseB2Response;

public class B2SingleUploadService extends HttpUploadFeature<BaseB2Response, MessageDigest> {
private static final Logger log = LogManager.getLogger(B2SingleUploadService.class);

private final B2Session session;
private Write<BaseB2Response> writer;

public B2SingleUploadService(final B2Session session, final Write<BaseB2Response> writer) {
super(writer);
this.session = session;
this.writer = writer;
}

@Override
Expand Down Expand Up @@ -76,10 +70,4 @@ protected MessageDigest digest() throws IOException {
protected void post(final Path file, final MessageDigest digest, final BaseB2Response response) throws BackgroundException {
this.verify(file, digest, Checksum.parse(StringUtils.removeStart(((B2FileResponse) response).getContentSha1(), "unverified:")));
}

@Override
public Upload<BaseB2Response> withWriter(final Write<BaseB2Response> writer) {
this.writer = writer;
return super.withWriter(writer);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,9 @@
import ch.cyberduck.core.preferences.HostPreferences;
import ch.cyberduck.core.transfer.TransferStatus;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.util.EnumSet;

public class B2ThresholdCopyFeature implements Copy {
private static final Logger log = LogManager.getLogger(B2ThresholdCopyFeature.class);

private final B2Session session;
private final B2VersionIdProvider fileid;
Expand Down
3 changes: 0 additions & 3 deletions box/src/main/java/ch/cyberduck/core/box/BoxSession.java
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,11 @@

import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClientBuilder;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.io.IOException;
import java.util.Collections;

public class BoxSession extends HttpSession<CloseableHttpClient> {
private static final Logger log = LogManager.getLogger(BoxSession.class);

private final BoxFileidProvider fileid = new BoxFileidProvider(this);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@
import ch.cyberduck.core.exception.LocalNotfoundException;
import ch.cyberduck.core.exception.NotfoundException;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.rococoa.ObjCObjectByReference;
import org.rococoa.Rococoa;
import org.rococoa.cocoa.foundation.NSError;
Expand All @@ -43,7 +41,6 @@
* @see ch.cyberduck.binding.foundation.NSFileManager
*/
public class FinderLocalAttributes extends LocalAttributes {
private static final Logger log = LogManager.getLogger(FinderLocalAttributes.class);

private final FinderLocal local;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,7 @@
import ch.cyberduck.core.library.Native;
import ch.cyberduck.core.local.Application;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

public class SMAppServiceApplicationLoginRegistry implements ApplicationLoginRegistry {
private static final Logger log = LogManager.getLogger(SMAppServiceApplicationLoginRegistry.class);

static {
Native.load("core");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,7 @@

import ch.cyberduck.binding.foundation.NSAppleScript;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

public final class SystemPreferencesProxyConfiguration implements ProxyFinder.Configuration {
private static final Logger log = LogManager.getLogger(SystemPreferencesProxyConfiguration.class);

@Override
public void configure() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,9 @@
*/

import ch.cyberduck.binding.application.NSWorkspace;
import ch.cyberduck.binding.foundation.NSAppleScript;
import ch.cyberduck.binding.foundation.NSURL;
import ch.cyberduck.core.Factory;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

public final class SystemSettingsProxyConfiguration implements ProxyFinder.Configuration {
private static final Logger log = LogManager.getLogger(SystemSettingsProxyConfiguration.class);

@Override
public void configure() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,7 @@
import ch.cyberduck.core.features.Vault;
import ch.cyberduck.core.vault.DecryptingListProgressListener;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

public class CryptoListService implements ListService {
private static final Logger log = LogManager.getLogger(CryptoListService.class);

private final Session<?> session;
private final ListService delegate;
Expand Down
3 changes: 0 additions & 3 deletions ctera/src/main/java/ch/cyberduck/core/ctera/CteraSession.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,16 +46,13 @@
import org.apache.http.client.methods.HttpGet;
import org.apache.http.impl.client.AbstractResponseHandler;
import org.apache.http.impl.client.HttpClientBuilder;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.io.IOException;
import java.text.MessageFormat;

import com.fasterxml.jackson.databind.ObjectMapper;

public class CteraSession extends DAVSession {
private static final Logger log = LogManager.getLogger(CteraSession.class);

private static final String PUBLIC_INFO_PATH = "/ServicesPortal/public/publicInfo?format=jsonext";
private static final String CURRENT_SESSION_PATH = "/ServicesPortal/api/currentSession?format=jsonext";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,8 @@
import ch.cyberduck.core.exception.BackgroundException;

import org.apache.commons.lang3.StringUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

public final class CteraTokens {
private static final Logger log = LogManager.getLogger(CteraTokens.class);

public static CteraTokens EMPTY = new CteraTokens(StringUtils.EMPTY, StringUtils.EMPTY);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
*/

import ch.cyberduck.core.AbstractPath;
import ch.cyberduck.core.AttributedList;
import ch.cyberduck.core.CachingFileIdProvider;
import ch.cyberduck.core.Path;
import ch.cyberduck.core.PathAttributes;
Expand Down Expand Up @@ -312,7 +311,6 @@ public NodeIdProvider(final DeepboxListService.Contents supplier) {
@Override
public String getFileId(final Path file) throws BackgroundException {
try {
final AttributedList<Path> list = new AttributedList<>();
int offset = 0;
int size;
do {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,6 @@
import org.apache.http.entity.mime.HttpMultipartMode;
import org.apache.http.entity.mime.MultipartEntityBuilder;
import org.apache.http.impl.client.AbstractResponseHandler;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.io.ByteArrayOutputStream;
import java.io.IOException;
Expand All @@ -49,7 +47,6 @@
import com.fasterxml.jackson.databind.ObjectReader;

public class DeepboxWriteFeature extends AbstractHttpWriteFeature<Node> {
private static final Logger log = LogManager.getLogger(DeepboxWriteFeature.class);

private final DeepboxSession session;
private final DeepboxIdProvider fileid;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.BufferedHttpEntity;
import org.apache.http.util.EntityUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.io.IOException;
import java.io.OutputStream;
Expand All @@ -46,7 +44,6 @@
import java.util.concurrent.atomic.AtomicReference;

public class MultipartUploadTokenOutputStream extends OutputStream {
private static final Logger log = LogManager.getLogger(MultipartUploadTokenOutputStream.class);

private final SDSSession session;
private final SDSNodeIdProvider nodeid;
Expand Down Expand Up @@ -111,8 +108,8 @@ public Void call() throws BackgroundException {
default:
EntityUtils.updateEntity(response, new BufferedHttpEntity(response.getEntity()));
throw new SDSExceptionMappingService(nodeid).map(
new ApiException(response.getStatusLine().getStatusCode(), response.getStatusLine().getReasonPhrase(), Collections.emptyMap(),
EntityUtils.toString(response.getEntity())));
new ApiException(response.getStatusLine().getStatusCode(), response.getStatusLine().getReasonPhrase(), Collections.emptyMap(),
EntityUtils.toString(response.getEntity())));
}
}
catch(BackgroundException e) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,10 @@
import ch.cyberduck.core.sds.io.swagger.client.model.NodeList;

import org.apache.commons.lang3.StringUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.util.EnumSet;

public class SDSListService implements ListService {
private static final Logger log = LogManager.getLogger(SDSListService.class);

private final SDSSession session;
private final SDSNodeIdProvider nodeid;
Expand All @@ -58,8 +55,8 @@ protected AttributedList<Path> list(final Path directory, final ListProgressList
NodeList nodes;
do {
nodes = new NodesApi(session.getClient()).requestNodes(null, 0,
Long.parseLong(nodeid.getVersionId(directory)),
false, null, "name:asc", offset, chunksize, StringUtils.EMPTY);
Long.parseLong(nodeid.getVersionId(directory)),
false, null, "name:asc", offset, chunksize, StringUtils.EMPTY);
for(Node node : nodes.getItems()) {
final PathAttributes attributes = feature.toAttributes(node);
final EnumSet<Path.Type> type = feature.toType(node);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ public Path copy(final Path file, final Path target, final TransferStatus status
}
final String resourceId = fileid.getFileId(file);
final String parentResourceId = fileid.getFileId(target.getParent());
String targetResourceId = null;
final ResourceCopyResponseEntries resourceCopyResponseEntries;
switch(parentResourceId) {
case EueResourceIdProvider.ROOT:
Expand Down
4 changes: 0 additions & 4 deletions eue/src/main/java/ch/cyberduck/core/eue/EueDeleteFeature.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,12 @@
import ch.cyberduck.core.transfer.TransferStatus;

import org.apache.commons.lang3.StringUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.text.MessageFormat;
import java.util.List;
import java.util.Map;

public class EueDeleteFeature extends EueTrashFeature implements Delete {
private static final Logger log = LogManager.getLogger(EueDeleteFeature.class);

private final EueSession session;
private final EueResourceIdProvider fileid;
Expand All @@ -48,7 +45,6 @@ public EueDeleteFeature(final EueSession session, final EueResourceIdProvider fi
@Override
public void delete(final Map<Path, TransferStatus> files, final PasswordCallback prompt, final Callback callback) throws BackgroundException {
try {
final EueApiClient client = new EueApiClient(session);
// Move to trash first as precondition of delete
this.delete(super.trash(files, prompt, callback));
for(Path f : files.keySet()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@
import org.apache.http.HttpResponse;
import org.apache.http.HttpStatus;
import org.apache.http.client.HttpResponseException;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import javax.ws.rs.ProcessingException;
import java.io.IOException;
Expand All @@ -49,7 +47,6 @@
import java.util.stream.Collectors;

public class EueExceptionMappingService extends AbstractExceptionMappingService<ApiException> {
private static final Logger log = LogManager.getLogger(EueExceptionMappingService.class);

@Override
public BackgroundException map(final ApiException failure) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,10 @@
import ch.cyberduck.core.eue.io.swagger.client.model.ShareCreationResponseEntity;
import ch.cyberduck.core.eue.io.swagger.client.model.UserSharesModel;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.util.Collections;
import java.util.EnumSet;

public class EueShareUrlProvider implements UrlProvider {
private static final Logger log = LogManager.getLogger(EueShareUrlProvider.class);

private final Host host;
private final UserSharesModel shares;
Expand Down
3 changes: 0 additions & 3 deletions eue/src/main/java/ch/cyberduck/core/eue/EueWriteFeature.java
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,11 @@
import org.apache.http.client.methods.HttpPut;
import org.apache.http.entity.BufferedHttpEntity;
import org.apache.http.util.EntityUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.io.IOException;
import java.util.EnumSet;

public class EueWriteFeature extends AbstractHttpWriteFeature<EueWriteFeature.Chunk> {
private static final Logger log = LogManager.getLogger(EueWriteFeature.class);

public static final String RESOURCE_ID = "resourceId";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@
import org.apache.http.entity.AbstractHttpEntity;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.protocol.BasicHttpContext;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.glassfish.jersey.client.ClientRequest;
import org.glassfish.jersey.client.ClientResponse;
import org.glassfish.jersey.client.spi.AsyncConnectorCallback;
Expand All @@ -55,7 +53,6 @@
import com.google.common.util.concurrent.MoreExecutors;

public class HttpComponentsConnector implements Connector {
private static final Logger log = LogManager.getLogger(HttpComponentsConnector.class);

private final CloseableHttpClient client;
private final HttpClientContext context;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,11 @@
import ch.cyberduck.core.io.Checksum;
import ch.cyberduck.core.io.HashAlgorithm;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.util.EnumSet;

import com.joyent.manta.client.MantaObject;

public final class MantaObjectAttributeAdapter implements AttributesAdapter<MantaObject> {
private static final Logger log = LogManager.getLogger(MantaObjectAttributeAdapter.class);

private final MantaSession session;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,12 @@
import ch.cyberduck.core.shared.DelegatingHomeFeature;

import org.apache.commons.lang3.StringUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

import java.text.MessageFormat;
import java.util.Arrays;
import java.util.EnumSet;

public class NextcloudHomeFeature extends AbstractHomeFeature {
private static final Logger log = LogManager.getLogger(NextcloudHomeFeature.class);

private final Host bookmark;

Expand Down
Loading

0 comments on commit 2ddd684

Please sign in to comment.