Diff
stringlengths
5
2k
FaultInducingLabel
int64
0
1
public final int create2 = 15;
0
* in DirectRunner and on SparkRunner, with the mapped beam-to-spark
0
package org.apache.accumulo.core.spi.common; import java.util.Map; /** * Provides information about a configured Accumulo Iterator * * @since 2.0.0 */ public interface IteratorConfiguration { String getIteratorClass(); String getName(); int getPriority(); Map<String,String> getOptions();
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 use this file except in compliance with * the License. You may obtain a copy of the License at
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 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 * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.hadoop.metrics2.sink.timeline.deserialize; import java.util.LinkedHashMap; /** * This Map does not store neither null values. When null value is * inserted it is ignored. */ public class IgnoringNullsLinkedHashMap<K, V> extends LinkedHashMap<K, V> { @Override public V put(K key, V value) { if (value == null) return null; return super.put(key, value); } }
0
/** * Find if the command report is for an in progress command * @param report * @return */ public boolean isInProgressCommand(CommandReport report) { HostRoleCommand command = db.getTask(report.getTaskId()); if (command == null) { LOG.warn("The task " + report.getTaskId() + " is invalid"); return false; } return command.getStatus().equals(HostRoleStatus.IN_PROGRESS) || command.getStatus().equals(HostRoleStatus.QUEUED); }
0
buffer.append("[identity; completed: "); buffer.append("]");
0
public Map<PropertyId, String> getHttpBodyProperties();
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 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 * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */ package org.apache.commons.bcel6.generic; /** * Denote entity that has both name and type. This is true for local variables, * methods and fields. * * @version $Id$ * @author <A HREF="mailto:[email protected]">M. Dahm</A> */ public interface NamedAndTyped { String getName(); Type getType(); void setName( String name ); void setType( Type type ); }
1
import org.apache.beam.runners.core.KeyedWorkItem;
0
String shortClassName = className; if (className.contains(".")) shortClassName = className.substring(className.lastIndexOf('.') + 1); prompt = Shell.repeat("-", 10) + "> set " + shortClassName + " parameter " + e.getKey() + ", " + e.getValue() + ": "; prompt = Shell.repeat("-", 10) + "> set " + shortClassName + " option (<name> <value>, hit enter to skip): ";
0
private Set<String> seenPrincipals = new HashSet<>();
1
import java.util.zip.GZIPInputStream; else if (url.getPath().endsWith(".gz")) { is = new GZIPInputStream(FileUtil.openURL(url)); }
0
protected boolean doSetLastModifiedTime(final long modtime)
0
TabletLocationState result = new TabletLocationState(RootTable.EXTENT, futureSession, currentSession, lastSession, null, logs, false); public void suspend(Collection<TabletLocationState> tablets, Map<TServerInstance,List<Path>> logsForDeadServers, long suspensionTimestamp) throws DistributedStoreException { // No support for suspending root tablet. unassign(tablets, logsForDeadServers); } @Override public void unsuspend(Collection<TabletLocationState> tablets) throws DistributedStoreException { // no support for suspending root tablet. } @Override
1
package org.apache.commons.dbcp2;
1
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//jxpath/src/java/org/apache/commons/jxpath/ri/model/beans/CollectionChildNodeIterator.java,v 1.2 2003/10/09 21:31:40 rdonkin Exp $ * $Revision: 1.2 $ * $Date: 2003/10/09 21:31:40 $ * 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 $ $Date: 2003/10/09 21:31:40 $
0
import org.apache.beam.sdk.runners.AppliedPTransform;
0
* Implementation of the JdoPMF. Create one PMF and store it for future use
0
import org.apache.aurora.scheduler.Resources;
0
* @version CVS $Id$ facade.setDelegate((ForwardEnvironmentWrapper)newEnv); // The following is a fix for bug #26854 and #26571 final boolean result = processor.process(newEnv, context); if ( ((ForwardEnvironmentWrapper)newEnv).getRedirectURL() != null ) { environment.redirect( ((ForwardEnvironmentWrapper)newEnv).getRedirectURL(), false, false); } return result;
0
import org.apache.hc.core5.concurrent.FutureCallback;
1
return bean instanceof DynaBean ? new DynaBeanPointer(name, (DynaBean) bean, locale) : null; return bean instanceof DynaBean ? new DynaBeanPointer(parent, name, (DynaBean) bean) : null;
1
import org.apache.accumulo.core.security.tokens.PasswordToken; import org.apache.accumulo.core.security.tokens.SecurityToken;
0
* primitivePaint on the associated <code>GraphicsNode</code> or * primitivePaint on the associated <code>GraphicsNode</code> or false * Returns the <code>GraphicsNode</code> rendered by this image * Sets the <code>GraphicsNode</code> this image should render * include any filters or mask operations on <code>node</code>
0
import org.apache.avalon.framework.parameters.Parameters; import org.apache.cocoon.caching.CacheableProcessingComponent; import org.apache.cocoon.environment.SourceResolver; import org.apache.cocoon.util.TraxErrorHandler; import org.xmldb.api.DatabaseManager; import org.xmldb.api.base.Collection; import javax.xml.transform.OutputKeys; import javax.xml.transform.TransformerConfigurationException; import javax.xml.transform.TransformerFactory; import javax.xml.transform.sax.SAXTransformerFactory; import javax.xml.transform.sax.TransformerHandler; import javax.xml.transform.stream.StreamResult; * &lt;map:transformer name="xmldb" src="org.apache.cocoon.transformation.XMLDBTransformer"&gt; * @version CVS $Id: XMLDBTransformer.java,v 1.3 2003/07/09 21:36:53 joerg Exp $
0
import org.apache.accumulo.minicluster.impl.MiniAccumuloConfigImpl; import org.apache.accumulo.minicluster.impl.ProcessReference; public void configure(MiniAccumuloConfigImpl cfg) {
0
Set<String> candidateHosts = new HashSet<>(); Map<String, String> commandParams = new TreeMap<>(); Map<String, Map<String, String>> configTags = new TreeMap<>(); roleParams = new TreeMap<>(); cluster.addSuspendedUpgradeParameters(commandParams, roleParams); execCmd.setCommandParams(commandParams);
0
this.attributeNamespace = XMLSecNamespaceImpl.getInstance(this.name.getPrefix(), this.name.getNamespaceURI());
0
/** Tests for {@link MultiplexingFnDataReceiver}. */ @Rule public ExpectedException thrown = ExpectedException.none();
1
import org.apache.beam.sdk.extensions.sql.impl.parser.SqlDropTable; } else if (sqlNode instanceof SqlDropTable) { handleDropTable((SqlDropTable) sqlNode); private void handleDropTable(SqlDropTable stmt) { metaStore.dropTable(stmt.tableName()); env.deregisterTable(stmt.tableName()); }
0
MASTER("Master"), ZOOKEEPER("ZooKeeper"), TABLET_SERVER("TServer"), GARBAGE_COLLECTOR("GC"), TRACER("Tracer"), MONITOR("Monitor");
0
import java.util.Collections; * public SchemaImpl(ResourceProvider resourceProvider) {
0
private String[] getParametersForLogging(final Object[] params) { if (params == null) { return null; } final String[] result = new String[params.length]; for (int i = 0; i < params.length; i++) { result[i] = (params[i] == null ? null : params[i].getClass().getName()); } return result; } final ComponentLogger logger = rawParameter.getComponentContext().getLogger(); if (logger.isLogEnabled(LogService.LOG_DEBUG)) { logger.log(LogService.LOG_DEBUG, "invoking {0}: {1}: parameters {2}", null, getMethodNamePrefix(), getMethodName(), Arrays.asList(getParametersForLogging(params))); } final Object result = m_method.invoke(componentInstance, params); logger.log(LogService.LOG_DEBUG, "invoked {0}: {1}", null,
0
/* NOTE (SM): These are the hooks to the future FOM Event Model that will be designed in the future. It has been postponed because we think there are more important things to do at the moment, but these are left here to indicate that they are planned. */
0
public static final boolean disableAutoWatchReset; public static final int packetLen;
0
package org.apache.commons.vfs2.provider.compressed; import org.apache.commons.vfs2.Capability; import org.apache.commons.vfs2.FileName; import org.apache.commons.vfs2.FileObject; import org.apache.commons.vfs2.FileSystemException; import org.apache.commons.vfs2.FileType; import org.apache.commons.vfs2.provider.AbstractFileObject;
1
Map<Resource.Type, String> mapIds = new HashMap<>();
1
assertFalse("is not a readable file validator", validator.isReadable()); assertTrue("is a writable file validator", validator.isWritable());
0
registerTag( "focusListener", FocusListenerTag.class ); registerTag( "keyListener", KeyListenerTag.class );
0
zks.sessionTracker.trackSession(sessionId, sessionTimeout); sessionTrackerImpl.trackSession(sessionId, sessionTimeout); zks.sessionTracker.trackSession(sessionId, sessionTimeout);
0
import java.util.Comparator; import java.util.Map; import java.util.TreeMap; }
0
protected void processBean(String var, Object bean) throws JellyException { throws JellyException {
0
package org.apache.hc.core5.annotation;
1
* @version $Revision$
0
if (value == null || value.isEmpty()) { if (entry.getValue() == null || entry.getValue().isEmpty()) {
0
* @deprecated (4.2) use {@link HttpAsyncRequestExecutor} and {@link HttpAsyncRequester}
0
try(Socket s = new Socket(TEST_LOCALHOST, port)) {
0
/** * @return estimated size of data directory in bytes */ public long getDataDirSize(); /** * @return estimated size of log directory in bytes */ public long getLogDirSize();
1
// TODO - can we delete this override now? if (in == null) { throw new IOException("Stream closed"); }
0
static void runWindowedWordCount(Options options) throws IOException { public static void main(String[] args) throws IOException { Options options = PipelineOptionsFactory.fromArgs(args).withValidation().as(Options.class); runWindowedWordCount(options); }
0
import org.apache.accumulo.shell.ShellUtil;
0
import static java.util.Objects.requireNonNull; this.clock = requireNonNull(clock); this.sink = requireNonNull(sink);
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 use this file except in compliance with * the License. You may obtain a copy of the License at
0
Copyright 2000-2002 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 agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */
0
package org.apache.beam.runners.direct;
0
@Override public void setScanIterators(int priority, String iteratorClass, String iteratorName) {} @Override public void addScanIterator(IteratorSetting cfg) {} @Override public void setScanIteratorOption(String iteratorName, String key, String value) {} @Override public void updateScanIteratorOption(String iteratorName, String key, String value) {} @Override public void setupRegex(String iteratorName, int iteratorPriority) throws IOException {} @Override public void setRowRegex(String regex) {} @Override public void setColumnFamilyRegex(String regex) {} @Override public void setColumnQualifierRegex(String regex) {} @Override public void setValueRegex(String regex) {} @Override public void fetchColumnFamily(Text col) {} @Override public void fetchColumn(Text colFam, Text colQual) {} @Override public void clearColumns() {} @Override public void clearScanIterators() {} @Override public void setTimeOut(int timeOut) {} @Override public int getTimeOut() { return 0; } @Override public void setRange(Range range) {} @Override public Range getRange() { return null; } @Override public void setBatchSize(int size) { } @Override public int getBatchSize() { return 0; } @Override public void enableIsolation() { } @Override public void disableIsolation() { } @Override public Iterator<Entry<Key,Value>> iterator() { return new NullKeyValueIterator(); }
1
import com.twitter.aurora.scheduler.configuration.ParsedConfiguration; // TODO(Bill Farner): Remove this. It is only used since the CronJobManager and SchedulerCoreImpl // have a circular dependency. * @param config The job to schedule. public abstract boolean receiveJob(ParsedConfiguration config) throws ScheduleException;
0
import java.util.ArrayList; @Override public boolean consistentWithEquals() { return getElemCoder().consistentWithEquals(); } @Override public Object structuralValue(List<T> values) { if (consistentWithEquals()) { return values; } else { List<Object> ret = new ArrayList<>(values.size()); for (T value : values) { ret.add(getElemCoder().structuralValue(value)); } return ret; } }
0
public void execute(Storage.MutableStoreProvider storeProvider) {
0
package org.apache.hc.core5.http.impl.nio; import org.apache.hc.core5.util.HeapByteBufferAllocator; * Basic implementation of {@link org.apache.hc.core5.http.nio.HttpAsyncRequestConsumer}. * Please note that this consumer buffers request content in memory and should be used for
1
Halt.halt("Unexpected error in TThreadPoolServer " + e + ", halting.", 1);
0
builder.append(", ").append(requestedColumnNames[i]);
0
@Override public String getSecurityTokenClass() throws AccumuloException { return UserPassToken.class.getCanonicalName(); }
0
* The shift value required to create the upper nibble * from the first of 2 byte values converted from ascii hex. private static final byte[] DECODING_TABLE = new byte[128];
0
if (ver.lessEquals(HttpVersion.HTTP_1_0)) { return; throw new ProtocolException("Target host is unknown");
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 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 * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
0
import org.apache.cocoon.spring.WebAppContextUtils; handle = WebAppContextUtils.enteringContext(this.webAppContext); WebAppContextUtils.leavingContext(this.webAppContext, handle);
0
* Copyright 2002,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 or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * @version $Id: Uberspect.java,v 1.4 2004/02/28 13:45:21 yoavs Exp $
0
@Mock private ShardCheckpoint a, b, c; private KinesisReaderCheckpoint checkpoint; @Before public void setUp() { checkpoint = new KinesisReaderCheckpoint(asList(a, b, c)); } @Test public void splitsCheckpointAccordingly() { verifySplitInto(1); verifySplitInto(2); verifySplitInto(3); verifySplitInto(4); } @Test(expected = UnsupportedOperationException.class) public void isImmutable() { Iterator<ShardCheckpoint> iterator = checkpoint.iterator(); iterator.remove(); } private void verifySplitInto(int size) { List<KinesisReaderCheckpoint> split = checkpoint.splitInto(size); assertThat(Iterables.concat(split)).containsOnly(a, b, c); assertThat(split).hasSize(Math.min(size, 3)); }
0
getAccumuloClient().tableOperations().create(tableName); getAccumuloClient().tableOperations().addSplits(finalName, splits); getAccumuloClient().tableOperations().delete(finalName); assertFalse(getAccumuloClient().tableOperations().exists(tableName));
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 use this file except in compliance with * the License. You may obtain a copy of the License at
0
/** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated /** * @deprecated (4.2) */ @Deprecated
0
* Parses a {@link DoFn} and computes its {@link DoFnSignature}. See {@link #getSignature}. return getSignature(fn.getClass()); public synchronized <FnT extends DoFn<?, ?>> DoFnSignature getSignature(Class<FnT> fn) {
0
public FilterIteratorTest(final String name) { for (final String element : array) { final Iterator<E> iter1 = Collections.singleton((E) new Object()).iterator(); final Iterator<E> iter2 = Collections.<E>emptyList().iterator(); final FilterIterator<E> filterIterator = new FilterIterator<E>(iter1); final Iterator<E> iter = Collections.singleton((E) null).iterator(); final FilterIterator<E> filterIterator = new FilterIterator<E>(iter); catch (final NoSuchElementException e) { final Predicate<E> pred = new Predicate<E>() { public boolean evaluate(final E x) { for (final String element : elements) { final String s = (String)iterator.next(); final Object last = iterator.next(); protected FilterIterator<E> makePassThroughFilter(final Iterator<E> i) { final Predicate<E> pred = new Predicate<E>() { public boolean evaluate(final E x) { return true; } protected FilterIterator<E> makeBlockAllFilter(final Iterator<E> i) { final Predicate<E> pred = new Predicate<E>() { public boolean evaluate(final E x) { return false; }
0
assertOkResponse(thrift.addInstances(INSTANCE_KEY, 2)); thrift.addInstances(INSTANCE_KEY, 2)); thrift.addInstances(INSTANCE_KEY, 0)); assertResponse(INVALID_REQUEST, thrift.addInstances(INSTANCE_KEY, 1)); thrift.addInstances(INSTANCE_KEY, 1); assertResponse(LOCK_ERROR, thrift.addInstances(INSTANCE_KEY, 1)); assertResponse(INVALID_REQUEST, thrift.addInstances(INSTANCE_KEY, 1)); assertResponse(INVALID_REQUEST, thrift.addInstances(INSTANCE_KEY, 1)); assertResponse(INVALID_REQUEST, thrift.addInstances(INSTANCE_KEY, 1));
0
import org.eclipse.jetty.jmx.MBeanContainer; import org.eclipse.jetty.server.Server;
0
@Mock private HealthCheckExecutorServletConfiguration healthCheckExecutorServletConfig; doReturn(true).when(healthCheckExecutorServletConfig).disabled(); doReturn("OK:200").when(healthCheckExecutorServletConfig).httpStatusMapping(); healthCheckExecutorServlet.activate(healthCheckExecutorServletConfig); Map<Status, Integer> statusMapping = healthCheckExecutorServlet.getStatusMapping("CRITICAL:500"); assertEquals(statusMapping.get(Result.Status.TEMPORARILY_UNAVAILABLE), (Integer) 503); assertEquals(statusMapping.get(Result.Status.CRITICAL), (Integer) 500); assertEquals(statusMapping.get(Result.Status.HEALTH_CHECK_ERROR), (Integer) 500); assertEquals(statusMapping.get(Result.Status.TEMPORARILY_UNAVAILABLE), (Integer) 503); assertEquals(statusMapping.get(Result.Status.CRITICAL), (Integer) 503); assertEquals(statusMapping.get(Result.Status.HEALTH_CHECK_ERROR), (Integer) 500); statusMapping = healthCheckExecutorServlet.getStatusMapping("OK:200,WARN:418,CRITICAL:503,TEMPORARILY_UNAVAILABLE:503,HEALTH_CHECK_ERROR:500"); assertEquals(statusMapping.get(Result.Status.TEMPORARILY_UNAVAILABLE), (Integer) 503); statusMapping = healthCheckExecutorServlet.getStatusMapping("WARN:418,HEALTH_CHECK_ERROR:503"); assertEquals(statusMapping.get(Result.Status.WARN), (Integer) 418); assertEquals(statusMapping.get(Result.Status.TEMPORARILY_UNAVAILABLE), (Integer) 503); assertEquals(statusMapping.get(Result.Status.HEALTH_CHECK_ERROR), (Integer) 503); @Test(expected = IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class) @Test(expected = IllegalArgumentException.class)
0
try { context.log("ShieldingListener: Loading listener class " + className);
0
import org.apache.commons.vfs2.FileObject; // @Override - commented in FilesCache interface public void touchFile(final FileObject file) { }
0
currentStackId, cluster, true); newConfigurationsByType = configHelper.getDefaultProperties(targetStackId, cluster, true);
0
private final Set<Long> hostIds; private final Set<String> hosts; public HostsRemovedEvent(Set<String> hosts, Set<Long> hostIds) { this.hostIds = hostIds != null ? hostIds : Collections.emptySet(); this.hosts = hosts != null ? hosts : Collections.emptySet(); * @return names of removed hosts public Set<String> getHostNames() { return hosts; * @return ids of removed hosts public Set<Long> getHostIds() { return hostIds; return "HostsRemovedEvent{" + hosts + "}";
0
* @version $Id$
0
assertThat(pipeline.getCoderRegistry().getCoder(output.getTypeDescriptor()), equalTo(pipeline.getCoderRegistry().getCoder(new TypeDescriptor<String>() {})));
0
* <p>This pipeline processes an unbounded stream of 'game events'. The calculation of the team * <p>In contrast-- to demo another windowing option-- the user scores are calculated using a * <p>In contrast to the previous pipelines in the series, which used static, finite input data, * <p>Run {@link injector.Injector} to generate pubsub data for this pipeline. The Injector * <p>To execute this pipeline using the Dataflow service, specify the pipeline configuration
0
package aQute.bnd.build; public class CircularDependencyException extends Exception { public CircularDependencyException(String string) { super(string); } private static final long serialVersionUID = 1L; }
0
if (formatter == null) {
0
* @version CVS $Id: JobScheduler.java,v 1.4 2003/09/04 15:59:09 giacomo Exp $ * Get the names of all scheduled jobs. * * @return state of execution successfullness */ String[] getJobNames(); /** * Get the JobSchedulerEntry for a scheduled job * * @return the entry */ JobSchedulerEntry getJobSchedulerEntry(String jobname); /** * Fire a job once immediately * @return success state adding the job * Fire a CronJob once immediately * @param job The job object itself. It must implement either CronJob, Runnable or might also be an implementation * specific class (i.e. org.quartz.Job) * @return whether the job has been successfully started boolean fireJob(Object job); * Fire a job once immediately * @param jobrole The Avalon components role name of the job itself * @param params Additional Parameters to setup CronJob * @param objects A Map with additional object to setup CronJob * @return whether the job has been successfully started boolean fireJob(String jobrole, Parameters params, Map objects) throws CascadingException; * Fire a job once immediately * @return whether the job has been successfully started * Fire a job once at a specific date throws CascadingException; * Fire a job once immediately throws CascadingException; * Fire a job once immediately
0
* $Header: /home/jerenkrantz/tmp/commons/commons-convert/cvs/home/cvs/jakarta-commons//collections/src/java/org/apache/commons/collections/Attic/LazyCollections.java,v 1.3 2002/06/16 03:39:40 mas Exp $ * $Revision: 1.3 $ * $Date: 2002/06/16 03:39:40 $ * @version $Revision: 1.3 $ }
0
if (mev.getModifiersEx() == e.getModifiersEx()) { if (mev.getModifiersEx() == e.getModifiersEx()) {
0
import org.apache.beam.vendor.guava.v26_0_jre.com.google.common.io.BaseEncoding;
0
* Decorates another {@link Iterator} using a predicate to filter elements. * <p> * This iterator decorates the underlying iterator, only allowing through * those elements that match the specified {@link Predicate Predicate}.
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 use this file except in compliance with the License. You may obtain a copy of the License at
0
byte[] decodedBytes = XMLUtils.decode(sb.toString()); byte[] bytes = XMLUtils.decode(sb.toString()); byte[] decodedBytes = XMLUtils.decode(base64Bytes); byte[] bytes = XMLUtils.decode(input.getBytes()); byte[] bytes = XMLUtils.decode(inputBytes); byte[] decodedBytes = XMLUtils.decode(sb.toString());
0
if (this.status.compareTo(IOReactorStatus.INACTIVE) == 0) { this.status = IOReactorStatus.SHUT_DOWN; cancelRequests(); return; }
0
public void testSharedDedicatedHost() throws Exception { String dedicated1 = "ads/adserver"; String dedicated2 = "kestrel/kestrel"; expectGetHostAttributes(HOST_A, dedicated(dedicated1, dedicated2)).anyTimes(); control.replay(); assertNoVetoes(checkConstraint( new Identity().setRole("ads"), "adserver", HOST_A, DEDICATED_ATTRIBUTE, true, dedicated1)); assertNoVetoes(checkConstraint( new Identity().setRole("kestrel"), "kestrel", HOST_A, DEDICATED_ATTRIBUTE, true, dedicated2)); } @Test private Attribute dedicated(String value, String... values) { return valueAttribute(DEDICATED_ATTRIBUTE, value, values); private TwitterTaskInfo checkConstraint( String host, String constraintName, boolean expected, String value, String... vs) { return checkConstraint(OWNER_A, JOB_A, host, constraintName, expected, value, vs); private TwitterTaskInfo checkConstraint( Identity owner, String jobName, String host, String constraintName, boolean expected, String value, String... vs) { return checkConstraint(owner, jobName, host, constraintName, expected, private TwitterTaskInfo checkConstraint( Identity owner, String jobName, String host, String constraintName, boolean expected, ValueConstraint value) { TwitterTaskInfo task = makeTask(owner, jobName, constraint); assertEquals( expected, defaultFilter.filter(DEFAULT_OFFER, host, task, TASK_ID).isEmpty()); TwitterTaskInfo negatedTask = makeTask(owner, jobName, negated); assertEquals( !expected, defaultFilter.filter(DEFAULT_OFFER, host, negatedTask, TASK_ID).isEmpty()); return task;
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 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 * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.hedwig.server.delivery; import com.google.protobuf.ByteString; import org.apache.hedwig.protocol.PubSubProtocol.MessageSeqId; import org.apache.hedwig.server.subscriptions.MessageFilter; public interface DeliveryManager { public void startServingSubscription(ByteString topic, ByteString subscriberId, MessageSeqId seqIdToStartFrom, DeliveryEndPoint endPoint, MessageFilter filter, boolean isHubSubscriber); public void stopServingSubscriber(ByteString topic, ByteString subscriberId); }
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 use this file except in compliance with the License. You may obtain a copy of the License at
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 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 * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package org.apache.bcel.util; import java.io.File; import java.io.FileInputStream; import junit.framework.TestCase; import org.apache.bcel.classfile.ClassParser; public class Class2HTMLTestCase extends TestCase { public void testConvertJavaUtil() throws Exception { File outputDir = new File("target/test-output/html"); outputDir.mkdirs(); FileInputStream file = new FileInputStream("target/test-classes/Java8Example.class"); ClassParser parser = new ClassParser(file, "Java8Example.class"); new Class2HTML(parser.parse(), outputDir.getAbsolutePath() + "/"); } }
0
import org.apache.accumulo.fate.zookeeper.ZooReaderWriter;
0