Diff
stringlengths
5
2k
FaultInducingLabel
int64
0
1
* @deprecated use the one from excalibur sourceresolve instead * @version CVS $Id: ModifiableTraversableSource.java,v 1.5 2003/10/23 10:37:27 unico Exp $
0
InputStream is = null; is = getClass().getClassLoader().getResourceAsStream(name + suffix); if (is != null) { return is; } return getClassFile(name, suffix).getInputStream();
0
provider.deleteResources(new RequestImpl(null, null, null, null), createPredicate(1L));
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
import org.apache.beam.sdk.testing.ExpectedLogs; private static final String REPLACEMENT_JOB_ID = "replacementJobId"; @Rule public ExpectedLogs expectedLogs = ExpectedLogs.none(DataflowPipelineJob.class); if (state == State.UPDATED) { statusResponse.setReplacedByJobId(REPLACEMENT_JOB_ID); } exp...
0
import org.apache.accumulo.core.clientImpl.ClientInfo; * {@link ClientContext#ClientContext(SingletonReservation, ClientInfo)} is kept up-to-date if we * move the {@link SystemToken}<br>
0
assertThat(mgr.removeAll(), Matchers.emptyIterable());
0
Set<StackConfigurationDependencyRequest> requests) throws AmbariException { Set<StackConfigurationDependencyResponse> response = new HashSet<StackConfigurationDependencyResponse>(); if (requests != null) { String stackName = request.getStackName(); String serviceName = requ...
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
} catch (CompactionCanceledException cce) { log.debug("Major compaction canceled, extent = " + getExtent()); failed = true; } catch (IOException ioe) { log.error("MajC Failed, extent = " + getExtent(), ioe); failed = true; } catch (RuntimeException e) { log.erro...
0
* @version $Revision: 1.5 $ $Date: 2004/05/16 11:16:01 $ * Evaluates the predicate returning true if all predicates return true. * * @param object the input object * @return true if all decorated predicates return true *
0
/** Returns a {@link RootProviderRegistry} that supports the Java SDK root transforms. */ /** Returns a {@link RootProviderRegistry} that only supports the {@link Impulse} primitive. */ private RootProviderRegistry(Map<String, RootInputProvider<?, ?, ?>> providers) {
1
package org.apache.sshd.client.subsystem.sftp.extensions.openssh.impl; import org.apache.sshd.client.subsystem.sftp.extensions.openssh.OpenSSHFsyncExtension; import org.apache.sshd.client.subsystem.sftp.extensions.openssh.OpenSSHStatExtensionInfo; import org.apache.sshd.client.subsystem.sftp.extensions.openssh.OpenSSHS...
0
import org.apache.sshd.common.channel.ChannelPipedOutputStream; import org.apache.sshd.common.future.CloseFuture; import org.apache.sshd.common.future.SshFuture; import org.apache.sshd.common.future.SshFutureListener; import org.apache.sshd.common.util.IoUtils; import org.apache.sshd.server.CommandFactory;
0
protected Coder<T> getDefaultOutputCoder() { return source.getDefaultOutputCoder(); } @Override public Coder<T> getDefaultOutputCoder() { return boundedSource.getDefaultOutputCoder(); return new CheckpointCoder<>(boundedSource.getDefaultOutputCoder());
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
exceptionPlease(impl, "\u82b1\u5b50.foo.com", x509); exceptionPlease(impl, "\u82b1\u5b50.bar.com", x509); Assert.assertTrue(DefaultHostnameVerifier.matchIdentity("a.B.c", "*.b.c")); Assert.assertTrue(DefaultHostnameVerifier.matchIdentityStrict("a.B.c", "*.b.c")); Assert.assertTr...
0
import java.util.Map; Map<String, Object> getValuesMap() throws MetadataException;
0
else if (value instanceof NodeSet) { count = ((NodeSet) value).getPointers().size(); }
0
Set<MetricUpdate> cloudCountersFromSet = new HashSet<>( CloudCounterUtils.extractCounters(set, true)); Set<MetricUpdate> cloudCountersFromArray = new HashSet<>(CounterTestUtils.extractCounterUpdates(Arrays.asList(counters), true)); assertEquals(cloudCountersFromSet, cloudCountersFromArray);
0
* @version CVS $Id: AggregateJXPathBindingBuilder.java,v 1.6 2004/02/03 12:26:21 joerg Exp $ extends JXPathBindingBuilderBase { CommonAttributes commonAtts = JXPathBindingBuilderBase.getCommonAttributes(bindingElm);
0
return (isInclusiveHostCount() ? network : broadcastLong() - networkLong() > 1 ? network + 1 : 0); return (isInclusiveHostCount() ? broadcast : broadcastLong() - networkLong() > 1 ? broadcast -1 : 0); return format(toArray(broadcast)); ret...
0
try { curChar = ASCII_CharStream.readChar(); } try { curChar = ASCII_CharStream.readChar(); } try { curChar = ASCII_CharStream.readChar(); } try { curChar = ASCII_CharStream.readChar(); } try { curChar = ASCII_CharStream.readChar(); } try { curChar = ASCII_CharStream.readChar(); } try { curCh...
0
import org.apache.bcel.classfile.LineNumber; * @author <A HREF="mailto:m.dahm@gmx.de">M. Dahm</A>
0
public Set<StateTag<?>> getTagsInUse(StateNamespace namespace) { Set<StateTag<?>> inUse = new HashSet<>(); for (Map.Entry<StateTag<?>, State> entry :
0
* $HeadURL$ * $Revision$ * $Date$ * @version $Revision$
0
private ListUtils() {}
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 static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.junit.jupiter.api.Assertions.fail; @org.junit.jupiter.ap...
0
p.traverseTopologically(new StreamingSourceTracker(jssc, p, ParDo.BoundMulti.class, 0)); p.traverseTopologically(new StreamingSourceTracker(jssc, p, ParDo.BoundMulti.class, 0, 1));
0
.setValidating( true )
0
private static final Identity IDENTITY = new Identity().setUser("user");
0
public void processElement(@Element X input, MultiOutputReceiver r) { r.output(typedTag, input);
0
import static org.apache.ambari.server.agent.ExecutionCommand.KeyNames.GPL_LICENSE_ACCEPTED; hostLevelParams.put(GPL_LICENSE_ACCEPTED, configs.getGplLicenseAccepted().toString());
0
/** Representation of multiple metric updates. */ * return Iterables.isEmpty(counterUpdates()) && Iterables.isEmpty(distributionUpdates());
1
/** Signature - Optional DSAwithSHA256 */ public static final String ALGO_ID_SIGNATURE_DSA_SHA256 = Constants.SignatureSpec11NS + "dsa-sha256";
0
import static org.hamcrest.Matchers.equalTo; import static org.hamcrest.Matchers.nullValue; import static org.junit.Assert.assertThat; underTest.advanceProcessingTime(new Instant(20)); assertThat(underTest.removeNextProcessingTimer(), equalTo(processingTime1)); assertThat(underTest.removeNextProcessingTimer...
0
public class H2MultiplexingRequester extends AsyncRequester{ * Use {@link H2MultiplexingRequesterBootstrap} to create instances of this class. public H2MultiplexingRequester(
0
notificationInterface.setCurrentUser(getUser());
0
/* * Copyright 2013 Twitter, Inc. * * 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 t...
0
import com.google.common.collect.ImmutableList; import org.apache.aurora.gen.Constraint; import org.apache.aurora.gen.Metadata; import org.apache.aurora.gen.TaskConstraint; import org.apache.aurora.gen.TaskEvent; import org.apache.aurora.gen.ValueConstraint; import org.apache.aurora.scheduler.storage.testing.StorageEnt...
0
import org.apache.felix.dm.Component; Component srv = dm.createBundleAdapterService(stateMask, filter, propagate);
0
import org.apache.atlas.store.DeleteType; * Inverse reference update test with SoftDeleteHandlerV1 public InverseReferenceUpdateSoftDeleteV2Test() { super(DeleteType.SOFT); }
0
import org.apache.accumulo.harness.AccumuloClusterHarness; public class BloomFilterIT extends AccumuloClusterHarness {
0
/* * Copyright 2006 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 ...
0
import java.util.concurrent.TimeUnit;
0
import org.apache.beam.sdk.values.TypeDescriptor; TypeDescriptor<OutputT> outputType, TypeDescriptor<K> keyType, super(name, flow, outputType, windowing, euphoriaWindowing, extractor, keyType);
0
/** * Processes the actual HTTP request. The handler can choose to send * response messages immediately inside the call or asynchronously * at some later point. * * @param request the actual request. * @param entityDetails the request entity details or {@code null} if the request ...
0
private static ThreadLocal<SimpleDateFormat> dateFormat = new ThreadLocal() { public SimpleDateFormat initialValue() { SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd"); public SimpleDateFormat getDateFormat() {
0
import org.apache.commons.configuration.ConfigurationException; @Override T get() throws ConfigurationException;
0
state.set("Auths-" + target + '-' + "time", System.currentTimeMillis()); public static boolean ambiguousAuthorizations(State state, String target) { Long setTime = state.getLong("Auths-" + target + '-' + "time"); if (setTime == null) throw new RuntimeException("WTF? Auths-" + target + '-' + "time is...
0
new PoolableConnectionFactory(xaConnectionFactory, null);
0
package org.apache.accumulo.master.tableOps.bulkVer1; import org.apache.accumulo.master.tableOps.MasterRepo; if (!fs.exists(new Path(error, BulkImport.FAILURES_TXT)))
0
* @version CVS $Id: XSPModuleHelper.java,v 1.5 2003/09/24 21:41:11 cziegeler Exp $ }
0
* @version $Revision$
0
import org.apache.zookeeper.data.ACL; ConcurrentHashMap<Long, Integer> sessionsWithTimeouts) throws IOException {
0
import org.apache.accumulo.core.clientImpl.Namespaces; import org.apache.accumulo.core.clientImpl.Tables;
0
DataflowExecutionContext<?> executionContext, DataflowExecutionContext<?> executionContext, DataflowExecutionContext<?> executionContext,
0
data.put(new Key(skvi.getTopKey()), new Value(skvi.getTopValue())); * One of the trickiest cases in writing iterators: After any result is returned from a TabletServer to the client, the Iterator in the TabletServer's * memory may be torn down. To preserve the state and guarantee that all records ar...
0
fail("should ignore " + ignored);
0
return FileUtils.readFileToString(new File(versionFilePath)).trim(); try { Injector injector = Guice.createInjector(new UpgradeHelperModule()); SchemaUpgradeHelper schemaUpgradeHelper = injector.getInstance(SchemaUpgradeHelper.class); String targetVersion = schemaUpgradeHelper.getAmbariServe...
0
public abstract class AbstractContentBody implements ContentBody {
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 com.twitter.mesos.scheduler; import java.util.Set; import com.google.common.collect.ImmutableSet; import com.google.common.collect.Iterables; import org.junit.Test; import com.twitter.mesos.gen.ScheduleStatus; import static com.twitter.mesos.gen.ScheduleStatus.RUNNING; import static org.junit.Assert.assert...
0
package org.apache.felix.ipojo.runtime.core.components; import org.apache.felix.ipojo.runtime.core.services.Dummy; /** * Just a Dummy test */ public class DummyImpl implements Dummy { private void start() { } private void stop() { } }
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 javax.naming.InitialContext; import junit.framework.TestCase; * @version $Id: TestJNDIConfiguration.java,v 1.1 2004/01/16 17:32:36 epugh Exp $ public class TestJNDIConfiguration extends TestCase private Configuration conf; private NonStringTestHolder nonStringTestHolder; InitialContext context = new In...
0
(node.getChildren().isEmpty())) { if (children.isEmpty()) {
0
private AtlasClient atlasClient = null; this.clusterName = clusterName; this.hiveClient = hiveClient; this.atlasClient = atlasClient; public HiveMetaStoreBridge(HiveConf hiveConf) throws Exception { this(hiveConf.get(HIVE_CLUSTER_NAME, DEFAULT_CLUSTER_NAME), Hive.get(hiveConf), n...
0
this.getClass().getClassLoader(),
0
* This interface represents {@link Cancellable} object dependent on another * ongoing process or operation. * Sets {@link Cancellable} dependency on another ongoing process or * operation represented by {@link Cancellable}. /** * Determines whether the process or operation has been cancelled. ...
0
* on a separator. * Concatenates an array of string using a separator. * @param separator the separator between two strings
0
private static Map<HostRoleStatus, EnumSet<HostRoleStatus>> manualTransitionMap = new HashMap<>(); List<StageEntity> stageEntities = new LinkedList<>(); Map<Long, String> resultMap = new HashMap<>(); JpaSortBuilder<StageEntity> sortBuilder = new JpaSortBuilder<>(); List <HostRoleCommandEntity> hrcWi...
1
* Microsoft Windows specific {@link Credentials} representation that includes
0
.getDefaultJavaEnvironmentUrl()));
0
assertThat(item0.getTimestamp(), equalTo(window(0, 10).maxTimestamp())); assertThat(item1.getTimestamp(), equalTo(window(10, 20).maxTimestamp())); public static void groupsElementsIntoSlidingWindowsWithMinTimestamp( SlidingWindows.of(Duration.millis(20)).every(Duration.millis(10))) .withOutput...
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/primitives/adapters/Attic/CollectionShortCollection.java,v 1.3 2003/11/07 20:09:15 rwaldhoff Exp $ * @deprecated This code has been moved to Jakarta Commons Primitives (http://jak...
0
package org.apache.beam.sdk.extensions.euphoria.beam; import org.apache.beam.sdk.extensions.euphoria.core.annotation.audience.Audience; import org.apache.beam.sdk.extensions.euphoria.core.client.accumulators.AccumulatorProvider; import org.apache.beam.sdk.extensions.euphoria.core.client.accumulators.Counter; import org...
0
import org.apache.accumulo.core.security.tokens.SecurityToken; * @throws AccumuloSecurityException public static TabletLocator getTabletLocator(Class<?> implementingClass, Configuration conf) throws TableNotFoundException, AccumuloSecurityException { SecurityToken token = getToken(implementingClass, conf);
0
connector.securityOperations().changeUserAuthorizations(username, labelAuths);
0
package org.apache.batik.dom.svg12; import org.apache.batik.dom.svg.SVGStylableElement; import org.apache.batik.util.SVG12Constants; public class SVGOMSubImageRefElement extends SVGStylableElement { protected SVGOMSubImageRefElement() { public SVGOMSubImageRefElement(String prefix, AbstractDocument owner) { ...
1
import org.junit.Assume; private InputStream createUtf8DataStream(byte[] baseData, boolean addBOM) { private InputStream createUtf16BeDataStream(byte[] baseData, boolean addBOM) { private InputStream createUtf16LeDataStream(byte[] baseData, boolean addBOM) { public void testReadWithBOMUtf32Be() throws E...
0
* {@link BroadcastVariableInitializer} that initializes the broadcast input as a {@code Map} from * window to side input. for (WindowedValue<KV<?, ?>> value : (Iterable<WindowedValue<KV<?, ?>>>) (Iterable) inputValues) { for (BoundedWindow window : value.getWindows()) { for (Map.Entry<BoundedWin...
1
package test; public class Parent { private int m_index = 0; public Parent(int i, String s) { m_index = i + s.length(); } public int getIndex() { return m_index; } }
0
InputT, K, V, OutputT, StateT extends State<V, OutputT>, W extends BoundedWindow> extends WindowingParams<W>{
0
private final String charset; this(CharacterEncodingNames.UTF8);
0
closeManagementFor(event.getBundle()); //TODO Should be done in another thread m_thread.addBundle(context.getBundles()[i]); // Bundles are processed in another thread.
0
private Set<AbstractCheckDescriptor> m_upgradeChecks = new TreeSet<>( new PreUpgradeCheckComparator()); return new ArrayList<>(m_upgradeChecks); List<String> missingChecks = new ArrayList<>(); List<URL> urls = new ArrayList<>(); List<AbstractCheckDescriptor> resultCheckDescriptor = new ArrayList<>...
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 u...
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
* * * // zipFile = createZipFile(this.file); closeCommunicationLink();
0
* any, must include the following acknowledgement: * Alternately, this acknowledgement may appear in the software itself, * if and wherever such third-party acknowledgements normally appear. * permission of the Apache Software Foundation.
0
* any, must include the following acknowledgement: * 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 $Id: ASTUnaryMinusNode.java,v 1.2 2003/10/09 21:28:5...
0
@Warmup(iterations = 1, time = 10, timeUnit = TimeUnit.SECONDS) @Measurement(iterations = 5, time = 5, timeUnit = TimeUnit.SECONDS)
0
public Map<String, AtlasVertex> getVerticesForPropertyValues(String property, List<String> values)
0
"(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}" + // initial 3 fields, 0-255 followed by . "([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])"; // final field, 0-255 "^([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}$"); "^(([0-9A-Fa-f]{1,4}(:[0-9A-Fa-f]{1,4})*)?...
0
CommandRepository commandRepo = repoVersionHelper.getCommandRepository(cluster, componentRM, host); RepoOsEntity repoOsEntity = new RepoOsEntity(); commandRepo = repoVersionHelper.getCommandRepository(cluster, componentRM, host); commandRepo = repoVersionHelper.getCommandRepository(cluster, componentZKC...
0
import org.apache.sshd.common.PropertyResolverUtils; * @param v Checks if the value is &quot;yes&quot;, &quot;y&quot;, * &quot;on&quot;, &quot;t&quot; or &quot;true&quot;. * @see PropertyResolverUtils#TRUE_VALUES if (GenericUtils.isEmpty(v)) { return false; } return P...
0
private ByteChannel byteChan; Mockito.when(session.channel()).thenReturn(byteChan); Mockito.when(session.channel()).thenReturn(byteChan);
0
import org.apache.aurora.common.quantity.Amount; import org.apache.aurora.common.quantity.Data; import org.apache.aurora.scheduler.config.CliOptions; Amount.of(512, Data.KB), BackupModule.Options backupOptions = new BackupModule.Options(); backupOptions.backupDir = backupDir; install(n...
0