Diff stringlengths 5 2k | FaultInducingLabel int64 0 1 |
|---|---|
if ( bundleLocation.equals( cfg.getBundleLocation() ) || Activator.hasCtWorkaround() ) | 0 |
+ "[" + m_provider + "]"; | 1 |
/*
* Copyright (c) OSGi Alliance (2011). All Rights Reserved.
*
* 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 |
/*
* 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 |
assertEquals("a", c.execute("(echo a) | capture"));
assertEquals("a", c.execute("((echo a)) | capture"));
assertEquals("def", c.execute("echo def|grep d.*|capture"));
assertEquals("def", c.execute("echoout def|grep d.*|capture"));
assertEquals("def", c.execute("myecho def|grep d.... | 0 |
* Verify that acl optimization of storing just
* a few acls and there references in the data
assertTrue("waiting for server being up",
/*
* (non-Javadoc)
*
*/
{
startSignal.countDown(); | 0 |
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 |
import org.apache.accumulo.core.security.Authorizations;
Scanner scanner = getConnector().createScanner(table, Authorizations.EMPTY); | 0 |
/**
* This class governs the space in Zookeeper that advertises the status of Write-Ahead Logs in use
* by tablet servers and the replication machinery.
* <p>
* The Master needs to know the state of the WALs to mark tablets during recovery. The GC needs to
* know when a log is no longer needed so it can be removed... | 0 |
import org.apache.http.impl.conn.ConnRoute;
private final ConnRoute route;
public final ConnRoute getRoute() { | 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 static synchronized DomainValidator getInstance() {
inUse = true;
public static synchronized DomainValidator getInstance(boolean allowLocal) {
inUse = true;
/*
* This field is used to detect whether the getInstance has been called.
* After this, the method updateTLDOverride ... | 0 |
private volatile boolean requestEnd; // used for inter-thread communication | 0 |
* Gets a map of components to hosts they are installed on.
* <p>
* This may may be filtered by host and/or service by optionally providing a set of hostname
* and/or service names to use as a filter. <code>null</code> for either filter indicates no
* filter (or all), an empty set indicates a complete fi... | 0 |
import java.io.FileInputStream;
public XMLSignatureInput(Node rootNode)
public XMLSignatureInput(Set inputNodeSet) {
this(XMLUtils.convertNodelistToSet(inputNodeSet));
NodeList nodeList = CachedXPathAPIHolder.getCachedXPathAPI().selectNodeList(
return getResetabl... | 0 |
import org.apache.batik.util.SVGTypes;
* Implements {@link ValueManager#isAnimatableProperty()}.
*/
public boolean isAnimatableProperty() {
return true;
}
/**
* Implements {@link ValueManager#isAdditiveProperty()}.
*/
public boolean isAdditiveProperty() {
return true... | 1 |
boolean secVal = Utils.secureValidation(xc);
apacheTransform.setSecureValidation(secVal); | 0 |
AccessController.doPrivileged(
(PrivilegedAction<Boolean>) () -> Boolean.getBoolean("org.apache.xml.security.ignoreLineBreaks")); | 0 |
import com.google.common.base.Supplier;
if (query.getEnvironment() != null) {
if (!query.getEnvironment().equals(config.getEnvironment())) {
return false;
}
} | 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.hc.core5.annotation.ThreadSafe; | 1 |
listener.blocked(session, handle, fileHandle, offset, length, mask, null);
doUnblock(id, handle, offset, length);
sendStatus(BufferUtils.clear(buffer), id, SftpConstants.SSH_FX_OK, "");
protected void doUnblock(int id, String handle, long offset, long length) throws IOException {
... | 0 |
import org.apache.beam.sdk.schemas.Schema.TypeName;
TypeName.INT64, "order_id",
TypeName.INT32, "site_id",
TypeName.DOUBLE, "price"
TypeName.INT64, "order_id",
TypeName.INT32, "site_id",
TypeName.DOUBLE, "price"
TypeName.INT64, "order_i... | 0 |
import org.apache.ambari.common.rest.entities.Stack;
import org.apache.ambari.common.rest.entities.StackInformation;
OptionBuilder.withDescription( "Stack revision, if not specified latest revision is used" );
public void printStack(Stack stack, String file_path) throws Exception {
JAXBContext jc =... | 0 |
quorumPeer.setSslQuorum(config.isSslQuorum());
quorumPeer.setUsePortUnification(config.shouldUsePortUnification()); | 0 |
import java.io.EOFException;
public CryptoModuleParameters encryptSecretKey(CryptoModuleParameters context) throws IOException {
throw new IOException(e);
// TODO ACCUMULO-2530 Ensure volumes are properly supported
boolean invalidFile = false;
int keyEncryptionKeyLength = 0;
keyEncryp... | 0 |
import com.twitter.mesos.scheduler.base.SchedulerException; | 0 |
log.debug("open({}) SSH_MSG_CHANNEL_OPEN", this);
buffer.putInt(getId()); | 0 |
package org.apache.commons.net.telnet;
| 0 |
* Construct a new XML stream writer for the specified output stream
* Construct a new XML stream writer for the specified output stream
* Construct a new XML stream writer for the specified file
* Construct a new XML stream writer for the specified file | 0 |
private final Map<SpanKey,Destination> clients = new HashMap<>();
protected final AbstractQueue<RemoteSpan> sendQueue = new ConcurrentLinkedQueue<>();
List<Annotation> result = new ArrayList<>(); | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//beanutils/src/java/org/apache/commons/beanutils/converters/StringConverter.java,v 1.4 2003/10/09 20:43:16 rdonkin Exp $
* $Revision: 1.4 $
* $Date: 2003/10/09 20:43:16 $
* Alternately, this acknowledgement may appear in the so... | 0 |
*
*
final ByteArrayOutputStream buffer = new ByteArrayOutputStream(); | 0 |
Path dir = getTempTargetRelativeFile(getClass().getSimpleName());
ConfigFileHostEntryResolver resolver = new ConfigFileHostEntryResolver(assertHierarchyTargetFolderExists(dir).resolve(getCurrentTestName() + ".config.txt")) { | 0 |
import org.apache.ambari.server.audit.AuditLogger;
import org.apache.ambari.server.audit.AuditLoggerDefaultImpl;
import org.easymock.EasyMock;
bind(AuditLogger.class).toInstance(EasyMock.createNiceMock(AuditLoggerDefaultImpl.class)); | 1 |
import cz.seznam.euphoria.core.client.dataset.BatchWindowing;
public class CountByKey<IN, KEY, W extends Window<?>>
IN, IN, IN, KEY, Pair<KEY, Long>, W, CountByKey<IN, KEY, W>> {
public <W extends Window<?>> CountByKey<IN, KEY, W>
public Dataset<Pair<KEY, Long>> output() {
return windowBy(BatchWin... | 0 |
import static org.hamcrest.Matchers.containsString;
import static org.junit.internal.matchers.ThrowableMessageMatcher.hasMessage;
import org.apache.beam.sdk.extensions.sql.impl.ParseException;
exceptions.expect(ParseException.class);
exceptions.expectCause(hasMessage(containsString("Column 'f_int_na' not found ... | 0 |
import com.twitter.mesos.Tasks;
Preconditions.checkArgument(hasJob(user, name), "No such cron job " + Tasks.jobKey(user, name));
cronTriggered(scheduledJobs.get(Tasks.jobKey(user, name)).getSecond());
LOG.info(String.format("Cron triggered for %s at %s", Tasks.jobKey(job), new Date()));
LOG.info(String.... | 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 $Revision: 1.2 $ | 0 |
public static void main(final String[] args) throws Exception {
final IOReactorConfig ioReactorConfig = IOReactorConfig.custom()
final CloseableHttpAsyncClient client = HttpAsyncClients.custom()
final HttpHost target = new HttpHost("httpbin.org");
final String[] requestUris = new Str... | 0 |
@NamedQuery(name = "AlertCurrentEntity.findByCluster", query = "SELECT alert FROM AlertCurrentEntity alert WHERE alert.alertHistory.clusterId = :clusterId"),
@NamedQuery(name = "AlertCurrentEntity.findByService", query = "SELECT alert FROM AlertCurrentEntity alert WHERE alert.alertHistory.clusterId = :clusterId... | 0 |
/**
* Copyright 2016 Seznam a.s.
*
* 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 |
* Follower MBean interface implementation
@Override
public long getElectionTimeTaken() {
return follower.self.getElectionTimeTaken();
} | 0 |
import org.apache.http.ProtocolVersion;
private final ProtocolVersion protoversion;
final ProtocolVersion version) {
if (version == null) {
("Protocol version must not be null.");
this.protoversion = version;
public ProtocolVersion getProtocolVersion()... | 0 |
/*****************************************************************************
* Copyright (C) The Apache Software Foundation. All rights reserved. *
* ------------------------------------------------------------------------- *
* This software is published under the terms of the Apache Software License *
* v... | 1 |
Font font = new Font("Lucida Sans", Font.BOLD, 15); | 0 |
@Override | 0 |
ret = in.read(b, off, n); | 0 |
* @version $Id$ | 0 |
throw new AssertionViolatedException("Field '" + field_name + "' not found in " + jc.getClassName());
throw new AssertionViolatedException("Field '" + field_name + "' not found in " + jc.getClassName()); | 0 |
OpenFuture f = new DefaultOpenFuture(this);
signalChannelOpenSuccess();
signalChannelOpenFailure(e); | 0 |
ctor = key.getMostSpecificConstructor(l); | 0 |
return formatNumber(value); | 0 |
import java.util.Properties;
Properties cp = Accumulo.newClientProperties().to("test", "zk").as("blah", "blah")
.batchWriterConfig(bwConfig).build();
AccumuloOutputFormat.configure().clientProperties(cp).store(job); | 0 |
"An unexpected error was returned by the property server during {1} request for open metadata access service {2} on server {3}; message was {0}", | 0 |
* Constructs a new <code>ParametrizedDOMTest</code>.
* Creates the <code>TranscoderInput</code>. | 0 |
* <p>See also the <a href='http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113'>Document Object Model (DOM) Level 2 Core Specification</a>. | 0 |
import org.apache.commons.collections.buffer.BoundedBuffer;
* Returns a synchronized buffer backed by the given buffer that will block on {@link Buffer#add(Object)} and
* {@link Buffer#addAll(java.util.Collection)} until enough object(s) are removed from the buffer to allow
* the object(s) to be added an... | 0 |
.apply(Distinct.create())
.apply("DedupedShakespeare", TextIO.write().to(options.getOutput())); | 0 |
"CREATE EXTERNAL TABLE message (\n"
"CREATE EXTERNAL TABLE message (\n"
"CREATE EXTERNAL TABLE message (\n" | 0 |
import org.apache.beam.sdk.testing.InterceptingUrlClassLoader;
ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader();
new InterceptingUrlClassLoader(contextClassLoader, AvroCoderTestPojo.class.getName());
new InterceptingUrlClassLoader(contextClassLoader, AvroCoderTestPojo.... | 0 |
start(server, Collections.emptyMap(), Integer.MAX_VALUE);
public synchronized void start(ServerType server, Map<String,String> configOverrides, int limit)
throws IOException { | 0 |
import org.apache.flink.streaming.runtime.streamrecord.LatencyMarker;
import org.apache.flink.streaming.runtime.tasks.TestProcessingTimeService;
public void emitLatencyMarker(LatencyMarker latencyMarker) {
}
@Override
public void emitLatencyMarker(LatencyMarker l... | 0 |
import cz.seznam.euphoria.shadow.com.google.common.collect.Iterables; | 0 |
import org.apache.accumulo.core.security.Authorizations;
final Scanner scanner = shellState.getConnector().createScanner(Constants.METADATA_TABLE_NAME, Authorizations.EMPTY); | 0 |
/**
* Creates the requests to send to the clusters
* @param amc the controller
* @param requestProperties the request properties
* @param clusterNames the names of all the clusters to update
* @return the response
* @throws AmbariException
*/
public static RequestStatusResponse createRequests(A... | 0 |
import com.google.common.annotations.VisibleForTesting;
@VisibleForTesting
public static String toJsonFromAttribute(AtlasAttribute attribute) {
@VisibleForTesting
public static AtlasAttributeDef toAttributeDefFromJson(AtlasStructDef structDef, | 0 |
package org.apache.felix.ipojo.runtime.core.test.components.inner;
import org.apache.felix.ipojo.runtime.core.test.services.Call;
public class C1 implements Call {
public String callMe() {
return "called";
}
} | 0 |
public final TypeSystem typeSystem;
HierarchicalType(TypeSystem typeSystem, String name, ImmutableList<String> superTypes, int numFields) {
HierarchicalType(TypeSystem typeSystem, String name, ImmutableList<String> superTypes, AttributeInfo... fields)
@Override
public String getName() {
retu... | 0 |
* Several standard file selectors.
* @version $Revision: 1.1 $ $Date: 2002/10/23 10:56:32 $
public interface Selectors
* A {@link FileSelector} that selects only the base file/folder.
* A {@link FileSelector} that selects the base file/folder and its
* A {@link FileSelector} that selects only the direc... | 0 |
// TODO
@Override
public ServiceComponentHost getServiceComponentHost(String hostname) {
return this.hostComponents.get(hostname);
}
| 0 |
if (in != null)
try
{
props.load(in);
}
catch (IOException ex)
{
ex.printStackTrace();
}
FelixConstants.FELIX_VERSION_PROPERTY, "0.0.0")); | 0 |
try (AccumuloClient client = Accumulo.newClient().from(getClientProperties())
.as(newPrincipal, krbToken).build()) {
// Do the explicit check to see if the user has the permission to get a delegation token
if (!client.securityOperations().hasSystemPermission(client.whoami(),
... | 0 |
* org.w3c.dom.svg.SVGGradientElement#getMaskUnits()}.
* <b>DOM</b>: Implements {@link
* org.w3c.dom.svg.SVGPatternElement#getMaskContentUnits()}.
*/
public SVGAnimatedEnumeration getMaskContentUnits() {
throw new RuntimeException(" !!! TODO: SVGOMMaskElement.getPatternUnits()");
}
... | 0 |
= "org/apache/batik/apps/rasterizer/resources/rasterizer.policy";
*
* is not an acceptable option.
* This defines the length of the optionValues array passed to
* throws an exception if the number of arguments passed to the
* method is invoked.
* Subclasses can implemen... | 0 |
import com.google.api.services.dataflow.model.JobMessage;
import com.google.api.services.dataflow.model.JobMetrics;
import com.google.api.services.dataflow.model.MetricUpdate;
import com.google.common.base.Joiner;
import com.google.common.base.Optional;
import com.google.common.base.Throwables;
import java.io.IOExcepti... | 0 |
/** The connection operator. */
protected final ClientConnectionOperator connOperator;
protected AbstractPoolEntry(ClientConnectionOperator connOperator,
super();
if (connOperator == null) {
throw new IllegalArgumentException("Connection operator may not be null");
}
... | 0 |
* @version $Id$ | 0 |
*
* @version $Id$
//
//
//
//
//
//
//
//
//
//
// | 0 |
jmxStream = streamProvider.readFrom(jmxUrl, "GET", (String)null, headers); | 0 |
// Must remove the fragment candidate because we must
// only use hosted capabilities for package namespace
candidates.remove(fragCand); | 0 |
import java.util.Collection;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
import org.junit.runners.Parameterized.Parameters;
@RunWith(value = Parameterized.class)
private final boolean propagateExceptions;
public TestFactoryCreate( boolean propagateExceptions )
{
this.pr... | 0 |
import org.apache.ambari.server.controller.utilities.PropertyHelper;
host = PropertyHelper.fixHostName(host); | 0 |
/*
import java.util.Enumeration;
*
* @param conf : the configuration from the composite instance
private void createServiceInstance(Element service, Dictionary conf) throws ConfigurationException {
// Prepare the configuration to append.
Properties toAppend = new Properties();
Enu... | 0 |
public InputLimit(final long value) { | 0 |
mavenBundle().groupId("org.osgi").artifactId("org.osgi.compendium").version("4.1.0"), | 0 |
throws XMLSignatureException;
XMLSignatureException;
* not specified)
* invocation of this method returns a new clone of the array to
* prevent subsequent modification. | 1 |
import java.net.InetAddress;
import java.net.UnknownHostException;
import com.google.common.base.Throwables;
String hostname = getLocalHost();
assertEquals(hostname, event.getScheduler());
}
}
private static String getLocalHost() {
try {
return InetAddress.getLocalHost().getHostName();
... | 0 |
shellState.getAccumuloClient().tableOperations().rename(cl.getArgs()[0], cl.getArgs()[1]); | 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 applicable law o... | 0 |
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.util.concurrent.ListeningExecutorService;
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.util.concurrent.MoreExecutors; | 0 |
* or {@link javax.xml.crypto.XMLStructure} | 0 |
super(name, help, argFile, arg, type, verifierAnnotations, parser);
if (optionName.equals(getNegatedName())) { | 0 |
* Generated data to check that the wire format has not changed. To regenerate, see {@code
* PrintBase64Encodings}.
private static final List<String> TEST_ENCODINGS =
Arrays.asList(
"AQ",
"AWE",
"ATEz",
"AWhlbGxv",
"AA",
"AWEgbG9uZ2VyIHN0cmluZyB3a... | 1 |
FlowHelper.setContextObject(objectModel, newObjectModel, bizData); | 0 |
StringBuffer sb = new StringBuffer( numTables * 8 ).append("cmap\n");
sb.append( '\t' ).append(entries[i].toString()).append( '\n' );
sb.append( '\t' ).append(formats[i].toString()).append( '\n' ); | 0 |
IoSession ioSession = sessions.remove(sessionId);
if (log.isDebugEnabled()) {
log.debug("unmapSession(id={}): {}", sessionId, ioSession);
} | 0 |
* @version $Revision$ | 0 |
Collection<Text> splits = state.getConnector().tableOperations().listSplits(indexTableName);
splits = state.getConnector().tableOperations().listSplits(indexTableName); | 0 |
public int compareTo(FileName obj) | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.