Diff
stringlengths
5
2k
FaultInducingLabel
int64
0
1
public static CheckDescription DRUID_HA_WARNING = new CheckDescription( "DRUID_HA", PrereqCheckType.SERVICE, "Druid Downtime During Upgrade", new ImmutableMap.Builder<String, String>() .put( AbstractCheckDescriptor.DEFAULT, "High Availability is not enable...
0
public void testDirectoryBeginningWithNumberFollowedBySpaces() throws Exception { FTPFile f = getParser().parseFTPEntry("12-03-96 06:38AM <DIR> 123 xyz"); assertEquals("name", "123 xyz", f.getName()); f = getParser().parseFTPEntry("12-03-96 06:38AM <DIR> ...
0
import org.apache.commons.jexl3.JexlInfoHandle; public final class SandboxUberspect extends Uberspect { private final Sandbox sandbox; public JexlMethod getConstructor(Object ctorHandle, Object[] args, JexlInfoHandle info) { public JexlMethod getMethod(Object obj, String method, Object[] args, JexlInfoHandl...
1
package com.twitter.mesos.scheduler.httphandlers; import java.io.StringWriter; import javax.ws.rs.WebApplicationException; import javax.ws.rs.core.Response; import org.antlr.stringtemplate.StringTemplate; import com.twitter.common.base.Closure; import com.twitter.common.util.templating.StringTemplateHelper; import ...
0
* * * * * * * *
0
value = tokenParser.parseToken(buf, cursor, delimSet);
0
private static Random numberGenerator; Random ng = numberGenerator; // FELIX-2771 Secure Random not available on Mika try { ng = new SecureRandom(); } catch ( Throwable t ) { // fall back to Random ...
0
import org.apache.beam.runners.core.metrics.MetricsPusher; MetricsPusher.getInstance().pushMetrics();
0
private final List<byte[]> elements; private final Coder<OUT> coder; public FlinkStreamingCreateFunction(List<byte[]> elements, Coder<OUT> coder) { this.elements = elements; this.coder = coder; } @Override public void flatMap(IN value, Collector<WindowedValue<OUT>> out) throws Exception { @Su...
0
@Override @Override @Override @Override @Override @Override
0
* * * * * * * *
1
package org.apache.zookeeper.server; import org.apache.jute.Record; import org.apache.zookeeper.Watcher; import org.apache.zookeeper.data.Id; import org.apache.zookeeper.proto.ReplyHeader; import org.apache.zookeeper.proto.WatcherEvent;
0
* Provides {@link CommittedBundle bundles} that will be provided to the * {@link PTransform PTransforms} that are at the root of a {@link Pipeline}. interface RootInputProvider { * produced by {@link TransformEvaluatorFactory#forApplication(AppliedPTransform, * CommittedBundle)}, all of the elements contained i...
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
return "searches each row, column family, column qualifier and value, in" + " parallel, on the server side (using a java Matcher, so put .* before" + " and after your term if you're not matching the whole element)"; "forces the use of the find() expression matcher, causing substring" ...
0
import org.apache.beam.sdk.transforms.OldDoFn; return input.apply(ParDo.of(new OldDoFn<TimestampedValue<T>, T>() {
0
* @author Bernhard Huber * @since 23. Oktober 2002 * @version CVS $Id: MailCommands.java,v 1.2 2003/03/11 19:04:59 vgritsenko Exp $
0
" <label>Label 1.</label>\n" + " <placeholder>Placeholder 1.</placeholder>\n" + " <default-value>Default value 1.</default-value>\n" +
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jxpath/src/test/org/apache/commons/jxpath/ri/model/dom/DOMModelTest.java,v 1.4 2002/11/26 01:20:08 dmitri Exp $ * $Revision: 1.4 $ * $Date: 2002/11/26 01:20:08 $ import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c....
0
prefix = saslParams + ":";
0
m_logger.log(
0
package org.apache.http.client.utils; import org.apache.http.impl.cookie.DateParseException; public void testMalformedDate() { Assert.assertNull(DateUtils.parseDate("Fri, 14 Oct 2005 00:00:00 GMT", new String[] {}, null)); } @Test
0
* {@link PipelineVisitor#visitPrimitiveTransform} and
0
public InputStream getInputStream() throws IOException createStream();
0
if ("".equals(namespaceURI)) { // Map global namespace from StAX to DOM namespaceURI = null; } if ("".equals(namespaceURI)) { // Map global namespace from StAX to DOM namespaceURI = null; }
0
* Notify about the occurrence of an event
0
import java.util.Set; Type type = new TypeToken<Map<String, Set<String>>>() {}.getType(); Type type = new TypeToken<Map<String, Set<String>>>() {}.getType(); Map<String, Set<String>> clusterHostInfo1 = StageUtils.getGson().fromJson(CLUSTER_HOST_INFO, type); Map<String, Set<String>> clusterHostInfo2 = St...
0
import com.google.common.base.Optional; import com.twitter.mesos.gen.JobKey; public void removeJob(JobKey jobKey) { checkNotNull(jobKey); // TODO(ksweeney): Remove this delegation as part of MESOS-2403. removeJob(Tasks.jobKey(jobKey)); } @Override public Optional<JobConfiguration> fetchJob(String ...
0
* Simple utility class that creates a map for string-based keys by extending * <tt>TreeMap</tt>. This map can be set to use case-sensitive or * case-insensitive comparison when searching for the key. Any keys put into * this map will be converted to a <tt>String</tt> using the * <tt>toString()</tt> method, since i...
0
} catch (SingletonService.LeadException e) { throw new IllegalStateException("Failed to lead service.", e);
0
@Parameter(names = "--sleep", description = "the time to wait between queries", converter = TimeConverter.class) Scanner scanner = ContinuousUtil.createScanner(conn, clientOpts.getTableName(), clientOpts.auths);
0
public NodeGet() { }
0
String[] st = commandLine.split("//s"); String command = st.length > 1? st[1]: HELP_CMD; String arg = (st.length > 2) ? st[2] : null; if (command.equals(HELP_CMD)) help(out, arg); private void help(PrintStream out, String command)
0
final Map<String, String> variants = new HashMap<>();
0
package org.apache.felix.sigil.eclipse.internal.repository.manager;
0
String MAX_CONCURRENT_SESSIONS = "max-concurrent-sessions"; String SERVER_IDENTIFICATION = "server-identification"; String MAX_AUTH_REQUESTS = "max-auth-requests"; String WELCOME_BANNER = "welcome-banner"; String AUTH_METHODS = "auth-methods"; String COMMAND_EXIT_TIMEOUT = "command-exit-timeout"...
0
import org.apache.felix.service.threadio.ThreadIO;
0
* Sets the color of the selection overlay to the specified color. * * @param color the new color of the selection overlay */ public void setSelectionOverlayColor(Color color) { textSelectionManager.setSelectionOverlayColor(color); } /** * Returns the color of the selection overlay...
0
private final HashMap<String,Long> prevGcTime = new HashMap<>();
1
* Copyright (c) 2004 The Apache Software Foundation. All rights * @versionn $Id: NTFTPEntryParserTest.java,v 1.8 2004/01/01 21:04:19 scohen Exp $
0
RepositoryVersionState.INSTALLING);
0
import org.apache.beam.runners.core.construction.RehydratedComponents; import org.apache.beam.runners.core.construction.WindowingStrategyTranslation; import org.apache.beam.sdk.values.WindowingStrategy; import org.apache.beam.vendor.grpc.v1_13_1.com.google.protobuf.InvalidProtocolBufferException; public static Windo...
0
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.ImmutableList;
0
public Set<String> getRequestedPorts() { return task.getRequestedPorts();
0
return input.length() == 1 && contains(bContent, input.charAt(0)) == shouldMatch; return input.length() > 0 && contains(bContent, input.charAt(0)) == shouldMatch; return input.length() > 0 && contains(bContent, input.charAt(...
0
* <p> * </p> * <p> * </p>
0
import org.apache.beam.sdk.io.GenerateSequence; import org.joda.time.Duration; pipeline.apply(GenerateSequence.fromTo(0, numElements)); // Use withMaxReadTime to force unbounded mode. pipeline.apply( GenerateSequence.fromTo(0, numElements).withMaxReadTime(Duration.standardDays(1)));
0
getLog().warn( "Unable to merge Maven manifest: " + e.getLocalizedMessage() );
0
@Test public void testWritePartialUpdate() throws Exception { elasticsearchIOTestCommon.setPipeline(pipeline); elasticsearchIOTestCommon.testWritePartialUpdate(); }
0
import org.apache.beam.sdk.transforms.reflect.DoFnSignature; private static void rejectStateAndTimers(DoFn<?, ?> doFn) { DoFnSignature signature = DoFnSignatures.getSignature(doFn.getClass()); if (signature.stateDeclarations().size() > 0) { throw new UnsupportedOperationException( String.form...
0
/* * Copyright (C) 2014 Google 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 to ...
0
* Copyright 2001-2005 The Apache Software Foundation * Bear in mind that Sets require immutable objects to function correctly. * @version $Revision: 1.8 $ $Date$ * @author Tom Dunham * If it is present, then the old version is removed. Object removed = super.set(index, object); return remo...
0
// to all fields. If the input type of the DoFn is already Row, then no need to do // anything special.
0
import org.apache.hc.core5.http.config.Http1Config; conn = new DefaultBHttpClientConnection(Http1Config.DEFAULT,
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.server.util; import java.util.concurrent.Executors; import java.util.concurrent.ThreadFactory; public class NamingThreadFactory implements ThreadFactory { private ThreadFactory dtf = Executors.defaultThreadFactory(); private int threadNum = 1; private String name; public NamingThrea...
1
@Rule public ExpectedException thrown = ExpectedException.none(); public void encode(KV<String, Long> kv, OutputStream out) throws IOException { public KV<String, Long> decode(InputStream inStream) throws IOException { return other instanceof MyCustomCoder && key.equals(((MyCustomCoder) other).key); ...
1
* @author William Farner
0
final Instance inst = conn.getInstance(); MetadataServicer.forTableId(inst, credentials, tableId).getTabletLocations(tabletLocations); checkTabletServer(inst, conf.getConfiguration(), new Credentials(opts.principal, opts.getToken()), entry, failures); private static void checkTabletServer(Instance...
0
import javax.xml.xpath.XPath; import javax.xml.xpath.XPathConstants; import javax.xml.xpath.XPathFactory; import org.apache.xml.security.samples.DSNamespaceContext; XPathFactory xpf = XPathFactory.newInstance(); XPath xpath = xpf.newXPath(); xpath.setNamespaceContext(new DSNamespaceContext()); ...
0
/** Tests for {@link ApexTimerInternals}. */ TimerData timerData0 = TimerData.of("timerData0", StateNamespaces.global(), instant0, TimeDomain.EVENT_TIME); TimerData timerData1 = TimerData.of("timerData1", StateNamespaces.global(), instant1, TimeDomain.EVENT_TIME); timerInternals.fireReadyTim...
1
@Override public String writeGetTableConstraints(String databaseName, String tableName) { // pg_class: http://www.postgresql.org/docs/9.4/static/catalog-pg-class.html // pg_constraint: http://www.postgresql.org/docs/9.4/static/catalog-pg-constraint.html // pg_namespace: http://www.postgresql.org/docs/9...
0
* Ignores non-BASE64 bytes. @Test assertEncoded("Hello World", "S?G!V%sbG 8g\rV\t\n29ybGQ*=");
0
verifyDeterministic(this, "ListCoder.elemCoder must be deterministic", getElemCoder());
0
/** Specify the password for authentication. */ /** Specify the encrypted password used for authentication. */ * Specify the password decrypter used to decrypt the encrypted password. It delayed the /** Specify the password used for authentication. */ /** Specify the encrypted password used for aut...
0
* * @see <a href="https://tools.ietf.org/html/rfc1945">RFC1945 (HTTP/1.0)</a> * @see <a href="https://tools.ietf.org/html/rfc2616">RFC2616 (HTTP/1.1)</a> * @see <a href="https://tools.ietf.org/html/rfc2518">RFC2518 (WebDAV)</a> * @see <a href="https://tools.ietf.org/html/rfc7540">RFC7540 (HTTP/2)</a>
0
return parentNode; parentNode = v; previousSibling = v; return previousSibling; nextSibling = v; return nextSibling;
1
import org.apache.sshd.common.SshConstants; port = SshConstants.DEFAULT_PORT; return getFileSystemIdentifier(addr.toString(), SshConstants.DEFAULT_PORT, username); + ((port <= 0) ? SshConstants.DEFAULT_PORT : port) + ':'
0
public void onClassificationUpdatedToEntity(String entityId, List<AtlasClassification> classifications) throws AtlasBaseException { // Since the classification attributes are updated in the graph, we need to recursively remap the entityText doFullTextMapping(entityId); ITypedReferenceableIn...
0
/* $Id$ * @version $Revision$ $Date$
0
// get full decoded path for dispatching final RequestInfo requestInfo = new RequestInfo(pr.servletPath, pr.pathInfo, null, req.getRequestURI());
0
* * * import org.apache.avalon.framework.thread.ThreadSafe; implements Parameterizable, ThreadSafe {
0
m_n = n; m_t = t; m_v = v; p.setAttribute( "n", getN() ); if ( getT() != null ) p.setAttribute( "t", getT() ); if ( getV() != null ) p.setAttribute( "v", getV() );
0
import org.apache.felix.ipojo.PrimitiveInstanceDescription; PrimitiveInstanceDescription id_dep = (PrimitiveInstanceDescription) ((Architecture) getContext().getService(arch_ref)).getInstanceDescription(); // id_dep = ((Architecture) getContext().getService(arch_ref)).getInstanceDescription(); //...
0
// Maps from the our unique job identifier (<role>/<jobName>) to the unique identifier used
0
void runAll(OptionT options, NexmarkRunner runner) { throw new RuntimeException("Execution was not successful"); errors = new ArrayList<>(); NexmarkRunner<NexmarkOptions> runner = new NexmarkRunner<>(options); new NexmarkDriver<>().runAll(options, runner);
0
Set<VertexInfo> compositeVertices = graphHelper.getCompositeVertices(instanceVertex); Iterator<Edge> edges = graphHelper.getOutGoingEdgesByLabel(instanceVertex, edgeLabel); Edge edge = graphHelper.getEdgeForLabel(outVertex, edgeLabel); edge = graphHelper.getEdgeFor...
1
* The prior alert firmness. */ private final AlertFirmness m_fromFirmness; /** * @param currentAlert * @param fromState * @param fromFirmness AlertCurrentEntity currentAlert, AlertState fromState, AlertFirmness fromFirmness) { m_fromFirmness = fromFirmness; * Gets the prior firmness of ...
0
import org.apache.ambari.spi.upgrade.UpgradeType;
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
@Override @Override @Override
0
* @see MultiKeyIdentityProvider int numProviders = GenericUtils.size(providers); if (numProviders <= 0) { return EMPTY_KEYS_PROVIDER; } else if (numProviders == 1) { return GenericUtils.head(providers); } else { return new MultiKeyIdentityProvider...
0
import org.apache.accumulo.core.data.TableId; private final TableId tableId; public VolumeChooserEnvironment(TableId tableId, Text endRow, ServerContext context) { public TableId getTableId() {
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
throw new FileSystemException("vfs.impl/unknown-scheme.error", scheme, uri); throw new FileSystemException("vfs.impl/unknown-scheme.error", scheme, uri); throw new FileSystemException("vfs.impl/unknown-provider.error", scheme, file); throw new FileSystemException(...
0
* @version $Revision: 1.2 $, $Date: 2004/01/18 16:18:56 $
0
import org.apache.accumulo.core.data.TableId; TableId id = TableId.of(tableId);
0
import org.eclipse.persistence.exceptions.EclipseLinkException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import javax.persistence.PersistenceException; import java.sql.SQLException; private static final Logger LOG = LoggerFactory.getLogger(AmbariJpaLocalTxnInterceptor.class); //commit transactio...
0
@Deprecated
0
import org.apache.hc.core5.annotation.Contract; import org.apache.hc.core5.annotation.ThreadingBehavior; import org.apache.hc.core5.http.ClassicHttpResponse; import org.apache.hc.core5.http.io.entity.EntityUtils; * org.apache.hc.core5.http.ClassicHttpRequest, org.apache.hc.client5.http.sync.ResponseHandler)}, @Contra...
0
import java.util.Properties; import org.apache.accumulo.core.trace.TraceUtil; TraceUtil.enableClientTraces(null, name, new Properties()); TraceUtil.disable();
0
* useful, ready made
0
import org.apache.batik.css.engine.value.ValueManager;
1
package org.apache.bcel.data; import java.lang.annotation.*; @Retention(RetentionPolicy.RUNTIME) public @interface MarkerAnnotation { }
0
* @version CVS $Id: ClassJXPathBindingBuilder.java,v 1.3 2004/02/03 12:26:21 joerg Exp $ extends JXPathBindingBuilderBase { CommonAttributes commonAtts = JXPathBindingBuilderBase.getCommonAttributes(bindingElm);
0
MacroContext macroContext, Event startEvent, Event endEvent) public String getQname() {
0
import java.io.FileInputStream; import java.util.Properties; final String configFile = params.getParameter("config-file", "/TestDiskCache.ccf"); final String regionName = params.getParameter("region-name", "indexedRegion1"); final String groupName = params.getParameter("group-name", "indexedDisk...
0
// testing the behavior for runSmokeTest flag // piggybacking on this test to avoid setting up the mock cluster testRunSmokeTestFlag(mapRequestProps, amc, serviceRequests); // should be able to add the host component back componentHostRequests.clear(); componentHostRequests.add(new ServiceCompo...
0
/***************************************************************************** * Copyright (C) The Apache Software Foundation. All rights reserved. * * ------------------------------------------------------------------------- * * This software is published under the terms of the Apache Software License * * v...
1
SourceResolver resolver = null; FormManager formManager = null; formManager = (FormManager) getComponent(FormManager.ROLE); releaseComponent(resolver); releaseComponent(formManager); protected String showForm(Form form, String uri) { return show...
0