Diff
stringlengths
5
2k
FaultInducingLabel
int64
0
1
private static final long serialVersionUID = -2505664948818681153L;
0
server.setForwardingFilter(AcceptAllForwardingFilter.INSTANCE);
0
/* Generated By:JavaCC: Do not edit this line. TokenMgrError.java Version 3.0 */
0
final TimeValue timeout = requestConfig.getConnectionTimeout(); timeout, if (TimeValue.isPositive(timeout)) { endpoint.setSocketTimeout(timeout.toMillisIntBound());
0
int count = 0; for (Mutation m : mutations) count += m.size(); defaultMap.mutate(mutations, count); nativeMapWrapper.mutate(mutations, count); localityGroupMap.mutate(mutations, count); localityGroupMapWithNative.mutate(mutations, count);
0
ResultSetIterator(final ResultSetDynaClass dynaClass) { public boolean contains(final String name, final String key) { public Object get(final String name) { } catch (final SQLException e) { public Object get(final String name, final int index) { public Object get(final String name, final St...
0
package org.apache.batik.refimpl.gvt;
0
package org.apache.http.impl.client.cache;
0
import org.junit.Rule; @Rule public TestPipeline p = TestPipeline.create(); /** Test the {@link ParseEventFn} {@link org.apache.beam.sdk.transforms.DoFn}. */
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
m_mapPostProcessors = new HashMap<>(); listProcessors = new ArrayList<>();
0
import java.io.PrintWriter; import org.apache.commons.net.ProtocolCommandEvent; import org.apache.commons.net.ProtocolCommandListener; public class PrintCommandListener implements ProtocolCommandListener { private PrintWriter __writer; public PrintCommandListener(PrintWriter writer) { __writer = wri...
0
if (option == null || res == null) return TypeHandler.createValue(res, option.getType());
0
import org.apache.commons.collections.ComparatorUtils; public class NullComparator<E> implements Comparator<E>, Serializable { private Comparator<E> nonNullComparator; @SuppressWarnings("unchecked") this(ComparatorUtils.NATURAL_COMPARATOR, true); public NullComparator(Comparator<E> nonNullComparato...
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.accumulo.test.continuous;
0
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.Lists;
0
return InputConfigurator.createClient(callingClass, context.getConfiguration());
0
try (ByteArrayOutputStream os = new ByteArrayOutputStream()) { Transformer transformer = tFactory.newTransformer(); DOMSource source = new DOMSource(xsltElement); StreamResult result = new StreamResult(os); transformer....
0
import com.google.cloud.hadoop.gcsio.GoogleCloudStorageReadOptions; GoogleCloudStorageReadOptions readOptions = GoogleCloudStorageReadOptions.builder().setFastFailOnNotFound(false).build(); null, "dummybucket", "dummyobject", null, new ClientRequestHelper<>(), readOptions);
0
* A java.util.Date property. */ private java.util.Date dateProperty; public java.util.Date getDateProperty() { return dateProperty; } public void setDateProperty(java.util.Date dateProperty) { this.dateProperty = dateProperty; } /** * A java.util.Date property. ...
0
* * * * @version CVS $Id$ *
0
import static org.apache.ambari.server.security.authorization.RoleAuthorization.CLUSTER_MANAGE_WIDGETS; import java.util.EnumSet; import org.apache.ambari.server.security.authorization.ResourceType; if (!isScopeAllowedForUser(scope, clusterName)) { String clusterName = propertyMap.get(WIDGET_CLUS...
0
import java.util.Arrays; import java.util.Collection; import org.apache.sshd.common.NamedResource; import org.apache.sshd.common.util.ValidateUtils; import org.apache.sshd.server.auth.BuiltinUserAuthFactories; default String getUserAuthFactoriesNameList() { return NamedResource.Utils.getNames(getUserAuthFac...
0
return new LinkEntry<>(next, hashCode, convertKey(key), value); return new LinkMapIterator<>(this); return new EntrySetIterator<>(this); return new KeySetIterator<>(this); return new ValuesIterator<>(this);
1
return new AfterEach(Arrays.asList(triggers));
0
public class URLFileName extends GenericFileName { public URLFileName(final String scheme, final String hostName, final int port, final int defaultPort, final String userName, final String password, final String path, final FileType type, final String queryString) { public String getQuer...
1
protected static final String kerberosRule = "RULE:[1:$1@$0](.*@EXAMPLE.COM)s/@.*//\nDEFAULT";
0
* $Header: /home/cvs/jakarta-commons/latka/src/java/org/apache/commons/latka/jelly/PostTag.java,v 1.4 2002/07/14 16:41:38 dion Exp $ * $Revision: 1.4 $ * $Date: 2002/07/14 16:41:38 $ * Copyright (c) 1999-2001 The Apache Software Foundation. All rights * import org.apache.commons.httpclient.HttpUrlMethod; import ...
0
import java.nio.charset.StandardCharsets; resp.setContentType("text/xml;charset=" + StandardCharsets.UTF_8.name()); sb.append("<?xml version=\"1.0\" encoding=\"" + StandardCharsets.UTF_8.name() + "\"?>\n");
0
import java.io.Serializable; import java.util.Arrays; import java.util.List;
0
import org.apache.hc.core5.http.ContentType; import org.apache.hc.core5.http.impl.io.EmptyInputStream; final BasicHttpEntity httpentity = new BasicHttpEntity(new ByteArrayInputStream(bytes), bytes.length, null); final BasicHttpEntity httpentity = new BasicHttpEntity(EmptyInputStream.INSTANCE, 10, ...
0
import org.apache.accumulo.core.security.Credentials; List<KeyExtent> candidates = findTablets(!opts.selectFarTablets, new Credentials(opts.principal, opts.getToken()), opts.tableName, instance, tabletLocations); List<FileRef> files = getTabletFiles(new Credentials(opts.principal, opts.getToken()), op...
0
import javax.xml.stream.XMLStreamException; import java.io.IOException; import java.io.Writer; @Override public void writeAsEncodedUnicode(Writer writer) throws XMLStreamException { try { writer.write("<?"); writer.write(getTarget()); final String data = getData(); ...
0
import java.util.ArrayList; private InMemoryTimerInternals timerInternals; this.timerInternals = new InMemoryTimerInternals(); return timerInternals; timerInternals.advanceProcessingTime(currentProcessingTime); timerInternals.advanceProcessingTime(currentProcessingTime); List...
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 applicable la...
0
List<Long> clusterIds = new ArrayList<>();
0
if (version == null || version == "") { throw new DeploymentException(DeploymentException.CODE_BAD_HEADER, "Invalid '" + org.osgi.framework.Constants.BUNDLE_VERSION + "' header for manifest entry '" + getPath() + "'"); } m_customizer = parseBooleanHeader(attributes, Constants.DEPLOYM...
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
* @version CVS $Id: ProfileManager.java,v 1.8 2003/07/31 14:37:05 cziegeler Exp $ * @param layoutID The id of a layout object or null for the root object
0
Collections.emptySet();
0
/** Tests for {@link Trigger}. */ assertEquals( "Repeatedly.forever(AfterWatermark.pastEndOfWindow())", protected Trigger getContinuationTrigger(List<Trigger> continuationTriggers) { protected Trigger getContinuationTrigger(List<Trigger> continuationTriggers) {
1
* <pre> * </pre>
0
Map<String,Cluster> clusterMap = new HashMap<>(); Map<String, Host> hostMap = new HashMap<>();
0
import org.apache.http.util.CharArrayBuffer; * HTTP response writer that serializes its output to an instance of * {@link org.apache.http.io.SessionOutputBuffer}. public DefaultHttpResponseWriter(final LineFormatter formatter) { super(formatter); public DefaultHttpResponseWriter() { super(null...
0
import java.util.List; private List<AgentAlert> alerts; /** * Sets alert information from the agent */ public void setAlerts(List<AgentAlert> alertInfo) { alerts = alertInfo; } /** * Gets alert information from the agent */ public List<AgentAlert> getAlerts() { return alerts; }
0
import org.apache.ambari.server.controller.AmbariManagementControllerImpl; ServiceOsSpecific hostOs = populateServicePackagesInfo(serviceInfo, osFamily); TreeMap<String, String> clusterLevelParams = null; TreeMap<String, String> ambariLevelParams = null; if (getManagementController() ins...
0
System.out.println("Updating component with " + conf);
0
package org.osgi.converter; /** * Start a conversion for the given object. * * @param obj The object that should be converted. * @return A {@link Converting} object to complete the conversion. */ Converting convert(Object obj); /** * Obtain a builder to create a modified converter based on this converter...
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jelly/src/java/org/apache/commons/jelly/parser/XMLParser.java,v 1.9 2002/04/24 13:03:03 jstrachan Exp $ * $Revision: 1.9 $ * $Date: 2002/04/24 13:03:03 $ * $Id: XMLParser.java,v 1.9 2002/04/24 13:03:03 jstrachan Exp $ import org....
0
* @param t The original {@link Throwable} - ignored if {@code null} * @return If {@link Throwable#getCause()} is non-{@code null} then * the cause, otherwise the original exception - {@code null} if * the original exception was {@code null} */ public static Throwable resolveExceptionCause(T...
0
import org.apache.beam.runners.core.construction.ArtifactServiceStager.StagedFile; stager.stage(Collections.singleton(StagedFile.of(file, file.getName()))); stager.stage( ImmutableList.of( StagedFile.of(file, file.getName()), StagedFile.of(otherFile, otherFile.getName()), ...
0
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.collect.Lists;
0
public void testGetRackSensitiveServicesNames() throws AmbariException { Set<String> res = metaInfo.getRackSensitiveServicesNames(STACK_NAME_HDP, "2.0.7"); assertEquals(1, res.size()); assertEquals("HDFS", res.iterator().next()); } @Test
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 applica...
0
import org.apache.commons.lang3.StringUtils; HealthCheckSelector selector = StringUtils.isNotBlank(tags) ? HealthCheckSelector.tags(tags.split(",")) : HealthCheckSelector.empty(); Collection<HealthCheckExecutionResult> results = healthCheckExecutor.execute(selector, options);
0
final MessageConstraints constraints = HttpParamConfig.getMessageConstraints(params); final HttpEntity entity = prepareDecoder(this.request); } catch (final HttpException ex) { } catch (final Exception ex) { final int bytesWritten = this.outbuf.flush(this....
0
import org.apache.batik.util.SMILConstants;
0
private static class ConfigurationDeserializer extends JsonDeserializer<Configuration> { DeserializationContext deserializationContext) throws IOException { private static class ConfigurationSerializer extends JsonSerializer<Configuration> { SerializerProvider serializerProvider) throws IOException ...
0
* @version $Id$
0
import org.apache.accumulo.core.clientImpl.Table; import org.apache.accumulo.core.clientImpl.Tables;
0
import org.apache.accumulo.cloudtrace.instrument.Span; import org.apache.accumulo.cloudtrace.instrument.Trace; import org.apache.accumulo.cloudtrace.instrument.Tracer; import org.apache.accumulo.cloudtrace.thrift.TInfo;
0
* Copyright (C) 2015 Google Inc.
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
* <li>their host name strings string-compare equal; or</li> * <li>A is a HDN string and has the form NB, where N is a non-empty * x.y.com domain-matches .Y.com but not Y.com.)</li>
0
public class PosixParserTest extends ParserTestCase super.setUp(); public void testBursting() throws Exception public void testUnrecognizedOptionWithBursting() throws Exception public void testMissingArgWithBursting() throws Exception public void testStopBursting2() throws Exception asse...
0
* * dataSource = pds; connectionFactory.setMaxConnLifetimeMillis(getMaxConnLifetimeMillis());
0
for (InetAddress remoteAddress: addresses) { sock.connect(new InetSocketAddress(remoteAddress, port), timeout); throw new ConnectTimeoutException("Connect to " + remoteAddress + " timed out");
0
private final KeyExtent extent; private final MajorCompactionReason reason; private final VolumeManager volumeManager; private final AccumuloConfiguration tableConfig; private final BlockCache indexCache; private final BlockCache summaryCache; private final ServerContext context;
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
import org.apache.accumulo.fate.zookeeper.ZooUtil;
0
/**Signature - Optional ECDSAwithSHA224 */ public static final String ALGO_ID_SIGNATURE_ECDSA_SHA224 = "http://www.w3.org/2001/04/xmldsig-more#ecdsa-sha224";
0
import org.apache.beam.vendor.grpc.v1p21p0.io.grpc.stub.CallStreamObserver; import org.apache.beam.vendor.grpc.v1p21p0.io.grpc.stub.StreamObserver;
0
Assert.assertTrue(qu.getPeer(observerIndex).peer.getName() .endsWith(String.format(":%d", port3)));
0
import org.apache.http.nio.testserver.HttpCoreNIOTestBase; import org.apache.http.nio.testserver.LoggingClientConnectionFactory; import org.apache.http.nio.testserver.LoggingServerConnectionFactory;
0
try (ClientSession session = client.connect(getCurrentTestName(), TEST_LOCALHOST, port) .verify(7L, TimeUnit.SECONDS) .getSession()) {
0
if (fileName == null) { } if (file != null) { } if (name == null) { } return expandProperty(configurationProperties.getProperty(PREFIX + name));
0
public void initializeSecurity(TCredentials itw, String rootuser) throws AccumuloSecurityException { // create the root user with all system privileges, no table privileges, and no record-level // authorizations zoo.putPersistentData(ZKUserPath + "/" + rootuser + ZKUserAuths, ZKSecurityT...
0
ELEMENT_PARAMETER_METHOD, DoFn.class)), TypeCasting.to(new TypeDescription.ForLoadedType(p.elementT().getRawType())));
0
public List<? extends UnboundedSource<Long, CountingSource.CounterMark>> split(
0
private static final Logger log = LoggerFactory.getLogger(Halt.class);
0
LOG.debug("Creating BeamFnMapTaskExecutor"); LOG.debug("Starting BeamFnMapTaskExecutor, launching progress thread"); LOG.debug("Stopping BeamFnMapTaskExecutor, grabbing final metric updates");
0
import org.apache.beam.sdk.io.BoundedSource.BoundedReader;
0
public static final String USE_LOCAL_CONFIGS_PROPERTY = "logfeeder.configs.local.enabled"; public static final boolean USE_LOCAL_CONFIGS_DEFAULT = false; public static final String USE_SOLR_FILTER_STORAGE_PROPERTY = "logfeeder.configs.filter.solr.enabled"; public static final boolean USE_SOLR_FILTER_STORAGE_DE...
0
String invalidTablePropFormatString = "Invalid per-table property : {}, still removing from zookeeper if it's there."; Shell.log.warn(invalidTablePropFormatString, property); Shell.log.warn(invalidTablePropFormatString, property); Shell.log.warn(invalidTablePropFormatString...
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 applicable law o...
0
public void before() { public void testWriteMetricsWithCommittedSupported() throws Exception { @Test public void testWriteMetricsWithCommittedUnSupported() throws Exception { MetricQueryResults metricQueryResults = new CustomMetricQueryResults(false); PipelineOptions pipelineOptions = PipelineOptionsFa...
0
for (Method declaredMethod : AuroraSchedulerManager.Iface.class.getDeclaredMethods()) { .transform(input -> input.getType().getRawType()) input -> input.getAnnotation(AuthorizingParam.class) != null);
0
public void write(final byte[] b) throws IOException public void write(final byte[] b, final int off, final int len) throws IOException
0
import org.apache.beam.sdk.nexmark.model.AuctionPrice; import org.apache.beam.sdk.transforms.ParDo; public class SqlQuery2 extends PTransform<PCollection<Event>, PCollection<AuctionPrice>> { public PCollection<AuctionPrice> expand(PCollection<Event> allEvents) { .apply(getName() + ".ToRow", ToRow.parDo()) ...
0
import java.util.Arrays; import java.util.List; public static List<FrameworkMethod> computeTestMethodsForClass(final Class klass, final List<FrameworkMethod> defaultMethods) { List<FrameworkMethod> list = defaultMethods; String methodName = System.getProperty("test.method"); if (methodName =...
0
try { if (textElement.getTagName().equals(SVG_ALT_GLYPH_TAG)) { SVGAltGlyphElementBridge altGlyphBridge = (SVGAltGlyphElementBridge)ctx.getBridge(textElement); Glyph[] glyphArray = altGlyphBridge.createAltGlyphArray(ctx, textEle...
0
package org.apache.commons.beanutils2.priv;
1
for (MultiStatusResponse response : responses)
0
* @param fields * - the fields that are expected in the returned Map
0
@Category(com.google.cloud.dataflow.sdk.testing.RunnableOnService.class)
0
Object svc = usage.m_svcHolderRef.getAndSet(null).m_service; .getRegistration().ungetService(bundle, svc);
0
public class ZooCacheIT extends SimpleMacIT { assertEquals(0, exec(CacheTestClean.class, "/zcTest-42", "/tmp/zcTest-42").waitFor()); CacheTestReader.main(new String[]{"/zcTest-42", "/tmp/zcTest-42", getConnector().getInstance().getZooKeepers()}); assertEquals(0, exec(CacheTestWriter.class, "/zcTest-...
0
private static org.slf4j.Logger log =
1
String script = "import os\nos._exit(0)"; Command command = new Command("root", script, param); Command cleanUp = new Command("root", script, param); action.setComponent("hdfs"); action.setRole("datanode"); action2.setComponent("hdfs"); action3.setClusterId("cluster-003"); action3.setCom...
0