Diff stringlengths 5 2k | FaultInducingLabel int64 0 1 |
|---|---|
new ClientRequestHelper<>()); | 0 |
assertTrue(auth.authenticate("sshd", "sshd"));
assertFalse(auth.authenticate("sshd", "dummy")); | 0 |
int p = attrQName.indexOf(':');
String prefix = p>=0 ?
attrQName.substring(0,p):
"";
script.addAttribute(list.getLocalName(i),
prefix, list.getURI(i), expression); | 0 |
*
public int bitIndex(final Byte key, final int offsetInBits, final int lengthInBits,
throw new IllegalArgumentException("offsetInBits=" + offsetInBits
public boolean isPrefix(final Byte prefix, final int offsetInBits,
| 0 |
* Property immutable aspect.
*/
private String m_immutable;
/**
if (name.equals("immutable")) {
m_immutable = value.toString();
return;
}
if (m_immutable != null) {
prop.addAttribute(new Attribute("immutable", m_immutable));
}
| 0 |
import org.apache.commons.vfs.Capability;
protected void addCapabilities(final Collection<Capability> caps) | 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 |
return "select user_id, pig_script,title,date_created,saved,arguments from pig_pigscript where saved=1 AND user_id =?";
return "select user_id, pig_script,title,date_created,saved,arguments from pig_pigscript where saved=1 AND user_id =? AND date_created <= to_date(?, 'YYYY-MM-DD')";
return "select user_id... | 0 |
* An additional {@code BeanInfo} class for {@link FileBasedBuilderParametersImpl}.
public class FileBasedBuilderParametersImplBeanInfo extends
* Creates a new instance of {@code FileBasedBuilderParametersImplBeanInfo}.
public FileBasedBuilderParametersImplBeanInfo()
super(FileBasedBuilderParametersImp... | 0 |
import java.io.IOException;
import org.xml.sax.SAXException;
String blockPath = this.location + "COB-INF/block.xml";
} catch (ServiceException e) {
String msg = "Exception while reading " + blockPath + ": " + e.getMessage();
throw new ConfigurationException(msg, e);
} cat... | 0 |
import static org.apache.beam.vendor.guava.v20_0.com.google.common.base.MoreObjects.firstNonNull;
import static org.apache.beam.vendor.guava.v20_0.com.google.common.base.Preconditions.checkNotNull;
import org.apache.beam.vendor.guava.v20_0.com.google.common.base.MoreObjects;
import org.apache.beam.vendor.guava.v20_0.co... | 0 |
import java.util.UUID;
import org.apache.beam.vendor.grpc.v1p13p1.com.google.protobuf.Struct;
final ServerConfiguration configuration = new ServerConfiguration();
final CmdLineParser parser = new CmdLineParser(configuration);
private static InMemoryJobService createJobService(int controlPort) throws IOExcepti... | 0 |
try (InputStreamReader in = new InputStreamReader(conn.getInputStream()))
List<String> lines = new ArrayList<>(); | 0 |
/*
* Copyright (c) OSGi Alliance (2012, 2014). 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 re... | 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 |
case WMFConstants.META_STRETCHDIB: {
int height = mr.elementAt( 1 );
int width = mr.elementAt( 2 );
int sy = mr.elementAt( 3 );
int sx = mr.elementAt( 4 );
float dy = conv * curre... | 0 |
* @author <a href="mailto:berni_huber@a1.net">Bernhard Huber</a>
* @version CVS $Id: SimpleLuceneCocoonIndexerImpl.java,v 1.2 2003/03/11 17:44:21 vgritsenko Exp $ | 0 |
@Override
public void clearCache(String user) {
impl.clearCache(user);
}
@Override
public void clearCache(String user, String tableId) {
impl.clearCache(user, tableId);
} | 0 |
/** Tests for {@link WindowSupplier}. */
public void encode(BoundedWindow value, OutputStream outStream)
public BoundedWindow decode(InputStream inStream) throws CoderException, IOException { | 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 ... | 0 |
options.values().removeIf(v -> v == null || v.isEmpty());
options.values().removeIf(v -> v == null || v.isEmpty());
| 0 |
new SoftReference(inner)); | 0 |
private final Iterator iterator; | 0 |
!((ProtectionDomain) modules[modIdx].getContentLoader().getSecurityContext()).implies(
!((ProtectionDomain) module.getContentLoader().getSecurityContext()).implies( | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jxpath/src/java/org/apache/commons/jxpath/ri/axes/ChildContext.java,v 1.2 2001/09/03 01:22:30 dmitri Exp $
* $Revision: 1.2 $
* $Date: 2001/09/03 01:22:30 $
* @version $Revision: 1.2 $ $Date: 2001/09/03 01:22:30 $
private boo... | 0 |
// @since 6.0
private List<AnnotationEntryGen> annotation_vec= new ArrayList<>();
/**
* @since 6.0
*/
protected FieldGenOrMethodGen(int access_flags) { // TODO could this be package protected?
/**
* @since 6.0
*/
protected void addAnnotationEntry(AnnotationEntryGen ag) ... | 0 |
import org.apache.beam.sdk.transforms.DoFn;
@Override
public DoFn<InputT, OutputT> getFn() {
return delegate.getFn();
} | 0 |
final MultipartEntity entity = MultipartEntityBuilder.create().build();
final MultipartEntity entity = MultipartEntityBuilder.create()
final MultipartEntity entity = MultipartEntityBuilder.create()
final List<FormBodyPart> bodyParts = entity.getMultipart().getBodyParts(); | 0 |
import org.apache.sshd.common.keyprovider.KeyPairProvider; | 0 |
* <p>The {@code AIMDBackoffManager} applies an additive increase,
* Creates an {@code AIMDBackoffManager} to manage
* this factor. {@code Math.floor} is applied in the
* @param cap must be >= 1 | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/observed/standard/Attic/StandardPreModificationListener.java,v 1.3 2003/11/27 22:55:16 scolebourne Exp $
* @deprecated TO BE REMOVED BEFORE v3.0
* @version $Revision: 1.3 $ $Date... | 0 |
/**
* The target ratio between requests sent and successful requests. This is "K" in the formula in
* https://landing.google.com/sre/book/chapters/handling-overload.html
*/
/**
* The target minimum number of requests per samplePeriodMs, even if no requests succeed. Must be
* from the formula in https... | 1 |
* Copyright (C) 2015 Google Inc. | 0 |
import org.apache.beam.sdk.values.Schema;
private Schema schema;
private RowCoder(Schema schema, List<Coder> coders) {
this.schema = schema;
public static RowCoder of(Schema schema, List<Coder> coderArray) {
if (schema.getFieldCount() != coderArray.size()) {
return new RowCoder(schema, coderArray);
... | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jelly/src/java/org/apache/commons/jelly/parser/XMLParser.java,v 1.5 2002/02/13 17:03:09 jstrachan Exp $
* $Revision: 1.5 $
* $Date: 2002/02/13 17:03:09 $
* $Id: XMLParser.java,v 1.5 2002/02/13 17:03:09 jstrachan Exp $
* @version... | 0 |
import org.apache.beam.sdk.runners.PTransformOverride;
pipeline.replace(PTransformOverride.of(override.getKey(), override.getValue())); | 0 |
* @param <InputT> the type of the element processed
* @param <OutputT> the type of the result applying element to the function
public interface UnaryFunctionEnv<InputT, OutputT> extends Serializable {
OutputT apply(InputT what, Context context); | 0 |
@Test
public void testSqoopExport() throws Exception {
SqoopJobDataPublisher.Data d = new SqoopJobDataPublisher.Data("export", "jdbc:mysql:///localhost/db",
"mysqluser", "mysql", "myTable", null, "default", "hiveTable", new Properties(),
System.currentTimeMillis() - 100, ... | 0 |
final ExecChain.Scope scope = new ExecChain.Scope("test", route, request, endpoint, context);
final ExecChain.Scope scope = new ExecChain.Scope("test", route, request, endpoint, context);
final ExecChain.Scope scope = new ExecChain.Scope("test", route, request, endpoint, context);
final ... | 0 |
import com.google.common.annotations.VisibleForTesting;
@VisibleForTesting
static final Resources TOTAL_GC_EXECUTOR_RESOURCES =
new Resources(0.2, Amount.of(128L, Data.MB), Amount.of(16L, Data.MB), 0);
// An epsilon is used because we are required to supply executor and task resources.
@VisibleForTesting... | 0 |
addWork(WorkCommand.KILL);
// fall through
// fall through
case KILLING:
addWork(WorkCommand.KILL);
case LOST:
addWork(WorkCommand.KILL);
// fall through | 0 |
} else {
shellState.checkTableState();
tablesToFlush.add(shellState.getTableName()); | 0 |
import org.apache.hadoop.metadata.listener.TypedInstanceChangeListener;
import org.apache.hadoop.metadata.repository.MetadataRepository;
private final Set<TypedInstanceChangeListener> typedInstanceChangeListeners
= new LinkedHashSet<>();
final String guid = repository.createEntity(entityInst... | 1 |
* {@link PCollection PCollection<Mutation>}, where each {@link Mutation} represents an
* idempotent transformation on a row.
* PCollection<Mutation> data = ...;
public static class Write extends PTransform<PCollection<Mutation>, PDone> {
public PDone expand(PCollection<Mutation> input) {
pr... | 0 |
final Timeout connectionRequestTimeout,
route,
null,
connectionRequestTimeout,
final Timeout connectionRequestTimeout = requestConfig.getConnectionRequestTimeout();
final Timeout connectTimeout = requestConfig.getConnectionTimeout();
le... | 0 |
* @version CVS $Id: ExtendedParserTransformer.java,v 1.2 2004/01/22 13:24:53 joerg Exp $
Unmarshaller.getContentHandler(unmarshalHandler)); | 0 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/test/org/apache/commons/collections/decorators/Attic/TestTransformedSortedBag.java,v 1.2 2003/08/31 17:28:42 scolebourne Exp $
* any, must include the following acknowledgement:
* Alternately, this acknowledg... | 0 |
logRequest.setHostList("logsearch1.com,logsearch2.com");
assertEquals("?q=*%3A*&start=0&rows=25&fq=type%3A%28logsearch_app+OR+secure_log%29&fq=-type%3A%28hst_agent+OR+system_message%29" +
"&fq=log_message%3Amyincludemessage&fq=-log_message%3Amyexcludemessage&fq=cluster%3Acl1&fq=path%3A%5C%2Fvar%5C%2Flog... | 0 |
new Object[] { hostToConnect, Integer.valueOf(portToConnect), originatorIpAddress, Integer.valueOf(originatorPort) });
@SuppressWarnings("synthetic-access")
if (log.isDebugEnabled()) {
log.debug("Ignoring write to channel {} in CLOSING state", Inte... | 0 |
this.beanFactory = BeanFactoryUtil.createBeanFactory(avalonEnv, rolesInfo, null, this.rootBeanFactory); | 0 |
public ExportTable(String namespaceId, String tableName, String tableId, String exportDir)
throws ThriftTableOperationException { | 0 |
*
* <p>We need this step, because we can get iterators from Kinesis only with "sequenceNumber"
* accuracy, not with "subSequenceNumber" accuracy. | 0 |
// Unset auth scope
targetAuthState.setAuthScope(null);
proxyAuthState.setAuthScope(null);
// Invalidate auth states if redirecting to another host | 0 |
File siteFile = Files.createTempFile(config.getConfDir().toPath(), "accumulo", ".properties")
writeConfigProperties(siteFile, confMap);
File siteFile = new File(config.getConfDir(), "accumulo.properties");
writeConfigProperties(siteFile, config.getSiteConfig());
AccumuloConfiguration acuConf =... | 0 |
try {
HttpPost httppost = new HttpPost("http://localhost:8080" +
"/servlets-examples/servlet/RequestInfoExample");
FileBody bin = new FileBody(new File(args[0]));
StringBody comment = new StringBody("A binary file of some kind");
MultipartEntit... | 0 |
Copyright 2000 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 |
Shell.log.info(" You cannot take the {} offline.", MetadataTable.NAME);
Shell.log.info("Offline of table {} {}", tableName, wait ? " completed." : " initiated..."); | 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 ap... | 0 |
Map<String, Map<String, String>> kerberosConfigurations = new HashMap<>();
Map<String, Set<String>> services = new HashMap<>();
components = new HashSet<>(); | 1 |
* @param maxSize the maximum size of the map
* most recently used position (last).
return get(key, true);
}
/**
* Gets the value mapped to the key specified.
* <p>
* If {@code updateToMRU} is {@code true}, the position of the key in the map
* is changed to the most recent... | 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
... | 0 |
import org.apache.accumulo.core.data.TableId;
TableId getTableId(); | 0 |
LOG.log(Level.INFO, "Karaf shutdown socket: received shutdown command. Stopping framework..."); | 0 |
* @version $Id$ | 0 |
* dir="a/b/c/d", contentHash="f000" => d-f000.jar
return fileName + "-" + contentHash + ".jar"; | 0 |
private byte[] content;
byte[] getContent()
return content;
void setContent(final byte[] buffer)
this.content = buffer;
this.content = new byte[0];
return content.length;
System.arraycopy(this.content, 0, newBuf, 0, Math.min(resize, size));
this.content = newB... | 0 |
import org.apache.xml.security.utils.XMLUtils;
javax.xml.parsers.DocumentBuilder db = XMLUtils.createDocumentBuilder(false); | 0 |
import org.apache.http.annotation.NotThreadSafe;
@NotThreadSafe | 0 |
public interface SM { | 0 |
private static final Logger LOG = LoggerFactory.getLogger(HostResourceProvider.class);
| 0 |
import static org.junit.Assert.fail; | 0 |
checkNotNull(earlyFirings, "Must specify the trigger to use for early firings");
checkNotNull(lateFirings, "Must specify the trigger to use for late firings");
return new AfterWatermarkEarlyAndLate(Never.ever(), lateFirings); | 0 |
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.InvalidObjectException;
import org.apache.accumulo.core.data.thrift.TRange;
public void testReadFields() throws Exception {
Range r = nr("nuts", "soup");
... | 0 |
import org.apache.http.cookie.ClientCookie;
registerAttribHandler(ClientCookie.VERSION_ATTR, new RFC2109VersionHandler());
registerAttribHandler(ClientCookie.PATH_ATTR, new BasicPathHandler());
registerAttribHandler(ClientCookie.DOMAIN_ATTR, new RFC2109DomainHandler());
registerAttribHan... | 0 |
private final Stack<Object> stack = new Stack<Object>(); | 0 |
* Copyright 2016 Seznam.cz, a.s. | 0 |
import static junit.framework.Assert.assertTrue;
import static org.junit.Assert.assertArrayEquals;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import org.junit.Test;
public class EnvironmentUtilTest {
@Test
@Test
@Tes... | 0 |
* Defines the {@link org.apache.beam.sdk.transforms.windowing.Window} transform for dividing the
* elements in a PCollection into windows, and the {@link
* org.apache.beam.sdk.transforms.windowing.Trigger} for controlling when those elements are output.
* <p>{@code Window} logically divides up or groups the element... | 1 |
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/decorators/Attic/PredicatedBuffer.java,v 1.3 2003/08/31 17:24:46 scolebourne Exp $
* any, must include the following acknowledgement:
* Alternately, this acknowledgement ma... | 0 |
*
* <p>If no instance has previously been created, one is created and the value
* <p>Returns a SeekableByteChannel that provides access to data in the bucket.
* <p>Returns a WritableByteChannel that can be used to write data to the | 0 |
this.data.setContent(RamFileData.EMPTY); | 0 |
import cz.seznam.euphoria.core.client.operator.state.StateContext;
private StateContext stateContext;
this.stateContext = new BatchStateContext(settings, env, maxMemoryElements);
.reduceGroup(new RSBKReducer(origOperator, stateContext, windowing,
private final StateContext stateContext;
St... | 0 |
valid1 = new ServiceRequest("foo", "PIG", null, null); | 0 |
* Listeners for {@link RepeaterEvent}s | 0 |
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.ImmutableList;
import org.apache.beam.vendor.guava.v20_0.com.google.common.collect.ImmutableMap; | 0 |
/*****************************************************************************
* Copyright (C) The Apache Software Foundation. All rights reserved. *
* ------------------------------------------------------------------------- *
* This software is published under the terms of the Apache Software License *
*... | 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 |
* 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 |
* http://www.apache.org/licenses/LICENSE-2.0 | 0 |
*
public class NamedBean
{
public NamedBean()
{
}
public NamedBean( String name )
{
}
public String getName()
{
public void setName( String name )
{
public void test( String name, String ignored )
{
setName( name );
public String toString()
{ | 1 |
public class AmbariCustomCommandExecutionHelperTest {
@Captor ArgumentCaptor<List<Stage>> stagesCaptor;
Mockito.verify(am, Mockito.times(1)).sendActions(stagesCaptor.capture(), any(ExecuteActionRequest.class));
List<Stage> stages = stagesCaptor.getValue();
Assert.assertEquals(1, stages... | 0 |
EventBusSynchronizer.synchronizeAmbariEventPublisher(binder()); | 0 |
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 use this file except in compliance with
the License. You may obta... | 0 |
import org.apache.hc.core5.annotation.GuardedBy;
import org.apache.hc.core5.annotation.ThreadSafe;
import org.apache.hc.core5.util.Args; | 1 |
final String desiredRepoVersion;
put("repository_version", desiredRepoVersion);
actionContext.setTimeout((short) 600);
ClusterVersionEntity existingCSVer = clusterVersionDAO.findByClusterAndStackAndVersion(clName, stackId, desiredRepoVersion);
if (existingCSVer == null) {
try { //... | 0 |
if (unitsType == OBJECT_BOUNDING_BOX && bridge != null) { | 0 |
String tidStr = String.format("%016x", tid);
log.warn("Failed to execute Repo, tid=" + tidStr, e);
log.info("Updated status for Repo with tid=" + tidStr + " to FAILED_IN_PROGRESS"); | 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 |
private final HashSet<String> children = new HashSet<>(); | 0 |
Map<String, DesiredConfig> clusterDesiredConfigs,
boolean useLatestConfigs)
if (useLatestConfigs) {
execCmd.setUseLatestConfigs(useLatestConfigs);
}
boolean runSmokeTest, boolean reconfigureClients, boolean useLatestConfigs)
... | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.