Diff
stringlengths
5
2k
FaultInducingLabel
int64
0
1
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
package org.apache.ambari.server.agent; import java.util.List; * * Data model for Ambari Agent to send heartbeat to Ambari Server. //TODO add serialization List<CommandReport> reports; //TODO add serialization List<ComponentStatus> componentStatus; //TODO add serialization NodeStatus nodeStatus; } ...
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jxpath/src/java/org/apache/commons/jxpath/ri/compiler/NodeNameTest.java,v 1.2 2001/09/21 23:22:44 dmitri Exp $ * $Revision: 1.2 $ * $Date: 2001/09/21 23:22:44 $ * @version $Revision: 1.2 $ $Date: 2001/09/21 23:22:44 $ public clas...
0
import com.google.common.collect.Lists;
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/observed/Attic/ObservedTestHelper.java,v 1.7 2003/09/20 12:13:59 scolebourne Exp $ * @version $Revision: 1.7 $ $Date: 2003/09/20 12:13:59 $ Object removed = it.next(); //...
0
import org.apache.http.HttpStatus; import org.apache.http.HttpVersion; import org.apache.http.conn.SchemeRegistry; import org.apache.http.message.BasicHttpRequest; import org.apache.http.params.BasicHttpParams; import org.apache.http.params.HttpParams; import org.apache.http.params.HttpProtocolParams; import org.apache...
0
/* * Copyright 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 applicable la...
0
*---------------------------------------------------------------------------* public Object evaluate(Reader scriptreader) ReflectObject. newInstance(interpreter, object.getClass(), object), // should not happened we just register an object }
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 l...
0
public void testGetExecutionSchedulerWait() throws Exception { final Properties ambariProperties = new Properties(); final Configuration configuration = new Configuration(ambariProperties); //default Assert.assertEquals(new Long(1000L), configuration.getExecutionSchedulerWait()); ambariPropertie...
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 l...
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.Constants; String s = new String(labels, Constants.UTF8); builder.append(" ").append(new String(m.getRow(), Constants.UTF8)).append("\n"); builder.append(" ").append(new String(update.getColumnFamily(), Constants.UTF8)).append(":") .append(new Stri...
0
import org.apache.sshd.agent.unix.AprLibrary; import org.apache.sshd.common.PropertyResolver; import org.apache.sshd.common.PropertyResolverUtils; import org.apache.sshd.common.util.OsUtils; return isPreferredUnixAgent(manager) ? UnixAgentFactory.DEFAULT_FORWARDING_CHANNELS : LocalAgentF...
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
package org.apache.cocoon.el.impl.parsing;
0
private HttpParams params = null; public HttpRequestExecutor(final HttpContext parentContext) { public HttpRequestExecutor() { this(null); } public HttpParams getParams() { return this.params; } public void setParams(final HttpParams params) { this.params = para...
0
package org.apache.felix.webconsole.internal.core; import org.apache.felix.webconsole.Action; import org.apache.felix.webconsole.internal.BaseManagementPlugin;
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
List<String> searchPath = searchPathResultColumn.isEmpty() ? ImmutableList.of() :
0
WindowedStream<StreamingWindowedElement<Void, TimeInterval, WindowedPair<TimeInterval, Integer, Integer>>, Integer, EmissionWindow<FlinkWindow>> windowed; DataStream<StreamingWindowedElement<Void, TimeInterval, WindowedPair<TimeInterval, Integer, Integer>>> reduced; new ReduceFunction<StreamingWindowedE...
0
import org.apache.commons.jelly.util.ClassLoaderUtils; return ClassLoaderUtils.getClassLoader(classLoader, useContextClassLoader, getClass());
0
getProducingTransformInternal().finishSpecifyingInternal();
0
return JobKeys.canonicalString(canonicalTask.getJob());
0
import static org.apache.beam.vendor.guava.v20_0.com.google.common.base.Preconditions.checkArgument; import org.apache.beam.vendor.guava.v20_0.com.google.common.util.concurrent.Uninterruptibles;
0
private final DataSource datasource; private final String table; private final String nameColumn; private final String keyColumn; private final String valueColumn; private final String name;
0
String signatureFileName = "hereSignature.xml"; /* */ /* */
0
import org.apache.hc.client5.http.cache.ResourceIOException; * @throws ResourceIOException if something bad happens while trying to read the body from the original entry final HttpResponse response) throws ResourceIOException {
0
* or more contributor license agreements. See the NOTICE file * regarding copyright ownership. The ASF licenses this file * with the License. You may obtain a copy of the License at * KIND, either express or implied. See the License for 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...
0
import junit.framework.Assert;
0
protected static final HashMap<String, ObjectPool<? extends Connection>> pools = pools.put(name, pool);
0
package org.apache.accumulo.core.client.admin;
0
import static org.junit.Assert.assertEquals; public void testNamedCompose() { PTransform<PCollection<Integer>, PCollection<Integer>> composed = PTransform.compose("MyName", (PCollection<Integer> numbers) -> numbers); assertEquals("MyName", composed.name); } @Test
0
import java.io.Closeable; public class LineIterator implements Iterator<String>, Closeable { try { close(); } catch (final IOException e) { ioe.addSuppressed(e); } * Closes the underlying {@code Reader}. * then the {@code ...
0
private final List<String> args = new LinkedList<String>(); private final List<Option> options = new ArrayList<Option>();
0
import org.apache.ambari.server.controller.utilities.PredicateBuilder; import org.apache.ambari.server.state.StackInfo; import org.apache.ambari.server.state.stack.WidgetLayout; import org.apache.ambari.server.state.stack.WidgetLayoutInfo; import java.util.LinkedHashSet; // Initialize service widgets getMan...
0
import org.apache.accumulo.core.data.TabletId; public abstract TabletId getTablet();
0
import java.util.Properties; * @see org.apache.cocoon.portal.PortalManagerAspect#render(org.apache.cocoon.portal.PortalManagerAspectRenderContext, org.apache.cocoon.portal.PortalService, org.xml.sax.ContentHandler, java.util.Properties) Properties properties) co...
0
import java.util.Base64; createCharactersAndOutputAsEvent(outputProcessorChain, Base64.getMimeEncoder().encodeToString(oaepParams)); createCharactersAndOutputAsEvent(outputProcessorChain, Base64.getMimeEncoder().encodeToString(encryptedEphemeralKey));
0
* @version $Revision$
0
import org.apache.accumulo.core.security.CredentialHelper; conn = instance.getConnector(credentials.getPrincipal(), CredentialHelper.extractToken(credentials));
0
import org.apache.batik.util.SVGConstants; /** * Strings for the 'align' values. */ protected static final String[] ALIGN_VALUES = { null, SVGConstants.SVG_NONE_VALUE, SVGConstants.SVG_XMINYMIN_VALUE, SVGConstants.SVG_XMIDYMIN_VALUE, SVGConstants.SVG_XMAXYM...
0
DoFn<InputT, OutputT> doFn = DoFnAdapters.getDoFn(this); if (doFn != null) { return doFn; } public AdaptedProcessContext(DoFn<InputT, OutputT>.ProcessContext newContext) { @Setup public void setup() throws Exception { OldDoFn.this.setup(); } public void startBundle(Context c...
0
/* * $HeadURL$ * $Revision$ * $Date$ * * ==================================================================== * 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...
0
public final static String AUTO_ADJUST_ACTION = "AutoAdjustAction"; * The auto adjust flag. */ protected boolean autoAdjust; /** listeners.put(AUTO_ADJUST_ACTION, new AutoAdjustAction()); * To adjust the window size on load. */ public class AutoAdjustAction extends AbstractA...
0
package org.apache.ambari.server.api.predicate.operators; import org.apache.ambari.server.api.predicate.InvalidQueryException; import org.apache.ambari.server.controller.predicate.BasePredicate; import org.apache.ambari.server.controller.predicate.EqualsPredicate; import org.apache.ambari.server.controller.predicate.O...
0
public Long getResourceId() { ResourceEntity resourceEntity = clusterEntity.getResource(); if (resourceEntity == null) { LOG.warn("There is no resource associated with this cluster:\n\tCluster Name: {}\n\tCluster ID: {}", getClusterName(), getClusterId()); return null; } else { ...
0
@Override
0
* @version $Revision$ $Date$
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jelly/jelly-tags/define/src/java/org/apache/commons/jelly/tags/define/AttributeTag.java,v 1.2 2003/01/26 00:07:23 morgand Exp $ * $Revision: 1.2 $ * $Date: 2003/01/26 00:07:23 $ * $Id: AttributeTag.java,v 1.2 2003/01/26 00:07:23 ...
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 java.lang.reflect.Array; return (T[]) copyOf(data, size, a.getClass()); Object[] newElements = copyOf(elements, len + added); @SuppressWarnings("unchecked") public static <T> T[] copyOf(T[] original, int newLength) { return (T[]) copyOf(original, newLength, original.getCla...
0
import org.apache.ambari.server.state.PropertyInfo; Map<PropertyInfo, String> notManagedHdfsPathMap = configHelper.getPropertiesWithPropertyType(stackId, PropertyType.NOT_MANAGED_HDFS_PATH, cluster, desiredConfigs); Set<String> notManagedHdfsPathSet = configHelper.filterInvalidPropertyValues(notManagedHdfsP...
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
logStorage = createLogStorage(dbStorage, INITIALIZATION_LOGIC); private LogStorage createLogStorage(DbStorage storage, Work.NoResult.Quiet initializationLogic) { LogStorage logStorage = new LogStorage(logManager, clock, shutdownRegistry, ...
0
* @version $Id$
0
import org.apache.hc.core5.annotation.Internal; @Internal
0
setMap(new HashMap<E, MutableInteger>()); super.doReadObject(in);
0
/* import org.objectweb.asm.Type; /** * Flag sets to true for parameter annotation. */ private boolean m_isParameterAnnotation = false; /** * For parameter annotations, the index of the parameter. */ private int m_index = -1; /** * For parameter annotation, the descripto...
0
* <li>If a package is exported, the classes must be marked with either ConsumerType or ProviderType return "exportannotation";
0
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.Iterables;
0
import java.util.ArrayList; import java.util.List; * @version $Revision: 1.2 $, $Date: 2004/05/04 22:27:10 $ public void testGetList() { BaseConfiguration conf = new BaseConfiguration(); conf.setProperty("test.abc", "value0,value1"); conf.addProperty("test.abc","value3"); Conf...
0
* Extension of {@link AbstractTestMap} for exercising the {@link TransformedMap}
0
c.store(DELAYED_UNTIL_TAG, c.window(), earliestTimer); c.setTimer(c.window(), earliestTimer, TimeDomain.SYNCHRONIZED_PROCESSING_TIME); public void clear(TriggerContext c) throws Exception { c.remove(DELAYED_UNTIL_TAG, c.window()); c.deleteTimer(c.window(), TimeDomain.SYNCHRONIZED_PROCESSING_TIME);
0
* <p> * <p> * <p> * &quot;A#C&quot; &amp; B
0
List<ElementValuePairGen> elements = new ArrayList<ElementValuePairGen>(); List<ElementValuePairGen> elements = new ArrayList<ElementValuePairGen>(); Vector<AnnotationEntryGen> v = new Vector<AnnotationEntryGen>(); Vector<AnnotationEntryGen> v2 = new Vector<AnnotationEntryGen>();
0
* @version $Id: FormManager.java,v 1.3 2004/06/01 10:51:28 bruno Exp $ * <p>To avoid having to resolve the Source object yourself, * use the {@link #createForm(java.lang.String)} method. * * Creates a form instance based on the XML form definition * that can be retrieved from the specified URI...
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/ArrayStack.java,v 1.14 2003/09/20 14:01:17 scolebourne Exp $ * @version $Revision: 1.14 $ $Date: 2003/09/20 14:01:17 $ /** Ensure serialization compatability */ privat...
0
org.apache.commons.logging.LogFactory.getLog(StorageResolver.class);
0
public interface CombiningState<InputT, AccumT, OutputT> CombiningState<InputT, AccumT, OutputT> readLater();
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
protected final Parameters parameters; * @param environment Describes the environment for the component. * @param info Describes the configuration/settings for the component. // this is our default logger: final String category = this.serviceInfo.getLoggerCategory(); if ( category ...
0
*/ public LXOR() { super(org.apache.bcel.Constants.LXOR); } /** * Call corresponding visitor method(s). The order is: * Call visitor methods of implemented interfaces first, then * call methods according to the class hierarchy in descending order, * i.e., the most specific visi...
0
package aQute.libg.cryptography; import aQute.lib.hex.*; public abstract class Digest { final byte[] digest; protected Digest(byte[] checksum, int width) { this.digest = checksum; if (digest.length != width) throw new IllegalArgumentException("Invalid width for digest: " + digest.length + " expected " ...
0
import org.apache.atlas.typesystem.TypesDef; import org.apache.atlas.typesystem.types.utils.TypesUtil; public class TraitTest extends HierarchicalTypeTest<TraitType> { } @Override protected HierarchicalTypeDefinition<TraitType> getTypeDefinition(String name, AttributeDefinition... attributes) { re...
0
import org.apache.commons.collections.CollectionUtils; import org.apache.commons.lang3.StringUtils; private final String query; this.query = query; this.queryContext = Parser.parse(query); public GremlinQuery translate() throws AtlasBaseException { ...
0
* @version CVS $Id: JXPathBindingBase.java,v 1.11 2004/02/03 12:22:08 joerg Exp $ public abstract void doLoad(Widget frmModel, JXPathContext jxpc) throws BindingException; public final void loadFormFromModel(Widget frmModel, JXPathContext jxpc) throws BindingException { public final void loadFormFromModel(...
0
PCollection<TimestampedValue<KV<String, Integer>>> timestamped = res.apply(Reify.timestamps()); p.apply( "main", p.apply( "side", p.apply( "main", p.apply( "side", PCollection<KV<String, Iterable<Integer>>> grouped =...
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
/** * <p> * An implementation of * {@link org.apache.commons.fileupload.FileUpload FileUpload} * for use in servlets conforming to JSR 53. This implementation requires * only access to the servlet's current <code>HttpServletRequest</code> * instance, and a suitable * {@link org.a...
0
import org.apache.ambari.server.orm.entities.RepositoryVersionEntity; /** * Gets whether all host components whose desired repository version matches * the repository version specified have reported the correct version and are * no longer upgrading. * * @param repositoryVersion * the repos...
0
// upto 2.1.x the logging configuration was named "logkit-config" // we still support this, but provide a new unbiased name as well } else { value = getInitParameter(config, "logging-config"); if ( value != null ) { s.setLoggingConfiguration("context:/" + ...
0
import net.jcip.annotations.Immutable; @Immutable
0
* @version $Id: FTPClient2.java,v 1.2 2002/04/30 13:59:42 brekke Exp $ /** * The only constructor for this class. */ * data connection cannot be opened. If the current working directory * contains no files, an empty array will be the return. * @param basedir The file or directory to list....
0
package org.apache.hadoop.metadata.types; import org.apache.hadoop.metadata.IReferenceableInstance; import org.apache.hadoop.metadata.MetadataException; import org.apache.hadoop.metadata.MetadataService; import org.apache.hadoop.metadata.storage.Id; import org.apache.hadoop.metadata.IReferenceableInstance; import org.a...
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
* Copyright 2001-2006 The Apache Software Foundation.
0
import java.nio.charset.Charset; public static Charset getCharset(PropertyResolver resolver, String name, Charset defaultValue) { Object value = getObject(resolver, name); return (value == null) ? defaultValue : toCharset(value); } public static Charset getCharset(Map<String, ?> props, Stri...
0
package org.apache.commons.vfs.operations.vcs; /** * todo: add class description here * * @author Siarhei Baidun * @since 0.1 */ public interface VcsModifyListener { /** * * @param path * @param contentStatus */ void modified(final String path, final int contentStatus); }
0
import static java.lang.String.format; import static javax.tools.Diagnostic.Kind.*; import javax.annotation.processing.Messager; import javax.lang.model.element.Element; // processingEnv is a predefined member in AbstractProcessor class // Messager allows the processor to output messages to the enviro...
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
name, rootName, name.getRootURI());
0
private static class RangeReader extends BoundedReader<Integer> { private static class FailingReader extends BoundedSource.BoundedReader<Integer> {
0
/** * An InputFormat that turns the file data ingested with FileDataIngest into an InputStream. Mappers used with this InputFormat must close the InputStream. */
0
import org.apache.beam.vendor.grpc.v1p13p1.io.grpc.Context; import org.apache.beam.vendor.grpc.v1p13p1.io.grpc.Contexts; import org.apache.beam.vendor.grpc.v1p13p1.io.grpc.Metadata; import org.apache.beam.vendor.grpc.v1p13p1.io.grpc.Metadata.Key; import org.apache.beam.vendor.grpc.v1p13p1.io.grpc.ServerCall; import org...
0
Object o=i.next(); try { ((Plugin) pluginList.get(o)).unregisterServicePlugin(); }catch(Exception e){ System.out.println("INFO Something went wrong when unregistering the Plugin. Please control the beavior of the unregisterServicePlugin function of this tab"+o); }
0
* @version $Id$
0
extendedAtts.add( GVTAttributedCharacterIterator.TextAttribute.STROKE_PAINT); textRun.getLayout().draw(g2d, (float)(location.getX() + x), (float)(location.getY())); AffineTransform t = AffineTransform.getTranslateInstance( location....
0
Byte.valueOf((byte)1), Short.valueOf((short)1),
0