katstack commented on code in PR #4234: URL: https://github.com/apache/logging-log4j2/pull/4234#discussion_r4359798903
########## log4j-core/src/main/java/org/apache/logging/log4j/core/appender/rolling/action/AbstractCompressAction.java: ########## @@ -0,0 +1,105 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to you under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.logging.log4j.core.appender.rolling.action; + +import java.io.File; +import java.io.IOException; +import java.io.OutputStream; +import java.util.Objects; +import org.apache.logging.log4j.core.appender.rolling.action.internal.CompressActionSupport; + +/** + * Base class for actions that compress a file and optionally delete the source after successful compression. + * + * @since 2.27.0 + */ +public abstract class AbstractCompressAction extends AbstractAction { Review Comment: I tried moving `AbstractCompressAction` back to the internal package, but Bnd fails with: ```text Export org.apache.logging.log4j.core.appender.rolling.action, has 1, private references [org.apache.logging.log4j.core.appender.rolling.action.internal] ``` This comes from the public `GzCompressAction` and `ZipCompressAction` extending the internal base class. That is why I placed it in the exported package. Would a narrowly scoped Bnd exception be acceptable so we can keep the base class internal? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
