Diff
stringlengths
5
2k
FaultInducingLabel
int64
0
1
(XMLSignatureInput input, Transform _transformObject) return enginePerformTransform(input, null, _transformObject); try { byte[] decodedBytes = Base64.decode(sb.toString()); return new XMLSignatureInput(decodedBytes); Base64.decode(sb....
1
package org.apache.http;
0
import org.apache.hc.core5.http.impl.BasicHttpTransportMetrics; final BasicHttpTransportMetrics metrics = new BasicHttpTransportMetrics(); final BasicHttpTransportMetrics metrics = new BasicHttpTransportMetrics(); final BasicHttpTransportMetrics metrics = new BasicHttpTransportMetrics(); ...
1
* @return the node that is the signature
0
/* $Id: FinderFromResource.java,v 1.4 2004/05/10 06:30:08 skitching Exp $ *
0
/* $Id$ * * 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"); ...
0
* @param title The advisory title. See also the section. * @param media The comma-separated list of media associated with the * new style sheet. See also the section.
0
import static com.google.common.collect.Maps.transformValues; import java.util.Optional; import org.apache.ambari.server.topology.ConfigurableHelper; import org.codehaus.jackson.map.ObjectMapper; /** * * @param properties properties in <i>name -> value</i> format * @param attributes attributes in <i>...
0
/** Tag name for Batik's color switch extension. */ public static final String BATIK_EXT_COLOR_SWITCH_TAG = "colorSwitch"; /** Tag name for Batik's histogram normalization extension. */ public static final String BATIK_EXT_HISTOGRAM_NORMALIZATION_TAG = "histogramNormalization"; /*...
1
/* $Id: RegexMatcher.java,v 1.8 2004/05/10 06:30:06 skitching Exp $ *
0
osgiHelper.waitForService(Factory.class, "(factory.name=COMPO-FooProviderType-1)", 1000);
0
import org.apache.spark.SparkConf; * Pipeline p = [logic for pipeline creation] * EvaluationResult result = SparkPipelineRunner.create().run(p); * <p/> * To create a pipeline runner to run against a different spark cluster, with a custom master url * we would do the following: * Pipeline p = [logic for pipeline c...
0
DataElement(final String description) {
0
package org.apache.hc.core5.testing.nio;
0
Schema schema = CalciteUtils.toSchema(rowType); .apply(ParDo.of(new CalcFn(executor, CalciteUtils.toSchema(rowType)))) projectStream.setRowSchema(CalciteUtils.toSchema(getRowType()));
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/TestLRUMap.java,v 1.13 2002/02/20 20:51:38 morgand Exp $ * $Revision: 1.13 $ * $Date: 2002/02/20 20:51:38 $ * @version $Id: TestLRUMap.java,v 1.13 2002/02/20 20:51:38 morgand Ex...
0
import org.apache.hc.core5.http.URIScheme; if (URIScheme.HTTP.same(pv.getProtocol())) {
0
/** Get repository info given a cluster and host. */
0
if (origPropValue != null) {
0
// now try with a START command, but still unresolved Assert.assertFalse(commandParams.containsKey(KeyNames.VERSION)); // now that the repositoryVersion is resolved, it should populate the version even // though the state is INSTALLING repositoryVersion.setResolved(true); ormTestHelper.reposito...
0
shouldThrow("A&\"B\\");
0
* Copyright (c) OSGi Alliance (2000, 2017). All Rights Reserved.
0
private void activator() { if ( bundle != null ) { if ( context != null ) { if ( config != null ) { if ( !config.get("email").equals("foo") ) { if ( !config.get("port").equals("80") ) { if ( config.get("t...
0
import org.apache.commons.configuration.ex.ConfigurationException;
0
DoFnRunner<InputT, OutputT> underlying, BoundedWindow sideInputWindow = view.getWindowMappingFn().getSideInputWindow(mainInputWindow); public void onTimer( String timerId, BoundedWindow window, Instant timestamp, TimeDomain timeDomain) {
1
* ";" separated list of people to send to * ";" separated list of people to cc
0
* User: guillaume * Date: 11/07/13 * Time: 14:41 */ if (context.getClassNode() != null) { new Element(m_name, m_namespace)); } else if (context.getFieldNode() != null) { new Element(m_name, m_namespace), context.getFieldNode()); } e...
0
/* ==================================================================== * @version $Revision: 1.3 $ $Date: 2004/01/14 21:43:16 $
0
import java.io.IOException; import java.util.concurrent.atomic.AtomicInteger; import org.apache.zookeeper.TestableZooKeeper; import org.apache.zookeeper.WatchedEvent; import org.apache.zookeeper.Watcher.Event.KeeperState; private AtomicInteger authFailed = new AtomicInteger(0); @Override protected Tes...
0
public void testInterpolationSystemProperties()
0
private final Log log = LogFactory.getLog(CPool.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 m...
0
* @author <A HREF="mailto:m.dahm@gmx.de">M. Dahm</A>
0
boolean valid = true; valid = false; if (!JsonUtils.isValidJson(propertyValue)) { valid = false; break; // fallthrough // no validity check if (valid) { pi.setValue(propertyValue); ...
0
import org.apache.beam.model.pipeline.v1.MetricsApi; @Test public void testUserDistribution() { SimpleMonitoringInfoBuilder builder = new SimpleMonitoringInfoBuilder(); builder.setUrn(MonitoringInfoConstants.Urns.USER_DISTRIBUTION_COUNTER); builder.setLabel(MonitoringInfoConstants.Labels.NAME, "myName...
0
import org.apache.accumulo.server.fs.VolumeManagerImpl; FileSystem fs = VolumeManagerImpl.get().getDefaultVolume().getFileSystem();
0
// they are regularly captured within DoFn's.
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//validator/src/test/org/apache/commons/validator/DoubleTest.java,v 1.5 2003/05/22 02:29:46 dgraham Exp $ * $Revision: 1.5 $ * $Date: 2003/05/22 02:29:46 $ * @version $Revision: 1.5 $ $Date: 2003/05/22 02:29:46 $ validator.ad...
0
/** * A collection wrapper that only permits clients to shrink the collection. **/
0
* @version $Id$
0
/** Defines IO connectors for Amazon Web Services S3. */
1
for (final Map.Entry<String, HttpRequestHandler> entry: handlerMap.entrySet()) {
0
long startTime = System.currentTimeMillis(); while (true) { if(System.currentTimeMillis() - startTime >= 10000) { throw new RuntimeException("Zookeeper did not start within 10 seconds . Check the logs in " + config.getLogDir() + " for errors."); }
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/OrderedMap.java,v 1.3 2003/12/02 23:51:49 scolebourne Exp $ * @version $Revision: 1.3 $ $Date: 2003/12/02 23:51:49 $ public interface OrderedMap extends IterableMap {
0
import net.jcip.annotations.Immutable; @Immutable
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 java.io.Reader; * This class implements an event-based parser for the SVG points public class PointsParser extends NumberParser { /** * The points handler used to report parse events. */ protected PointsHandler pointsHandler; /** * Whether the last character was a 'e' or 'E'. ...
0
package org.apache.sling.felix.webconsole.internal.core; import org.apache.sling.felix.webconsole.Action; import org.apache.sling.felix.webconsole.internal.BaseManagementPlugin;
0
private final Bundle m_installingBundle; m_installingBundle = null; BundleImpl(Felix felix, Bundle installingBundle, BundleArchive archive) throws Exception m_installingBundle = installingBundle; int operationType; Bundle target; ...
1
* <p>Two values of type {@code T} are compared for equality <b>not</b> by * <p>Optionally, a function may be provided that maps each element to a representative * <p>By default, the {@code Coder} of the output {@code PCollection} * <p>Each output element is in the same window as its corresponding input * <p>Does n...
0
public void resourceOffers(SchedulerDriver driver, final List<Offer> offers) { // Store all host attributes in a single write operation to prevent other threads from // securing the storage lock between saves. We also save the host attributes before passing // offers elsewhere to ensure that host attribu...
0
import java.util.List; public class BeanListHandler<T> implements ResultSetHandler<List<T>> { private final Class<T> type; public BeanListHandler(Class<T> type) { public BeanListHandler(Class<T> type, RowProcessor convert) { public List<T> handle(ResultSet rs) throws SQLException {
0
.add(new RequestExpectContinue()).build();
0
final int dig1 = Character.digit(buffer.charAt(index + 1), HEX_BASE); final int dig2 = Character.digit(buffer.charAt(index + 2), HEX_BASE); final char value = (char) (dig1 << BITS_IN_HALF_BYTE | dig2); final char[] digits = public static String[] encode(final Stri...
1
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//validator/src/share/org/apache/commons/validator/Var.java,v 1.7 2003/08/21 19:40:13 rleland Exp $ * $Revision: 1.7 $ * $Date: 2003/08/21 19:40:13 $ * Copyright (c) 2001-2003 The Apache Software Foundation. All rights * any, ...
0
package org.apache.ambari.funtest.server.api.service; import org.apache.ambari.funtest.server.ConnectionParams;
0
private Storage storage; private void buildScheduler(Storage newStorage) throws Exception { this.storage = newStorage; ImmediateJobManager immediateManager = new ImmediateJobManager(storage); Set<ScheduledTask> tasks = Storage.Util.fetchTasks(storage, queryJob(OWNER_A, JOB_A)); storage = createStora...
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...
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.beam.sdk.testing.TestPipeline; /** Utilities for working with the {@link ValueProvider} interface. */ * Given {@code serializedOptions} as a JSON-serialized {@link PipelineOptions}, updates the * values according to the provided values in {@code runtimeValues}. * * @deprecated Use {@link T...
0
package org.apache.felix.persister.test.objects.provider; import org.apache.felix.persister.test.objects.Bottom; import org.apache.felix.persister.test.objects.SimpleMiddle; public class SimpleMiddleEntity extends SimpleMiddle.SimpleMiddleDTO implements SimpleMiddle { public SimpleMiddleEntity(SimpleMiddleDTO dto)...
0
Copyright 2001-2003 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...
0
import com.google.cloud.dataflow.sdk.options.PipelineOptions; private final PipelineOptions options; public TranslationContext(ExecutionEnvironment env, PipelineOptions options) { this.options = options; public PipelineOptions getPipelineOptions() { return options; }
0
/** * @return Returns the item class name. */ String getItemClassName(); /** * @param itemClassName The item class name to set. */ void setItemClassName(String value);
0
* @param patternTile region to which the pattern is constrained FilterRegion patternTile, if(patternTile == null){ Rectangle2D patternBounds = patternTile.getRegion(); Shape aoiShape = (Shape)hints.get(GraphicsNode.KEY_AREA_OF_INTEREST); Rectan...
0
TSERV_WORKQ_THREADS("tserver.workq.threads", "2", PropertyType.COUNT, "The number of threads for the distributed workq. These threads are used for copying failed bulk files."),
0
import org.apache.batik.constants.XMLConstants;
0
new DBColumnInfo(PROVISION_ACTION_COL, String.class, 255, null, true));
0
createTableOptFormatter = new Option("f", "formatter", true, "default formatter to set"); createTableOptFormatter.setArgName("className");
0
package com.twitter.aurora.scheduler.cron.noop; import java.util.Date; import com.twitter.aurora.scheduler.cron.CronPredictor; /** * A cron predictor that always suggests that the next run is Unix epoch time. * * This class exists as a short term hack to get around a license compatibility issue - Real * Implemen...
0
filter = (sb.length() > 3) ? sb.toString() : null;
0
import org.apache.accumulo.core.metadata.schema.Ample; import org.apache.accumulo.server.metadata.ServerAmpleImpl; @Override public Ample getAmple() { return new ServerAmpleImpl(this); }
0
public final static long CONFIG_FILE_RELOAD_DELAY = 60000;
0
package org.apache.cocoon.template.jxtg.instructions; import org.apache.cocoon.template.jxtg.script.event.AttributeEvent; import org.apache.cocoon.template.jxtg.script.event.CopyAttribute; import org.apache.cocoon.template.jxtg.script.event.Event; import org.apache.cocoon.template.jxtg.script.event.StartElement; import...
0
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.cache.CacheBuilder; import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.cache.CacheLoader; import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.cache.LoadingCache;
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
import com.google.api.services.cloudresourcemanager.CloudResourceManager.Projects.Delete; Delete deleteRequest = Transport.newCloudResourceManagerClient(options.as(CloudResourceManagerOptions.class)) .build().projects().delete("testProjectId");
0
package org.apache.commons.beanutils2; import org.apache.commons.beanutils2.BasicDynaClass; import org.apache.commons.beanutils2.BeanUtils; import org.apache.commons.beanutils2.ConvertUtils; import org.apache.commons.beanutils2.DynaBean; import org.apache.commons.beanutils2.DynaClass; import org.apache.commons.beanutil...
1
Copyright 2001 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 or a...
0
package org.apache.commons.ognl; import java.math.BigDecimal; import java.math.BigInteger; import java.util.HashMap; import java.util.Map; /** * Numeric primitive literal string expressions. */ class NumericLiterals { private final Map<Class<? extends Number>, String> map = new HashMap<Class<? extends Number>,...
1
/* ==================================================================== * @version $Revision: 1.3 $ $Date: 2004/01/14 21:43:06 $
0
/* * Copyright 1999-2005 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
/** * {@link FileUploadBase#getItemIterator(RequestContext)}. /** * @throws FileUploadException Parsing or processing the * file item failed. * @throws IOException Reading the file item failed. * @return True, if one or more additional file items * are available, otherwise false. /...
0
import org.apache.accumulo.core.security.tokens.InstanceTokenWrapper; public void initializeSecurity(InstanceTokenWrapper token, String rootuser) throws AccumuloSecurityException {
0
import java.io.FileInputStream; import java.io.FileOutputStream; import java.lang.management.ManagementFactory; updateInstancePid(); private void updateInstancePid() { try { if (!karafHome.equals(karafBase)) { String instanceName = System.getProperty("karaf.name"); ...
0
import java.util.Map.Entry; waitForAll(zk, States.CONNECTED); while (someoneNotConnected) { ClientBase.logAllStackTraces(); for (ZooKeeper zk : zks) {
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.beam.vendor.guava.v20_0.com.google.common.annotations.VisibleForTesting;
0
package org.apache.accumulo.core.client.mapreduce; public class InputTableConfigTest {
0
List<Object> argValues = new ArrayList<>(); Set<String> lines = new TreeSet<>();
1
System.getProperty("test.data.dir", "src/test/resources/data"));
0
import java.util.Comparator; * The class must implement the required service interface. Class defaultimplementation() default Class.class; /** * Set the comparator. * The indicated class must implement {@link Comparator} */ Class comparator() default Comparator.class;
0
* A base class that can be used to create Samplers based on hashing. This class offers consistent * options for configuring the hash function. The subclass decides which parts of the key to hash. * This class support two options passed into {@link #init(SamplerConfiguration)}. One option is * {@code hasher} which s...
0
Copyright 2001,2003-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
List<Object> contentCopy = new ArrayList<>(content); List<Object> newContent = 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 ...
0
import com.google.cloud.dataflow.sdk.testing.CoderProperties;
0
import org.apache.http.nio.impl.reactor.SessionInputBuffer;
0
* Configure an existing ZooKeeper instance to use. Calling this method is optional. If not set, a new ZooKeeper instance is created. * * @param existingZooKeepers * Connection string for a already-running ZooKeeper instance * * @since 1.7.0 */ public MiniAccumuloConfig setExistingZooKeep...
0
void consumeData(final ByteBuffer src) throws HttpException, IOException { exchangeHandler.consume(src);
0