Diff
stringlengths
5
2k
FaultInducingLabel
int64
0
1
ArrayNode node = (ArrayNode) getDigester().peek();
0
public static final String DEFAULT_SCHEME_NAME = "http"; private String schemeName = null; * @param schemeName the name of the scheme. Value <code>null</code> can be used to set * default scheme public HttpHost(final String hostname, int port, final String schemeName) { if (sc...
0
new HashMap<>(); "team", new WriteWindowedToBigQuery.FieldInfo<>("STRING", (c, w) -> c.element().getKey())); new WriteWindowedToBigQuery.FieldInfo<>("INTEGER", (c, w) -> c.element().getValue())); new WriteWindowedToBigQuery.FieldInfo<>( .apply( PubsubIO.readStrings() ...
0
this.connManager.setDefaultSocketConfig(socketConfig);
0
import org.apache.atlas.repository.graphdb.tinkerpop.query.NativeTinkerpopGraphQuery; public class NativeTitan0GraphQuery implements NativeTinkerpopGraphQuery<Titan0Vertex, Titan0Edge> {
1
import org.apache.cocoon.portal.profile.PortalUser; public boolean matches(PortalUser user) { return user.isUserInRole(this.role);
0
Mockito.when(hdfsService.getDesiredStackId()).thenReturn(new StackId("HDP", "2.2")); Mockito.when(tezService.getDesiredStackId()).thenReturn(new StackId("HDP", "2.2")); Mockito.when(amsService.getDesiredStackId()).thenReturn(new StackId("HDP", "2.2"));
0
if (m_service == null) throw validationFailure( "Use of '$' configuration-pid wildcard requires DS 1.3 or later namespace " ); if (m_dsVersion == DSVersion.DS12Felix)
0
final JobKey jobKey = JobKeys.from("role", "env", "job"); final JobUpdateConfiguration config = new JobUpdateConfiguration(jobKey, updateToken, updateConfiguration); final SaveJobUpdate saveOp = new SaveJobUpdate(jobKey, updateToken, updateConfiguration); storageUtil.updateStore.saveJobUpdat...
0
import java.util.Dictionary; import java.util.Hashtable; Object aspect = ref.getProperty(DependencyManager.ASPECT); String serviceIdToTrack = (aspect != null) ? aspect.toString() : ref.getProperty(Constants.SERVICE_ID).toString(); dependency.setPropagate(this, "propagateA...
0
private final KafkaHeaders headers; KafkaHeaders headers, this(topic, partition, offset, timestamp, timestampType, headers, KV.of(key, value)); KafkaHeaders headers, this.headers = headers; public KafkaHeaders getHeaders() { return headers; } return Arrays.deepHashCode(new Object[] {t...
0
import org.apache.sshd.util.test.NoIoTestCase; import org.junit.experimental.categories.Category; @Category({ NoIoTestCase.class })
0
private final NHttpMessageParser requestParser; private final NHttpMessageWriter responseWriter; protected NHttpMessageWriter createResponseWriter(
0
if (command instanceof ExecutionCommand) { final AsyncClientExchangeHandler exchangeHandler = ((ExecutionCommand) command).getExchangeHandler(); exchangeHandler.failed(new ConnectionClosedException("Connection closed")); exchangeHandler.release...
0
suite.addTest(org.apache.xml.security.test.signature.AllTests.suite()); suite.addTest(org.apache.xml.security.test.utils.AllTests.suite()); suite.addTest(org.apache.xml.security.c14n.implementations.AllTests.suite()); suite.addTest(org.apache.xml.security.test.transforms.implementations.Al...
0
import org.apache.hc.core5.http.ClassicHttpRequest; import org.apache.hc.core5.http.ContentType; import org.apache.hc.core5.http.io.entity.EntityUtils; import org.apache.hc.core5.net.URIBuilder; public static RequestBuilder copy(final ClassicHttpRequest request) { private RequestBuilder doCopy(final ClassicHttp...
0
* <p> * </p> * <p> * </p> * <p> * </p> * <p> * </p> * <p> * </p>
0
* @version $Id: TestPropertiesConfiguration.java,v 1.6 2004/06/03 15:32:46 ebourg Exp $ for (Iterator i = conf.getKeys(); i.hasNext();){ String property = conf.getString("test.unescape"); assertEquals("String with escaped characters", "This \n string \t contains \" escaped \\ characters", prop...
0
public static AbstractComponentHandler getComponentHandler( final Class componentClass, ComponentFactory factory = new ComponentFactory(
0
INVALID_TYPE_DEFINITION(409, "ATLAS4094E", "Invalid type definition {0}"),
0
svc.isClientOnlyService(), pc, null); svc.isClientOnlyService(), pc, h1Params); svc.isClientOnlyService(), pc, h2Params); svc.isClientOnlyService(), pc, null); svc.isClientOnlyService(), pc, null);
0
if (s.charAt(i+1) == 'u') { // working with multi-byte symbols in format %uXXXX sb.append((char)Integer.parseInt(s.substring(i+2, i+6), 16)); i += 5; // 4 digits and 1 symbol u } else { ...
0
import org.apache.beam.sdk.transforms.windowing.Window.Assign; * An implementation of {@link Assign} for the Spark * runner.
0
import org.apache.beam.runners.spark.SparkRunner; import org.apache.beam.sdk.transforms.DoFn; import org.apache.beam.sdk.transforms.reflect.DoFnSignatures; DoFn<InputT, OutputT> doFn = transform.getNewFn(); if (DoFnSignatures.getSignature(doFn.getClass()).stateDeclarations().size() > 0) { thro...
0
* @deprecated 1.3 Use {@link UploadContext#contentLength()} instead
0
static org.slf4j.Logger log = org.slf4j.LoggerFactory.getLogger(RSASecurityTest.class.getName());
1
* @since 1.8.0
0
// [BEAM-5184] Specifically test with a duplicate value to ensure that // duplicate key/values are not lost. KV.of( windowA, WindowedValue.of( ...
0
* http://www.apache.org/licenses/LICENSE-2.0
0
* $Id$ * $Rev$ * $Date$ * Copyright 2004-2005 The Apache Software Foundation
0
import java.util.Collection; * Exports a metric that tracks the size of a collection. * * @param name Name of the stat to export. * @param collection Collection whose size should be tracked. */ default void exportSize(String name, final Collection<?> collection) { makeGauge(name, (Supplier<Number>)...
0
package org.apache.felix.configurator.impl.json; private final BinUtil.ResourceProvider provider; * @param provider The bundle provider, might be {@code null}. public TypeConverter(final BinUtil.ResourceProvider provider) { this.provider = provider; if ( provider == null ) { ...
0
interceptor = new ShiroAuthorizingParamInterceptor(); decoratedThrift.killTasks(JOB_KEY.newBuilder(), null).getResponseCode()); func.apply(new Object[]{new JobConfiguration(), new JobKey(), null}); @AuthorizingParam JobConfiguration jobConfig,
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 ma...
0
import org.apache.felix.eventadmin.impl.tasks.BlockTask; * Called upon stopping the bundle. This will block until all pending events are * delivered. An IllegalStateException will be thrown on new events starting with * the begin of this method. However, it might take some time until we settle ...
0
import org.apache.batik.css.CSSOMReadOnlyValue; import org.apache.batik.css.value.ImmutableString; import org.apache.batik.css.value.ImmutableValue; import org.w3c.dom.css.CSSPrimitiveValue; import org.w3c.dom.css.CSSValue; inst, (ViewCSS)d.getDefaultView(), ...
0
return new ReadableState<Boolean>() { @Nullable @Override public Boolean read() { return !impl.get().iterator().hasNext(); } @Override public R...
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
import org.apache.accumulo.core.client.AccumuloException; import org.apache.accumulo.core.client.AccumuloSecurityException; import org.apache.accumulo.core.replication.ReplicationTableOfflineException; s = conn.createScanner(sourceTableName, Authorizations.EMPTY); // Ensures table is online ...
0
* Configuration keys for {@link Instance#getConnector(String, AuthenticationToken)}.
0
private final String classLoaderContext; this.classLoaderContext = config.getClassLoaderContext(); DurabilityImpl.toThrift(durability), this.classLoaderContext);
1
class Evaluator extends PipelineVisitor.Defaults implements EvaluationContext { public void visitPrimitiveTransform(TransformTreeNode node) {
0
private static final long serialVersionUID = 2429077463161192057L;
0
COMMAND("events.commands"), AGENT_ACTIONS("events.agentactions");
0
current.getId(), current.getZxid(), current.getPeerEpoch()); v.getId(), v.getZxid(), ...
0
Class<?> clazz = Class.forName(cryptorClass);
0
/* * Copyright 2001,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...
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
ReconfigRequest reconfigRequest = (ReconfigRequest)record; QuorumVerifier lastSeenQV = lzks.self.getLastSeenQuorumVerifier(); throw new KeeperException.ReconfigInProgress(); if (newMembers != null) { //non-incremental membership change ...
0
import com.google.common.collect.ImmutableList; import com.google.common.hash.Hashing; import java.io.IOException; import java.util.ArrayList; import java.util.List;
0
import com.fasterxml.jackson.annotation.JsonAutoDetect; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import com.fasterxml.jackson.annotation.JsonInclude; import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility.NONE; import static com.fasterxml.jackson.annotation.JsonAutoDetect.Visibil...
0
* Copyright 2001-2006 The Apache Software Foundation
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/Bag.java,v 1.13 2004/01/05 22:46:33 scolebourne Exp $ * Copyright (c) 2001-2004 The Apache Software Foundation. All rights * @version $Revision: 1.13 $ $Date: 2004/01/05 22:46:3...
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...
1
@Description("AWS region where Kinesis stream resided") @Default.String("aws-kinesis-region") String getAwsKinesisRegion(); void setAwsKinesisRegion(String value); @Description("Kinesis stream name") @Default.String("aws-kinesis-stream") String getAwsKinesisStream(); void setAwsKinesisStream(String ...
0
buffer = session.createBuffer(SshConstants.Message.SSH_MSG_REQUEST_FAILURE, 0); buffer = session.createBuffer(SshConstants.Message.SSH_MSG_REQUEST_FAILURE, 0); buffer = session.createBuffer(SshConstants.Message.SSH_MSG_REQUEST_SUCCESS, 0); buffer = session.createB...
0
* @version $Id: BooleanField.java,v 1.10 2004/05/07 13:42:10 mpo Exp $ String param = formContext.getRequest().getParameter(getRequestParameterName()); throw new RuntimeException("Cannot set value of boolean field \"" + getRequestParameterName() + "\" to a non-Boolean value.");
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
import org.apache.http.auth.AUTH; import org.apache.http.message.BufferedHeader; CharArrayBuffer buffer = new CharArrayBuffer(32); if (isProxy()) { buffer.append(AUTH.PROXY_AUTH_RESP); } else { buffer.append(AUTH.WWW_AUTH_RESP); } ...
0
protected int depth; protected HashSet urlsToProcess; protected HashSet urlsNextDepth;
0
/** * 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 applicable law or agreed to in writing, software * distribu...
0
import java.util.GregorianCalendar; // This is pretty bad hack to work around the deficiencies of the JDK date/time classes. if (recentDateFormat != null && new GregorianCalendar().isLeapYear(now.get(Calendar.YEAR))) {
0
import org.apache.beam.vendor.grpc.v1p13p1.com.google.protobuf.Struct;
0
String zooKeepers = getClientInfo().getZooKeepers();
0
import java.io.BufferedInputStream; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.FileReader; import java.io.FileWriter; import java.io.IOException; import java.io.ObjectInputStream; import ...
0
/** Constant for the supported comment characters.*/ static final String COMMENT_CHARS = "#!"; files = new String[]{value};
0
* This class is a lexicoder that sorts a ComparablePair. Each item in the pair is encoded with the given lexicoder and concatenated together. This makes it * easy to construct a sortable key based on two components. There are many examples of this- but a key/value relationship is a great one. * { * &#064;code * ...
0
* @version $Id$
0
String encCurveName = PublicKeyEntryDecoder.decodeString(keyData); byte[] octets = PublicKeyEntryDecoder.readRLEBytes(keyData); PublicKeyEntryDecoder.encodeString(s, keyType); PublicKeyEntryDecoder.encodeString(s, curveName); PublicKeyEntryDecoder.encodeInt(s, 1 /* the in...
0
/** * Inserts 10K rows (50K entries) into accumulo with each row having 5 entries using an OutputFormat. */ System.out.println("Usage: bin/tool.sh " + this.getClass().getName() + " <instance name> <zoo keepers> <username> <password> <tablename>");
0
public ReadOnlyDictionary( final ServiceReference<?> serviceReference ) public Set<Entry<S, T>> entrySet() public Set<S> keySet() public void putAll( Map<? extends S, ? extends T> m ) public Collection<T> values()
0
import java.util.Objects; if (category == null) { LOG.warn("In stack {}-{} service {} component {} category is null!", stackId.getStackName(), stackId.getStackVersion(), scHost.getServiceName(), scHost.getServiceComponentName()); continue; } if (Objects.equals("MASTER...
0
resource.getQuery().getInternalPredicate());
0
* The config builder for various SFTP configuration options. * <p> * input/output streams between the target host and the VFS host. * public String getFileNameEncoding(final FileSystemOptions opts) * * Gets the proxy to use for the SFTP connection. * * @see #getProxyPort * ...
0
package org.apache.batik.svggen;
0
Assert.assertEquals("default", hdfsResponse.getGroupName()); Assert.assertEquals(Long.valueOf(-1), hdfsResponse.getGroupId());
0
import org.apache.commons.vfs.provider.UriParser; final SmbFileSystem fileSystem) throws FileSystemException this.fileName = UriParser.decode(name.getURI()); return UriParser.encode(file.list());
0
import java.util.concurrent.TimeUnit; try(ClientSession session = client.connect("sshd", "localhost", port).await().getSession()) { session.auth().verify(5L, TimeUnit.SECONDS); try(ByteArrayOutputStream out = new ByteArrayOutputStream(); ByteArrayOutputStr...
0
import com.twitter.aurora.gen.Response; public Response createJob(JobConfiguration job, SessionKey session) { Response response = new Response(); public Response startCronJob(JobKey jobKey, SessionKey session) { Response response = new Response(); public Response killTasks(final TaskQuery query, SessionKe...
0
m_bundle = bundle; m_actionMask = parseActions(actions); m_actionMask = actionMask; return this.getName().equals(p.getName()) && (m_actionMask == p.m_actionMask); if (m_actions == null) m_actions = createActionString(m_actionMask); return m_actions; if ((m_actionMas...
0
import org.apache.felix.moduleloader.IModule; private final WeakReference m_module; super( new CodeSource( Felix.m_secureAction.createURL( Felix.m_secureAction.createURL(null, "location:", new FakeURLStreamHandler()), bundle._getLocation(...
1
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/iterators/CollatingIterator.java,v 1.10 2003/12/03 11:37:44 scolebourne Exp $ import org.apache.commons.collections.list.UnmodifiableList; * @version $Revision: 1.10 $ $Date: 200...
0
ByteBuffer _elem52; // optional Range _elem55; // optional ScanColumn _elem58; // optional IteratorSetting _elem61; // optional ByteBuffer _elem72; // optional Range _elem75; // optional ScanColumn _elem78; // op...
0
/** * Get file object. * @param baseDir The reference towards which the file should be resolved * @param file The path to the file to get * @return The {@link SshFile} for the provided path */ SshFile getFile(SshFile baseDir, String file);
0
import org.w3c.dom.DOMException;
0
import com.google.cloud.dataflow.sdk.util.common.worker.NativeReader; public NativeReader<?> create( static class TestReader extends NativeReader<Integer> { public NativeReaderIterator<Integer> iterator() { class TestReaderIterator extends LegacyReaderIterator<Integer> { public NativeReader<?> create(...
0
public static final Buffer<Object> EMPTY_BUFFER = UnmodifiableBuffer.unmodifiableBuffer(new ArrayStack<Object>(1)); return SynchronizedBuffer.synchronizedBuffer(buffer); return BlockingBuffer.blockingBuffer(buffer); return BlockingBuffer.blockingBuffer(buffer, timeoutMillis); return ...
0
* Enables all components of this holder and if satisfied activates
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...
0
private static final String CLUSTER_REQUEST_TYPE = "org.apache.ambari.server.api.services.ClusterRequestSwagger";
0
public abstract class AbstractIterableGetMapDecorator<K, V> implements IterableGet<K, V> {
0
import org.apache.accumulo.core.iterators.user.IntersectingIterator;
0
import org.apache.ambari.server.state.stack.StackMetainfoXml; import org.w3c.dom.Element; import org.w3c.dom.Node; import javax.xml.bind.JAXBContext; import javax.xml.bind.Unmarshaller; import java.lang.reflect.Field; import java.util.ArrayList; import static org.easymock.EasyMock.createNiceMock; import static org.easy...
0
import org.apache.felix.ipojo.architecture.PropertyDescription; PropertyDescription[] props = factory.getComponentDescription().getProperties(); if (props != null && props.length != 0) { JSONArray properties = new JSONArray(); for (int i = 0; i < props.length; i+...
0
package org.apache.felix.ipojo.runtime.core.services; public interface MyService { public void foo(); }
0
@Test public void testDefaultLocalHost() throws Exception { DefaultClientConnectionOperator operator = new DefaultClientConnectionOperator( SchemeRegistryFactory.createDefault()); operator.resolveHostname("localhost"); }
0
for (String name : new String[]{null, "", getCurrentTestName()}) { for (Class<?> clazz : new Class<?>[]{null, getClass(), SftpClientExtension.class}) { for (Object instance : new Object[]{null, this}) { }
1
StringBuilder all3amsg = new StringBuilder(); all3amsg.append("Method '").append(jc.getMethods()[i]).append("': ") .append(vr.getMessage().replace('\n', ' ') ).append("\n\n"); pass3aTextPane.setText(all3amsg.toString());
0
import org.apache.cocoon.portal.coplet.CopletInstance; import org.apache.cocoon.portal.coplet.CopletInstanceFeatures; public CopletInstanceSizingEvent(CopletInstance target, int size) { if ( size < CopletInstance.SIZE_MINIMIZED || size > CopletInstance.SIZE_FULLSCREEN ) { && Coplet...
0
private void assertDoubleMetaphone(final String expected, final String source) { } catch (final EncoderException e) { public void assertDoubleMetaphoneAlt(final String expected, final String source) { public void doubleMetaphoneEqualTest(final String[][] pairs, final boolean useAlternate) { ...
1