Diff stringlengths 5 2k | FaultInducingLabel int64 0 1 |
|---|---|
zkArr[1].reconfig(null, leavingServers, null, -1, null); | 0 |
package org.apache.http.impl.execchain; | 0 |
if (getLogger().isDebugEnabled()) {
getLogger().debug("done saving " + this); | 0 |
public void testLongName() throws Exception {
public void testShortName() throws Exception {
public void testAppNameDefault() throws Exception { | 0 |
import org.apache.beam.sdk.values.PCollection.IsBounded;
import org.junit.Rule;
import org.junit.rules.ExpectedException;
import java.util.concurrent.ThreadLocalRandom;
@Rule public ExpectedException thrown = ExpectedException.none();
c.output(KV.of(ThreadLocalRandom.current().nextInt(), c.element()));
@Te... | 0 |
private final SchedulingStrategy schedulingStrategy;
private final FailureCache failureCache;
* using an {@link ImmediateSchedulingStrategy}. Its thread
* pool will be configured according to the given {@link CacheConfig}.
this(new ImmediateSchedulingStrategy(config));
* using the supplie... | 0 |
* @version $Id: URLCodec.java,v 1.18 2004/03/21 01:58:40 ggregory Exp $
* The default charset used for string decoding and encoding.
protected String charset = "UTF-8";
protected static byte ESCAPE_CHAR = '%';
* Constructor which allows for the selection of a default charset
* @param charset the... | 0 |
* 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... | 0 |
ServiceComponentHostEvent succeededEvent;
if (startEventType == ServiceComponentHostEventType.HOST_SVCCOMP_START) {
succeededEvent = new ServiceComponentHostStartedEvent(impl.getServiceComponentName(),
impl.getHostName(), ++timestamp);
} else if (startEventType == ServiceComponentHostEventTy... | 0 |
private volatile TServer replServer;
private void startReplicationService() throws UnknownHostException {
// if the replication name is ever set, then start replication services
SimpleTimer.getInstance(aconf).schedule(() -> {
if (this.replServer == null) {
if (!getConfiguration().get(Property.... | 0 |
package aQute.bnd.service;
import java.io.File;
import aQute.lib.osgi.Jar;
public interface RepositoryListenerPlugin {
/**
* Called when a bundle is added to a repository.
* @param repository
* @param jar
* @param file
*/
void bundleAdded(RepositoryPlugin repository, Jar jar, File file);
} | 0 |
import org.apache.beam.sdk.annotations.Experimental;
import org.apache.beam.sdk.util.ExecutableTrigger;
import org.apache.beam.sdk.util.TimeDomain;
import org.apache.beam.sdk.util.state.MergingStateAccessor;
import org.apache.beam.sdk.util.state.StateAccessor;
import org.joda.time.Instant; | 0 |
import org.apache.ambari.server.audit.event.AuditEvent;
import org.apache.ambari.server.audit.AuditLogger;
import com.google.inject.Inject;
import com.google.inject.Injector;
@Inject
private AuditLogger auditLogger;
protected void auditLog(AuditEvent ae) {
auditLogger.log(ae);
}
| 1 |
/* $Id$ | 0 |
import org.apache.hc.core5.http.WritableByteChannelMock;
public boolean isRepeatable() {
return false;
}
@Override | 0 |
Pipeline getPipeline();
Collection<? extends PValue> expand();
void recordAsOutput(AppliedPTransform<?, ?, ?> transform);
void finishSpecifyingOutput(); | 0 |
* Cluster configuration finished.
*/
CLUSTER_CONFIG_FINISHED,
/** | 0 |
// An exception is expected if we've closed the reader in another thread. Ignore and exit.
this, p.topicPartition, e); | 0 |
* A utility to add files to the !METADATA table that are not listed in the root tablet.
* This is a recovery tool for someone who knows what they are doing. It might be better to
*
| 0 |
final BasicHttpRequest httppost =
new BasicHttpRequest("POST", url.getPath(), ver);
final BasicHttpRequest httpput =
new BasicHttpRequest("PUT", url.getPath(), ver); | 0 |
import org.apache.sshd.common.file.nativefs.NativeFileSystemFactory; | 0 |
import org.apache.beam.sdk.extensions.gcp.options.GcsOptions; | 0 |
* This class is an accumulo constraint that ensures values are numeric strings. See
* docs/examples/README.constraint for instructions.
private static final List<Short> VIOLATION_LIST = Collections
.unmodifiableList(Arrays.asList(NON_NUMERIC_VALUE)); | 0 |
* @version $Revision$ $Date$ | 0 |
* For example: "user" is correct whereas "DOMAIN\user" is not.
* For example: "user" is correct whereas "DOMAIN\user" is not. | 0 |
import org.apache.beam.model.fnexecution.v1.BeamFnApi;
* a single {@link BeamFnApi.Elements} message when the buffer threshold | 0 |
* <p>To execute this pipeline in streaming mode, specify:
* --streaming
* <p>To change the runner, specify:
* --runner=YOUR_SELECTED_RUNNER
* }
* </pre>
* See examples/java/README.md for instructions about how to configure different runners.
* <p>Inherits standard Beam example configuration options.
/... | 0 |
final static String permissionErrors = "permissionErrors";
final static String unknownTabletErrors = "unknownTabletErrors";
final static String mutationArraySize = "mutationArraysSize";
final static String commitPrep = "commitPrep";
final static String constraintViolations = "constraintViolations";
final st... | 0 |
import org.apache.xml.security.exceptions.XMLSecurityException; | 0 |
for (final PropertyDescriptor propertyDescriptor : propertyDescriptors) { | 0 |
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed 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 ap... | 1 |
final
final Iterator<Map.Entry<K, V>> iterator = map.iterator();
final Map.Entry<K, V> entry = iterator.next();
final MultiValueMap map1 = MultiValueMap.multiValueMap(new HashMap(), ArrayList.class);
final MultiValueMap map2 = MultiValueMap.multiValueMap(new HashMap(), (Class... | 0 |
/*
* 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 ... | 0 |
/** State machine implementations for triggers, called "triggers" because they react to events. */ | 1 |
import org.apache.batik.util.HaltingThread;
if (HaltingThread.hasBeenHalted())
return;
// Check If we should halt early.
if (HaltingThread.hasBeenHalted()) {
// The Thread has been halted. | 0 |
* {@code HttpAsyncRequestProducer} is a callback interface whose methods | 0 |
/*import javassist.CannotCompileException;
*/
import net.sf.cglib.core.NamingPolicy;
import net.sf.cglib.core.Predicate;
import net.sf.cglib.core.Signature;
import net.sf.cglib.proxy.InterfaceMaker;
import org.objectweb.asm.Type;
String ifaceName=mbeanServer.getObjectInstance(objectName).getClassName();
InterfaceM... | 0 |
// Nothing to update or remove
if (configType == null ||
(updates == null || updates.isEmpty()) &&
(removals == null || removals.isEmpty())) {
return;
}
Config oldConfig = cluster.getDesiredConfigByType(configType);
Map<String, String> oldConfigProperties;
Map<String, String> ... | 0 |
import org.apache.accumulo.core.client.impl.Credentials; | 1 |
applyMessage(strBuff.toString(), jsonObj, currMultilineJsonStr);
// For now let's put the raw message in log_message, so it is will be searchable | 0 |
import java.util.LinkedHashMap;
Map<String, String> map = new LinkedHashMap<String, String>(); | 0 |
ComponentInstance under = Utils.getComponentInstanceByName(context, "TEMPORAL-MultipleCheckServiceProvider", un); | 0 |
import java.util.Collections;
import java.util.Map;
/**
* Result of executing a {@link com.google.cloud.dataflow.sdk.Pipeline} with Flink. This
* has methods to query to job runtime and the final values of
* {@link com.google.cloud.dataflow.sdk.transforms.Aggregator}s.
*/
public class FlinkRunnerResult implements P... | 0 |
* by calling {@link #consumeContent(org.apache.http.nio.ContentDecoder,
* org.apache.http.nio.IOControl)}. | 0 |
import static org.junit.Assert.assertEquals;
import org.junit.Before;
import org.junit.Test;
public class TestViewNode
@Before
public void setUp() throws Exception
@Test
@Test(expected = IllegalArgumentException.class)
viewNode.addChild(null);
@Test
@Test(expected = IllegalArgumentExcep... | 0 |
/** The list of capabilities this provider supports */
protected static final Collection capabilities = Collections.unmodifiableCollection(Arrays.asList(new Capability[] | 0 |
static String convertToString(char[] a) {
StringBuilder sb = new StringBuilder();
for (char c : a) {
sb.append(c);
}
return sb.toString();
}
@Test
public void testSecondLevelAdapter() {
Adapter ca = converter.getAdapter();
ca.rule(char[].clas... | 0 |
* 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... | 0 |
content = null;
} | 0 |
@Test
public void testZooKeeperStartupTime() {
// set specific zookeeper startup time
MiniAccumuloConfigImpl config = new MiniAccumuloConfigImpl(tempFolder.getRoot(), "password").setZooKeeperStartupTime(5000).initialize();
assertEquals(5000, config.getZooKeeperStartupTime());
}
| 0 |
/**
* Add a value to the buffer.
*
* <p>Elements added will not be reflected in {@code OutputT} objects returned by
* previous calls to {@link #read}.
*/
/**
* Returns a {@link ReadableState} whose {@link #read} method will return true if this state is
* empty at the point when that {@link #rea... | 0 |
* Construct a <CODE>ds:Reference</CODE> from an {@link org.w3c.dom.Element}. | 0 |
@Test
public void testExternalizedCheckpointsConfigs() {
String[] args = new String[] { "--externalizedCheckpointsEnabled=true",
"--retainExternalizedCheckpointsOnCancellation=false" };
final FlinkPipelineOptions options = PipelineOptionsFactory.fromArgs(args)
.as(FlinkPipelineOptions.class)... | 0 |
if (urlStr == null) return ret;
| 0 |
if (this.start != null)
this.start.prev = end; | 0 |
* @since 1.0
/**
* The default running mode.
* @see Settings#getRunningMode()
*/
/**
* Default reload delay for configurations in milliseconds.
* @see Settings#getReloadDelay(String)
*/
/**
* The default encoding for the web container.
* @see Settings#getContainerEn... | 0 |
* This class is Employee POJO class with properties- employee name and address. Used in {@linkplain
* HadoopInputFormatIO} for different unit tests.
/** Empty constructor required for Avro decoding. */
if (empAddress != null
? !empAddress.equals(employeePojo.empAddress) | 1 |
* @version $Revision$ $Date$ | 0 |
public IoConnectFuture connect(
SocketAddress address, AttributeRepository context, SocketAddress localAddress) { | 0 |
import java.net.URL;
* can add additional attamchemtns to the output of the configuration rendering.
* {@link AttachmentProvider} service.
public interface AttachmentProvider
* Return an array of attachments for the given render mode.
* The returned list should contain URLs pointing to the
* attachment... | 0 |
import org.apache.hc.core5.http.nio.command.RequestExecutionCommand;
import org.apache.hc.core5.io.CloseMode;
close(CloseMode.GRACEFUL);
public void close(final CloseMode closeMode) {
this.log.debug("Shutdown connection pool " + closeMode);
this.pool.close(closeMode);
... | 0 |
* $Revision: 1.12 $
* $Date: 2003/10/09 21:04:44 $
* Alternately, this acknowledgement may appear in the software itself,
* if and wherever such third-party acknowledgements normally appear.
* permission of the Apache Software Foundation.
* @version $Revision: 1.12 $ $Date: 2003/10/09 21:04:44 $ | 0 |
import static com.google.common.base.Preconditions.checkNotNull;
SchedulerLifecycle(
DriverFactory driverFactory,
this.driverFactory = checkNotNull(driverFactory);
this.scheduler = checkNotNull(scheduler);
this.lifecycle = checkNotNull(lifecycle);
this.driver = checkNotNull(driver);
this.... | 0 |
ingest = cluster
.exec(TestIngest.class, "-c", cluster.getClientPropsPath(), "--rows", rows + "")
.getProcess(); | 0 |
import org.apache.ambari.server.controller.spi.Request;
import org.apache.ambari.server.controller.spi.Resource;
import org.apache.ambari.server.controller.spi.SystemException;
import org.apache.ambari.server.controller.spi.TemporalInfo;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
... | 0 |
import org.apache.ambari.server.security.authorization.GroupType;
ldapGroup.setGroupType(GroupType.LDAP); | 0 |
final boolean booleanValue = conf.getBoolean("test.boolean");
final byte testValue = 10;
final byte byteValue = conf.getByte("test.byte");
final double testValue = 10.25;
final double doubleValue = conf.getDouble("test.double");
final float testValue = (float) 20.25;
... | 0 |
for (ImmutableNode node : getModel().getNodeHandler().getRootNode()
.getChildren()) | 0 |
/*
* 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 ... | 0 |
package org.apache.felix.ipojo.runtime.core.test.components;
import org.apache.felix.ipojo.annotations.Component;
@Component(name="nofactory", public_factory=false)
public class NoFactory {
} | 0 |
/*
* 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 ... | 0 |
import org.apache.beam.sdk.testing.UsesSplittableParDoWithWindowedSideInputs;
@Test
@Category({
ValidatesRunner.class,
UsesSplittableParDo.class,
UsesSplittableParDoWithWindowedSideInputs.class
})
public void testWindowedSideInput() throws Exception {
PCollection<Integer> mainInput =
p.a... | 0 |
@Default.InstanceFactory(DefaultProjectFactory.class) | 0 |
private static final long serialVersionUID = 9136852385761725494L;
// Pointer to the CONSTANT_Class_info structure representing the | 0 |
Filter getSource();
void setSource(Filter src);
int getFilterResolutionX();
void setFilterResolutionX(int filterResolutionX);
int getFilterResolutionY();
void setFilterResolutionY(int filterResolutionY); | 0 |
import com.google.inject.Inject;
import org.apache.ambari.server.actionmanager.StageFactory;
@Inject
private static StageFactory stageFactory;
@Inject
public StageUtils(StageFactory stageFactory) {
StageUtils.stageFactory = stageFactory;
}
@Inject
Stage s = stageFactory.createNew(requestId, "/tmp"... | 0 |
*
*
*/
* superclass are returned by reflection but an IllegalAccessException is thrown
| 0 |
/*
* 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 ... | 0 |
public interface PublicKeyEntryDecoder<PUB extends PublicKey, PRV extends PrivateKey> extends PublicKeyEntryResolver { | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/TestMapUtils.java,v 1.19 2003/11/16 00:05:47 scolebourne Exp $
import org.apache.commons.collections.map.LazyMap;
import org.apache.commons.collections.map.PredicatedMap;
* @versi... | 0 |
List<String> guids = getAtlasClient().createEntity(entityJSON);
return new Referenceable(guids.get(0), referenceable.getTypeName(), null);
AtlasClient atlasClient = new AtlasClient(atlasEndpoint); | 0 |
for (String name : new String[]{null, "", getCurrentTestName()}) {
String name = expected.getName();
Class<?> clazz = expected.getFactoryClass(); | 1 |
properties.setProperty(Configuration.MPACKS_V2_STAGING_DIR_PATH.getKey(),"src/test/resources/mpacks-v2"); | 0 |
import org.apache.hc.client5.http.sync.methods.HttpGet; | 0 |
} finally {
client.close();
String principal = getPrincipal(job);
AuthenticationToken token = getAuthenticationToken(job);
try (AccumuloClient c = Accumulo.newClient().from(getClientProperties(job)).build()) { | 0 |
if (propertiesDirFile == null) {
LOG.error("Failed to load value from property file. Properties directory is null");
} else {
LOG.error("Failed to load value from property file. Properties directory {} does not exist", propertiesDirFile.getAbsolutePath());
} | 0 |
* Invoked to generate a HTTP request message head. | 0 |
private static final PipelineOptionsParameter PIPELINE_OPTIONS_PARAMETER =
new AutoValue_DoFnSignature_Parameter_PipelineOptionsParameter();
return PIPELINE_OPTIONS_PARAMETER; | 0 |
Connector conn =
env.getInstance().getConnector(WalkingSecurity.get(state, env).getSysUserName(),
WalkingSecurity.get(state, env).getSysToken()); | 0 |
log.error("{}", e.getMessage(), e);
log.error("{}", e.getMessage(), e);
log.error("{}", e.getMessage(), e);
log.error("{}", e.getMessage(), e);
log.error("{}", e.getMessage(), e);
log.error("{}", e.getMessage(), e);
log.error("{}", e.getMessage(), e); | 0 |
import com.google.common.annotations.VisibleForTesting;
import java.io.IOException;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentLinkedQueue;
import java.util.concurrent.ConcurrentMap;
import javax.annotation.Nullable; | 0 |
return i.compareTo(Integer.valueOf(4)) < 0;
list1.add(Integer.valueOf(1));
list1.add(Integer.valueOf(2));
list2.add(Integer.valueOf(3));
list2.add(Integer.valueOf(4)); // will be ignored by the predicate | 0 |
public void encode(FileResult value, OutputStream outStream)
throws IOException {
encode(value, outStream, Context.NESTED);
}
@Override
public FileResult decode(InputStream inStream) throws IOException {
return decode(inStream, Context.NESTED);
}
@Override | 0 |
@Override | 0 |
import org.apache.beam.vendor.guava.v20_0.com.google.common.base.Suppliers;
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.ArrayListMultimap;
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.ImmutableList;
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.Immuta... | 0 |
/*
* $Header: /cvshome/build/ee.foundation/src/java/net/NetPermission.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
*
* (C) Copyright 2001 Sun Microsystems, Inc.
* Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use ... | 0 |
import org.apache.ambari.view.hive2.actor.message.ResetCursor;
import org.apache.ambari.view.hive2.client.ColumnDescription;
import org.apache.ambari.view.hive2.client.ColumnDescriptionShort;
import org.apache.ambari.view.hive2.client.Row;
import org.apache.ambari.view.hive2.persistence.Storage;
public ResultSetItera... | 0 |
private final Wire wireLog;
public LoggingIOSession(final IOSession session, final Logger log, final Logger wireLog) {
this.wireLog = wireLog != null ? new Wire(wireLog, session.getId()) : null;
this.channel = wireLog != null ? new LoggingByteChannel() : session.channel();
if (bytesR... | 0 |
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.collect.ImmutableList; | 0 |
final List<WorkerTask> workers = new ArrayList<>(); | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.