"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "log4j-cassandra/src/main/java/org/apache/logging/log4j/cassandra/CassandraAppender.java" between
apache-log4j-2.11.1-src.tar.gz and apache-log4j-2.11.2-src.tar.gz

About: Apache Log4j 2 is a logging library for Java. Source distribution (Java).

CassandraAppender.java  (apache-log4j-2.11.1-src):CassandraAppender.java  (apache-log4j-2.11.2-src)
skipping to change at line 25 skipping to change at line 25
* limitations under the license. * limitations under the license.
*/ */
package org.apache.logging.log4j.cassandra; package org.apache.logging.log4j.cassandra;
import com.datastax.driver.core.BatchStatement; import com.datastax.driver.core.BatchStatement;
import org.apache.logging.log4j.core.Core; import org.apache.logging.log4j.core.Core;
import org.apache.logging.log4j.core.Filter; import org.apache.logging.log4j.core.Filter;
import org.apache.logging.log4j.core.appender.AbstractAppender; import org.apache.logging.log4j.core.appender.AbstractAppender;
import org.apache.logging.log4j.core.appender.db.AbstractDatabaseAppender; import org.apache.logging.log4j.core.appender.db.AbstractDatabaseAppender;
import org.apache.logging.log4j.core.appender.db.ColumnMapping; import org.apache.logging.log4j.core.appender.db.ColumnMapping;
import org.apache.logging.log4j.core.config.Property;
import org.apache.logging.log4j.core.config.plugins.Plugin; import org.apache.logging.log4j.core.config.plugins.Plugin;
import org.apache.logging.log4j.core.config.plugins.PluginBuilderAttribute; import org.apache.logging.log4j.core.config.plugins.PluginBuilderAttribute;
import org.apache.logging.log4j.core.config.plugins.PluginBuilderFactory; import org.apache.logging.log4j.core.config.plugins.PluginBuilderFactory;
import org.apache.logging.log4j.core.config.plugins.PluginElement; import org.apache.logging.log4j.core.config.plugins.PluginElement;
import org.apache.logging.log4j.core.config.plugins.validation.constraints.Requi red; import org.apache.logging.log4j.core.config.plugins.validation.constraints.Requi red;
import org.apache.logging.log4j.core.net.SocketAddress; import org.apache.logging.log4j.core.net.SocketAddress;
import org.apache.logging.log4j.core.util.Clock; import org.apache.logging.log4j.core.util.Clock;
/** /**
* Appender plugin that uses a Cassandra database. * Appender plugin that uses a Cassandra database.
* *
* @see SocketAddress * @see SocketAddress
* @see ColumnMapping * @see ColumnMapping
*/ */
@Plugin(name = "Cassandra", category = Core.CATEGORY_NAME, elementType = Cassand raAppender.ELEMENT_TYPE, printObject = true) @Plugin(name = "Cassandra", category = Core.CATEGORY_NAME, elementType = Cassand raAppender.ELEMENT_TYPE, printObject = true)
public class CassandraAppender extends AbstractDatabaseAppender<CassandraManager > { public class CassandraAppender extends AbstractDatabaseAppender<CassandraManager > {
private CassandraAppender(final String name, final Filter filter, final bool ean ignoreExceptions, private CassandraAppender(final String name, final Filter filter, final bool ean ignoreExceptions,
final CassandraManager manager) { final Property[] properties, final CassandraManage
super(name, filter, ignoreExceptions, manager); r manager) {
super(name, filter, null, ignoreExceptions, properties, manager);
} }
@PluginBuilderFactory @PluginBuilderFactory
public static <B extends Builder<B>> B newBuilder() { public static <B extends Builder<B>> B newBuilder() {
return new Builder<B>().asBuilder(); return new Builder<B>().asBuilder();
} }
public static class Builder<B extends Builder<B>> extends AbstractAppender.B uilder<B> public static class Builder<B extends Builder<B>> extends AbstractAppender.B uilder<B>
implements org.apache.logging.log4j.core.util.Builder<CassandraAppender> { implements org.apache.logging.log4j.core.util.Builder<CassandraAppender> {
skipping to change at line 180 skipping to change at line 181
public B setBatchType(final BatchStatement.Type batchType) { public B setBatchType(final BatchStatement.Type batchType) {
this.batchType = batchType; this.batchType = batchType;
return asBuilder(); return asBuilder();
} }
@Override @Override
public CassandraAppender build() { public CassandraAppender build() {
final CassandraManager manager = CassandraManager.getManager(getName (), contactPoints, columns, useTls, final CassandraManager manager = CassandraManager.getManager(getName (), contactPoints, columns, useTls,
clusterName, keyspace, table, username, password, useClockForTim estampGenerator, bufferSize, batched, clusterName, keyspace, table, username, password, useClockForTim estampGenerator, bufferSize, batched,
batchType); batchType);
return new CassandraAppender(getName(), getFilter(), isIgnoreExcepti ons(), manager); return new CassandraAppender(getName(), getFilter(), isIgnoreExcepti ons(), null, manager);
} }
} }
} }
 End of changes. 3 change blocks. 
3 lines changed or deleted 5 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)