Diff stringlengths 5 2k | FaultInducingLabel int64 0 1 |
|---|---|
protected final Map<Integer, Channel> channels = new ConcurrentHashMap<>(); | 0 |
* Updates the animated value with the given {@link AnimatableValue}. | 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 |
materializationInput.apply(CreatePCollectionView.of(view));
materializationInput.apply(CreatePCollectionView.of(view));
materializationInput.apply(CreatePCollectionView.of(view));
materializationInput.apply(CreatePCollectionView.of(view)); | 0 |
public boolean emitMetrics(TimelineMetrics metrics) {
return super.emitMetrics(metrics); | 0 |
private BlueprintListener blueprintListener;
public BlueprintListener getBlueprintListener() {
return blueprintListener;
public void setBlueprintListener(BlueprintListener blueprintListener) {
this.blueprintListener = blueprintListener;
+ "] [" + getBlueprintStateString(b... | 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 |
* <p></p> | 0 |
*
* @version $Id$ | 0 |
public synchronized final List<String> getSchemeNames() { | 0 |
thrown.expect(IllegalArgumentException.class);
.expand(null);
thrown.expect(IllegalArgumentException.class);
.expand(null);
thrown.expect(IllegalArgumentException.class);
XmlIO.<Bird>write().withRecordClass(Bird.class).withRootElement(testRootElement).expand(null); | 0 |
private static final long serialVersionUID = 666941918490152456L;
* @param leftPos The position of the character in the code, counting from left to right
throw new CheckDigitException("Invalid Character[" +
* @param leftPos The position of the character in the code, counting from left to righ... | 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.server.security.SystemCredentials;
AuditedSecurityOperation.getInstance(iid, true).initializeSecurity(SystemCredentials.get().getAsThrift(), DEFAULT_ROOT_USER, opts.rootpass); | 1 |
import com.google.common.collect.Iterables;
public static <T> PCollection<T> getSingletonMainOutput(
AppliedPTransform<?, PCollection<T>, ? extends PTransform<?, PCollection<T>>> transform) {
return ((PCollection<T>) Iterables.getOnlyElement(transform.getOutputs().values()));
} | 0 |
@Override
@Override
@Override
@Override
@Override
@Override
@Override
@Override | 0 |
public static final String DEFAULT_ALGORITHM = KeyUtils.DSS_ALGORITHM; | 0 |
public void testDefaultFlexRSGoal() {
DataflowPipelineOptions options = PipelineOptionsFactory.as(DataflowPipelineOptions.class);
assertEquals(
DataflowPipelineOptions.FlexResourceSchedulingGoal.UNSPECIFIED, options.getFlexRSGoal());
options.setFlexRSGoal(DataflowPipelineOptions.FlexResourceSchedu... | 0 |
import org.apache.cocoon.objectmodel.ObjectModel;
//FIXME: I'm not sure if ObjectModel shouldn't be part of CocoonContinuationContext
ObjectModel newObjectModel = (ObjectModel)getComponent(ObjectModel.ROLE);
FlowHelper.setContextObject(this.getObjectModel(), bizData, newObjectModel)... | 0 |
this.getDoubleMetaphone().isDoubleMetaphoneEqual("\u00e7", "S"); // c-cedilla
this.getDoubleMetaphone().isDoubleMetaphoneEqual("\u00f1", "N"); // n-tilde | 0 |
* <p>When joining two streams, the join has to specify {@link Windowing} which groups elements from
* streams into {@link Window}s. The join operation is performed within same windows produced on
* left and right side of input {@link Dataset}s.
*
* <li>{@code by .......................} {@link UnaryFunction}s tr... | 0 |
fs.delete(new Path(base + "/testrf"));
fs.mkdirs(new Path(base + "/testBulkFail")); | 0 |
package org.apache.beam.sdk.transforms;
import org.apache.beam.sdk.coders.CannotProvideCoderException;
import org.apache.beam.sdk.coders.Coder;
import org.apache.beam.sdk.coders.CoderException;
import org.apache.beam.sdk.coders.CoderRegistry;
import org.apache.beam.sdk.coders.StandardCoder;
import org.apache.beam.sdk.t... | 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 ma... | 0 |
ListDelimiterHandler handler = cc.getListDelimiterHandler();
assertTrue("Wrong delimiter handler: " + handler,
handler instanceof DefaultListDelimiterHandler);
assertEquals("Wrong list delimiter character", ',',
((DefaultListDelimiterHandler) handler).getDelimiter... | 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 |
public static FSDataInputStream readHeader(FileSystem fs, Path path, Map<String,String> opts) throws IOException {
replication = fs.getDefaultReplication();
org.apache.accumulo.core.security.crypto.CryptoModule cryptoModule = CryptoModuleFactory.getCryptoModule(conf.getConfiguration().get(
Pro... | 0 |
return filePath.replace("\\", "/").split(":", -1)[1]; | 0 |
log.debug("authenticate({}) {} / {} - success = {}", session, username, password, result); | 0 |
import java.util.Base64;
import org.apache.hadoop.io.NullWritable;
* Because of the hadoop output format contract, we need to be able to
public class DataSinkOutputFormat<V> extends OutputFormat<NullWritable, V> {
/**
* Sets given {@link DataSink} into Hadoop configuration. Note that original
* configuration... | 0 |
package org.apache.jcp.xml.dsig.internal.dom; | 0 |
byte[] password = "secret".getBytes();
if (commandLine.hasOption("u")) {
table = commandLine.getOptionValue("u");
}
if (commandLine.hasOption("p")) {
password = commandLine.getOptionValue("p").getBytes();
}
end = new Text(commandLine.getOptionValue("e")); | 0 |
if (name.equals(properties[j])) {
}
if (count[j] < 0) {
} else if (count[j] > 1) {
} | 0 |
import org.apache.beam.sdk.coders.CustomCoder;
extends CustomCoder<TransformedMap<K, V1, V2>> { | 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 |
ClassLoader parent = (m_classLoader == null)
? determineParentClassLoader() : m_classLoader.getParent(); | 0 |
LOG.debug("Metrics request url = {}", uriBuilder);
LOG.debug("Requesting metrics with higher precision : {}", higherPrecision);
LOG.trace("metric: {}, size = {}, host = {}, app = {}, instance = {}, time = {}, startTime = {}",
metric.getMetricName(), metric.getMetricValues().size(), m... | 1 |
*
*
* @deprecated since 1.4
* @use org.apache.accumulo.core.file.rfile.RFile
/**
* @deprecated since 1.4
* @use org.apache.accumulo.core.Constants.MAPFILE_EXTENSION
*/ | 0 |
/*****************************************************************************
* Copyright (C) The Apache Software Foundation. All rights reserved. *
* ------------------------------------------------------------------------- *
* This software is published under the terms of the Apache Software License *
* v... | 0 |
if (type != null && type.isArray()) {
this.contentType = type.getComponentType();
} | 0 |
protected static final String RESOURCES =
public static int getInteger(String key) | 1 |
import java.io.StringReader;
import org.xml.sax.InputSource;
* @version CVS $Revision: 1.4 $ $Date: 2004/05/01 18:06:12 $
public static Document getDocument(String string) {
try {
final InputSource is = new InputSource(new StringReader(string));
return builder.parse(is);
} c... | 0 |
/** Result of query 10. */
public static final Coder<Done> CODER =
new CustomCoder<Done>() {
@Override
public void encode(Done value, OutputStream outStream) throws CoderException, IOException {
STRING_CODER.encode(value.message, outStream);
}
@Override
public D... | 1 |
// Don't do list interpolation
this.setListDelimiter('\0'); | 0 |
* Implementation FTPFileEntryParser and FTPFileListParser for standard Unix Systems
*
* @version $Id: UnixFTPEntryParser.java,v 1.4 2003/12/30 03:58:52 scohen Exp $
* @see org.apache.commons.net.ftp.FTPFileEntryParser FTPFileEntryParser (for usage instructions) | 0 |
package org.apache.beam.sdk.nexmark.queries;
import org.apache.beam.sdk.nexmark.NexmarkConfiguration;
import org.apache.beam.sdk.nexmark.NexmarkUtils;
import org.apache.beam.sdk.nexmark.model.AuctionCount;
import org.apache.beam.sdk.nexmark.model.Bid;
import org.apache.beam.sdk.nexmark.model.Event;
import org.apache.be... | 0 |
return (T) reader; | 0 |
public static <T> Bag<T> predicatedBag(Bag<T> bag, Predicate<? super T> predicate) { | 0 |
public TagScript createTagScript(String name, Attributes attributes) throws JellyException { | 0 |
package org.apache.hc.core5.http.bootstrap.nio;
import org.apache.hc.core5.http.impl.nio.DefaultNHttpServerConnection;
import org.apache.hc.core5.http.impl.nio.DefaultNHttpServerConnectionFactory;
import org.apache.hc.core5.http.impl.nio.HttpAsyncService;
import org.apache.hc.core5.http.impl.nio.SSLNHttpServerConnectio... | 1 |
// get the id prior to creating ambari resources which increments the counter
Long provisionId = ambariContext.getNextRequestId();
LogicalRequest logicalRequest = processRequest(persistedRequest, topology, provisionId);
return getRequestStatus(processRequest(persistedRequest, topology,
ambariCo... | 0 |
import org.apache.aurora.common.quantity.Amount;
import org.apache.aurora.common.quantity.Time;
import org.apache.aurora.common.util.Clock; | 0 |
package com.twitter.aurora.scheduler.thrift.auth;
import com.twitter.aurora.scheduler.thrift.SchedulerThriftRouter;
import com.twitter.aurora.scheduler.thrift.auth.CapabilityValidator.CapabilityValidatorImpl; | 0 |
import org.apache.sshd.server.channel.ChannelSession;
* {@code start(ChannelSession, Environment)}-ing execution.
* If {@code null} an ad-hoc single-threaded service is created and used.
public void start(ChannelSession channel, Environment env) throws IOExcep... | 0 |
private final Class cls;
private final String methodName;
private final Class[] paramTypes;
private final boolean exact;
private final int hashCode; | 0 |
@Override
@Override
@Override | 0 |
/*
* $Header: /cvshome/build/org.osgi.framework/src/org/osgi/framework/FrameworkUtil.java,v 1.1 2005/07/14 20:32:46 hargrave Exp $
*
* Copyright (c) OSGi Alliance (2005). All Rights Reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v1.0 ... | 1 |
import org.apache.sshd.common.subsystem.sftp.extensions.openssh.HardLinkExtensionParser;
new OpenSSHExtension(FsyncExtensionParser.NAME, "1"),
new OpenSSHExtension(HardLinkExtensionParser.NAME, "1")
case HardLinkExtensionParser.NAME:
do... | 0 |
WidgetDefinitionBuilderContext context = new WidgetDefinitionBuilderContext(formDefinition.getLocalLibrary());
// set local URI
formDefinition.getLocalLibrary().setSourceURI(LocationAttributes.getURI(formElement));
Iterator i = buildEventListeners(formElement, "on-processing-phase", Proc... | 0 |
import org.apache.sshd.common.PropertyResolverUtils;
import org.apache.sshd.common.util.GenericUtils;
/** Whether to invoke {@link FileChannel#force(boolean)} on files open for write when closing */
String PROP_AUTO_SYNC_FILE_ON_CLOSE = "sftp-auto-fsync-on-close";
/** Default value for {@value #PROP_AUTO_S... | 0 |
package org.apache.accumulo.cloudtrace.instrument; | 0 |
import java.util.Arrays;
"A string that represents a filesystem path, which can be either relative or absolute to some directory. The filesystem depends on the property. The following environment variables will be substituted: " + Arrays.asList(Constants.PATH_PROPERTY_ENV_VARS)), | 0 |
private static final long serialVersionUID = 8322269736316122743L; | 0 |
* cocoon + continuation The Continuation (if available) | 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 org.apache.ambari.server.configuration.Configuration;
import org.apache.ambari.server.serveraction.ServerAction;
* The Ambari configuration.
*/
@Inject
private Configuration configuration;
/**
String auditName = getExecutionCommand().getRoleParams().get(ServerAction.ACTION_USER_NAME);
if (a... | 0 |
if (configs.getJavaVersion() >= 8) {
System.setProperty("jdk.tls.ephemeralDHKeySize", String.valueOf(configs.getTlsEphemeralDhKeySize()));
} | 0 |
return Tables.getTableState(tabletServer, extent.getTableId()) == TableState.DELETING; | 0 |
@Override | 0 |
configAdminTracker = new ServiceTracker<>( | 0 |
Map<String, Section> mergedSections = new HashMap<>();
return new ArrayList<>(mergedSections.values()); | 1 |
public static final Transformer<DHFactory, NamedFactory<KeyExchange>> DH2KEX =
new Transformer<DHFactory, NamedFactory<KeyExchange>>() {
@Override
public NamedFactory<KeyExchange> transform(DHFactory factory) {
if (factory == null) {
return null;
... | 1 |
import org.apache.beam.sdk.io.gcp.bigquery.BigQueryIO; | 0 |
document = XMLUtils.read(is, false);
document = XMLUtils.read(is, false);
document = XMLUtils.read(is, false);
document = XMLUtils.read(is, false);
document = XMLUtils.read(is, false);
document = XMLUtils.read(is, false);
document = XML... | 0 |
import org.apache.beam.runners.core.metrics.ExecutionStateTracker; | 0 |
* Copyright (c) 2003-2004 The Apache Software Foundation. All rights | 0 |
TaskTag tag = (TaskTag) findAncestorWithClass( Task.class ); | 0 |
DirectPipelineResult result = (DirectPipelineResult) p.run();
DirectPipelineResult result = (DirectPipelineResult) p.run();
DirectPipelineResult otherResult = (DirectPipelineResult) p.run(); | 0 |
import java.util.Collection;
import java.util.Objects;
/**
* Encodes the {@link Objects#toString(Object)} value of each member
* @param objects The objects to be encoded in the buffer
* @see #putStringList(Collection, Charset)
*/
public void putStringList(Collection<?> objects) {
put... | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//beanutils/src/java/org/apache/commons/beanutils/converters/FloatConverter.java,v 1.3 2002/07/13 02:22:08 craigmcc Exp $
* $Revision: 1.3 $
* $Date: 2002/07/13 02:22:08 $
* @version $Revision: 1.3 $ $Date: 2002/07/13 02:22:08 $
... | 0 |
private final Factory<? extends E> factory; | 1 |
public class SVGGraphicContextConverter {
public String toSVG(TransformStackElement transformStack[]) {
public SVGGraphicContext toSVG(GraphicContext gc) {
// no need for synchronized map => use HashMap
Map groupAttrMap = new HashMap();
for (int i=0; i<converters.length; i++) {
... | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jxpath/src/java/org/apache/commons/jxpath/IdentityManager.java,v 1.2 2003/03/11 00:59:12 dmitri Exp $
* $Revision: 1.2 $
* $Date: 2003/03/11 00:59:12 $
* Copyright (c) 1999-2003 The Apache Software Foundation. All rights
* @ver... | 0 |
import org.apache.ambari.server.state.Cluster;
* The {@link HostsRemovedEvent} class is fired when the hosts are removed from the
public class HostsRemovedEvent extends AmbariEvent {
* The clusters that the removed hosts belonged to.
* Removed hosts.
*/
private final Set<String> m_hosts;
/**
* @param... | 1 |
return ClientConfiguration.fromFile(getCluster().getConfig().getClientConfFile()); | 0 |
public interface Params {
Amount<Long, Time> slaStatRefreshInterval();
Set<MetricCategory> slaProdMetrics();
Set<MetricCategory> slaNonProdMetrics();
}
private final Params params;
SlaModule(Params params) {
this.params = requireNonNull(params);
this(new Params() {
@Override
p... | 0 |
package org.apache.http.client.impl; | 0 |
import org.apache.accumulo.core.client.ClientInfo;
public ClientInfo info() { | 0 |
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.hadoop.metrics2.sink.timeline.Precision;
import org.apache.hadoop.metrics2.sink.timeline.TimelineMetric;
import org.apache.hadoop.metrics2.sink.timeline.TimelineMetrics;
import org.apache.hadoop.util.ExitUtil;
| 0 |
return env.explain(sqlString); | 0 |
addingService( refs[i] );
addingService( event.getServiceReference() );
removedService( event.getServiceReference() );
addingService( event.getServiceReference() );
removedService( event.getServiceReference() );
return size() > 0 || m_d... | 0 |
import org.apache.beam.sdk.values.TypeDescriptor;
import org.apache.beam.sdk.values.TypeParameter; | 0 |
AmbariUserDetails userDetails = new AmbariUserDetails(users.getUser(userEntity), password, users.getUserAuthorities(userEntity));
return new AmbariUserAuthentication(password, userDetails, true); | 0 |
* @deprecated This block is deprecated and will be removed in future versions. | 0 |
private static ParDoFnFactory parDoFnFactory = new DefaultParDoFnFactory();
| 0 |
assertNull("No FooService", Utils.getServiceReference(context, FooService.class.getName(), null));
assertTrue("Assert delay (" + (end - begin) + ")", (end - begin) >= 200);
| 0 |
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;
public class AbstractSignatureVerificationTest {
assertNotNull(elementToSign);
assertNotNull(sigElement);
} | 0 |
import static com.google.common.base.Charsets.UTF_8;
String cvs = new String(currentValue, UTF_8);
encodedIterators.append(new String(hex.encode(iterators), UTF_8));
return (Long.toString(flushID) + encodedIterators).getBytes(UTF_8);
return new CompactionDriver(Long.parseLong(new ... | 0 |
return createDocumentBuilder(validating, true);
}
public static DocumentBuilder createDocumentBuilder(
boolean validating, boolean disAllowDocTypeDeclarations
) throws ParserConfigurationException {
if (disAllowDocTypeDeclarations) {
dfactory.setFeature("http://apach... | 0 |
import org.apache.hadoop.metadata.MetadataException;
import org.apache.hadoop.metadata.storage.Id;
final ClassType classType;
classType = hierarchicalType;
boolean validate(MemRepository repo, Id id) throws RepositoryException {
if (id.isUnassigned() ) {
throw new RepositoryExceptio... | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.