name stringlengths 12 178 | code_snippet stringlengths 8 36.5k | score float64 3.26 3.68 |
|---|---|---|
hadoop_RouterQuotaManager_clear | /**
* Clean up the cache.
*/
public void clear() {
writeLock.lock();
try {
this.cache.clear();
} finally {
writeLock.unlock();
}
} | 3.68 |
Activiti_TreeValueExpression_isReadOnly | /**
* Evaluates the expression as an lvalue and determines if {@link #setValue(ELContext, Object)}
* will always fail.
* @param context used to resolve properties (<code>base.property</code> and <code>base[property]</code>)
* and to determine the result from the last base/property pair
* @return <code>true</code> ... | 3.68 |
hibernate-validator_GroupConversionHelper_convertGroup | /**
* Converts the given validation group as per the group conversion
* configuration for this property (as e.g. specified via
* {@code @ConvertGroup}.
*
* @param from The group to convert.
*
* @return The converted group. Will be the original group itself in case no
* conversion is to be performed.
*/... | 3.68 |
flink_PanedWindowProcessFunction_isPaneLate | /** checks whether the pane is late (e.g. can be / has been cleanup) */
private boolean isPaneLate(W pane) {
// whether the pane is late depends on the last window which the pane is belongs to is late
return windowAssigner.isEventTime() && isWindowLate(windowAssigner.getLastWindow(pane));
} | 3.68 |
framework_VaadinFinderLocatorStrategy_eliminateDuplicates | /**
* Go through a list, removing all duplicate elements from it. This method
* is used to avoid accumulation of duplicate entries in result lists
* resulting from low-context recursion.
*
* Preserves first entry in list, removes others. Preserves list order.
*
* @return list passed as parameter, after modificat... | 3.68 |
zxing_MinimalEncoder_getLastASCII | /** Peeks ahead and returns 1 if the postfix consists of exactly two digits, 2 if the postfix consists of exactly
* two consecutive digits and a non extended character or of 4 digits.
* Returns 0 in any other case
**/
int getLastASCII() {
int length = input.length();
int from = fromPosition + characterLength;
... | 3.68 |
hbase_MemStoreLABImpl_copyBBECellInto | /**
* Mostly a duplicate of {@link #copyCellInto(Cell, int)}} done for perf sake. It presumes
* ByteBufferExtendedCell instead of Cell so we deal with a specific type rather than the super
* generic Cell. Removes instanceof checks. Shrinkage is enough to make this inline where before
* it was too big. Uses less CPU... | 3.68 |
morf_AbstractSqlDialectTest_testCastToBoolean | /**
* Tests the output of a cast to a boolean.
*/
@Test
public void testCastToBoolean() {
String result = testDialect.getSqlFrom(new Cast(new FieldReference("value"), DataType.BOOLEAN, 10));
assertEquals(expectedBooleanCast(), result);
} | 3.68 |
hbase_ZKConfig_makeZKPropsFromHbaseConfig | /**
* Make a Properties object holding ZooKeeper config. Parses the corresponding config options from
* the HBase XML configs and generates the appropriate ZooKeeper properties.
* @param conf Configuration to read from.
* @return Properties holding mappings representing ZooKeeper config file.
*/
private static Pro... | 3.68 |
dubbo_StringUtils_toCommaDelimitedString | /**
* Create the common-delimited {@link String} by one or more {@link String} members
*
* @param one one {@link String}
* @param others others {@link String}
* @return <code>null</code> if <code>one</code> or <code>others</code> is <code>null</code>
* @since 2.7.8
*/
public static String toCommaDelimitedStri... | 3.68 |
pulsar_ConcurrentLongHashMap_forEach | /**
* Iterate over all the entries in the map and apply the processor function to each of them.
* <p>
* <b>Warning: Do Not Guarantee Thread-Safety.</b>
* @param processor the processor to apply to each entry
*/
public void forEach(EntryProcessor<V> processor) {
for (int i = 0; i < sections.length; i++) {
... | 3.68 |
flink_AvroDeserializationSchema_forGeneric | /**
* Creates {@link AvroDeserializationSchema} that produces {@link GenericRecord} using provided
* schema.
*
* @param schema schema of produced records
* @param encoding Avro serialization approach to use for decoding
* @return deserialized record in form of {@link GenericRecord}
*/
public static AvroDeseriali... | 3.68 |
hadoop_Signer_sign | /**
* Returns a signed string.
*
* @param str string to sign.
*
* @return the signed string.
*/
public synchronized String sign(String str) {
if (str == null || str.length() == 0) {
throw new IllegalArgumentException("NULL or empty string to sign");
}
byte[] secret = secretProvider.getCurrentSecret();
... | 3.68 |
framework_Escalator_getCalculatedColumnsWidth | /**
* Calculates the width of the columns in a given range.
*
* @param columns
* the columns to calculate
* @return the total width of the columns in the given
* <code>columns</code>
*/
double getCalculatedColumnsWidth(final Range columns) {
/*
* This is an assert instead of an except... | 3.68 |
framework_GridDropTarget_setDropMode | /**
* Sets the drop mode of this drop target.
* <p>
* When using {@link DropMode#ON_TOP}, and the grid is either empty or has
* empty space after the last row, the drop can still happen on the empty
* space, and the {@link GridDropEvent#getDropTargetRow()} will return an
* empty optional.
* <p>
* When using {@l... | 3.68 |
flink_ParameterTool_getConfiguration | /**
* Returns a {@link Configuration} object from this {@link ParameterTool}.
*
* @return A {@link Configuration}
*/
public Configuration getConfiguration() {
final Configuration conf = new Configuration();
for (Map.Entry<String, String> entry : data.entrySet()) {
conf.setString(entry.getKey(), entr... | 3.68 |
hbase_FSTableDescriptors_writeTableDescriptor | /**
* Attempts to write a new table descriptor to the given table's directory. It begins at the
* currentSequenceId + 1 and tries 10 times to find a new sequence number not already in use.
* <p/>
* Removes the current descriptor file if passed in.
* @return Descriptor file or null if we failed write.
*/
private s... | 3.68 |
hadoop_BufferPool_tryAcquire | /**
* Acquires a buffer if one is immediately available. Otherwise returns null.
* @param blockNumber the id of the block to try acquire.
* @return the acquired block's {@code BufferData} or null.
*/
public synchronized BufferData tryAcquire(int blockNumber) {
return acquireHelper(blockNumber, false);
} | 3.68 |
flink_MiniCluster_start | /**
* Starts the mini cluster, based on the configured properties.
*
* @throws Exception This method passes on any exception that occurs during the startup of the
* mini cluster.
*/
public void start() throws Exception {
synchronized (lock) {
checkState(!running, "MiniCluster is already running");
... | 3.68 |
morf_AbstractSqlDialectTest_expectedSqlForMathOperations6 | /**
* @return expected SQL for math operation 6
*/
protected String expectedSqlForMathOperations6() {
return "a + b / (c - d)";
} | 3.68 |
hbase_IndividualBytesFieldCell_getQualifierArray | // 3) Qualifier
@Override
public byte[] getQualifierArray() {
// Qualifier could be null
return (qualifier == null) ? HConstants.EMPTY_BYTE_ARRAY : qualifier;
} | 3.68 |
streampipes_AdapterResourceManager_encryptAndCreate | /**
* Takes an {@link AdapterDescription}, encrypts the password properties and stores it to the database
*
* @param adapterDescription input adapter description
* @return the id of the created adapter
*/
public String encryptAndCreate(AdapterDescription adapterDescription) {
AdapterDescription encryptedAdapterD... | 3.68 |
framework_AbstractMultiSelect_updateSelection | /**
* Updates the selection by adding and removing the given items.
*
* @param addedItems
* the items added to selection, not {@code} null
* @param removedItems
* the items removed from selection, not {@code} null
* @param userOriginated
* {@code true} if this was used originate... | 3.68 |
framework_VDragAndDropManager_get | /**
* Returns the current drag and drop manager instance. If one doesn't exist
* yet, it's created.
*
* @return the current drag and drop manager
*/
public static VDragAndDropManager get() {
if (instance == null) {
instance = GWT.create(VDragAndDropManager.class);
}
return instance;
} | 3.68 |
hbase_StorageClusterStatusModel_setReadRequestsCount | /**
* @param readRequestsCount The current total read requests made to region
*/
public void setReadRequestsCount(long readRequestsCount) {
this.readRequestsCount = readRequestsCount;
} | 3.68 |
zxing_AlignmentPattern_combineEstimate | /**
* Combines this object's current estimate of a finder pattern position and module size
* with a new estimate. It returns a new {@code FinderPattern} containing an average of the two.
*/
AlignmentPattern combineEstimate(float i, float j, float newModuleSize) {
float combinedX = (getX() + j) / 2.0f;
float comb... | 3.68 |
pulsar_ManagedCursorImpl_asyncReplayEntries | /**
* Async replays given positions: a. before reading it filters out already-acked messages b. reads remaining entries
* async and gives it to given ReadEntriesCallback c. returns all already-acked messages which are not replayed so,
* those messages can be removed by caller(Dispatcher)'s replay-list and it won't t... | 3.68 |
hadoop_FileIoProvider_openAndSeek | /**
* Create a FileInputStream using
* {@link FileInputStream#FileInputStream(File)} and position
* it at the given offset.
*
* Wraps the created input stream to intercept read calls
* before delegating to the wrapped stream.
*
* @param volume target volume. null if unavailable.
* @param f File object.
* @p... | 3.68 |
pulsar_ProducerConfiguration_setBlockIfQueueFull | /**
* Set whether the {@link Producer#send} and {@link Producer#sendAsync} operations should block when the outgoing
* message queue is full.
* <p>
* Default is <code>false</code>. If set to <code>false</code>, send operations will immediately fail with
* {@link PulsarClientException.ProducerQueueIsFullError} when... | 3.68 |
flink_FsStateBackend_isUsingAsynchronousSnapshots | /**
* Gets whether the key/value data structures are asynchronously snapshotted, which is always
* true for this state backend.
*/
public boolean isUsingAsynchronousSnapshots() {
return true;
} | 3.68 |
framework_Label_readDesign | /*
* (non-Javadoc)
*
* @see com.vaadin.ui.AbstractComponent#readDesign(org.jsoup.nodes .Element,
* com.vaadin.ui.declarative.DesignContext)
*/
@Override
public void readDesign(Element design, DesignContext designContext) {
super.readDesign(design, designContext);
String innerHtml = design.html();
boole... | 3.68 |
morf_Function_toString | /**
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
return type.toString() + "(" + StringUtils.join(arguments, ", ") + ")" + super.toString();
} | 3.68 |
framework_AbstractClientConnector_addExtension | /**
* Add an extension to this connector. This method is protected to allow
* extensions to select which targets they can extend.
*
* @param extension
* the extension to add
*/
protected void addExtension(Extension extension) {
ClientConnector previousParent = extension.getParent();
if (equals(... | 3.68 |
hbase_RegionServerObserver_preRollWALWriterRequest | /**
* This will be called before executing user request to roll a region server WAL.
* @param ctx the environment to interact with the framework and region server.
*/
default void preRollWALWriterRequest(
final ObserverContext<RegionServerCoprocessorEnvironment> ctx) throws IOException {
} | 3.68 |
flink_KeyedStateTransformation_transform | /**
* Method for passing user defined operators along with the type information that will transform
* the OperatorTransformation.
*
* <p><b>IMPORTANT:</b> Any output from this operator will be discarded.
*
* @param factory A factory returning transformation logic type of the return stream
* @return An {@link Sta... | 3.68 |
framework_AbstractMultiSelect_addValueChangeListener | /**
* Adds a value change listener. The listener is called when the selection
* set of this multi select is changed either by the user or
* programmatically.
*
* @see #addSelectionListener(MultiSelectionListener)
*
* @param listener
* the value change listener, not null
* @return a registration for ... | 3.68 |
framework_VTree_nodeIsInBranch | /**
* Examines the children of the branch node and returns true if a node is in
* that branch
*
* @param node
* The node to search for
* @param branch
* The branch to search in
* @return True if found, false if not found
*/
private boolean nodeIsInBranch(TreeNode node, TreeNode branch) {
... | 3.68 |
flink_FlinkRelMetadataQuery_getUniqueGroups | /**
* Returns the (minimum) unique groups of the given columns.
*
* @param rel the relational expression
* @param columns the given columns in a specified relational expression. The given columns
* should not be null.
* @return the (minimum) unique columns which should be a sub-collection of the given columns... | 3.68 |
hbase_AsyncTable_batchAll | /**
* A simple version of batch. It will fail if there are any failures and you will get the whole
* result list at once if the operation is succeeded.
* @param actions list of Get, Put, Delete, Increment, Append and RowMutations objects
* @return A list of the result for the actions. Wrapped by a {@link Completabl... | 3.68 |
pulsar_BrokerInterceptor_messageProduced | /**
* Intercept after a message is produced.
*
* @param cnx client Connection
* @param producer Producer object
* @param publishContext Publish Context
*/
default void messageProduced(ServerCnx cnx, Producer producer, long startTimeNs, long ledgerId,
long entryId, Topic.PublishContext... | 3.68 |
pulsar_PulsarClientImplementationBindingImpl_decodeKeyValueEncodingType | /**
* Decode the kv encoding type from the schema info.
*
* @param schemaInfo the schema info
* @return the kv encoding type
*/
public KeyValueEncodingType decodeKeyValueEncodingType(SchemaInfo schemaInfo) {
return KeyValueSchemaInfo.decodeKeyValueEncodingType(schemaInfo);
} | 3.68 |
pulsar_ConnectionPool_connectToResolvedAddresses | /**
* Try to connect to a sequence of IP addresses until a successful connection can be made, or fail if no
* address is working.
*/
private CompletableFuture<Channel> connectToResolvedAddresses(InetSocketAddress logicalAddress,
InetSocketAddress unresolv... | 3.68 |
framework_Heartbeat_init | /**
* Initializes the heartbeat for the given application connection.
*
* @param applicationConnection
* the connection
*/
public void init(ApplicationConnection applicationConnection) {
connection = applicationConnection;
setInterval(connection.getConfiguration().getHeartbeatInterval());
... | 3.68 |
flink_GeneratorFunction_open | /**
* Initialization method for the function. It is called once before the actual data mapping
* methods.
*/
default void open(SourceReaderContext readerContext) throws Exception {} | 3.68 |
querydsl_ProjectableSQLQuery_addJoinFlag | /**
* Add the given String literal as a join flag to the last added join
*
* @param flag join flag
* @param position position
* @return the current object
*/
@Override
@SuppressWarnings("unchecked")
public Q addJoinFlag(String flag, JoinFlag.Position position) {
queryMixin.addJoinFlag(new JoinFlag(flag, posit... | 3.68 |
hbase_AssignmentVerificationReport_getNonFavoredAssignedRegions | /**
* Return the regions not assigned to its favored nodes
* @return regions not assigned to its favored nodes
*/
List<RegionInfo> getNonFavoredAssignedRegions() {
return nonFavoredAssignedRegionList;
} | 3.68 |
framework_ListenerMethod_getTarget | /**
* Returns the target object which contains the trigger method.
*
* @return The target object
*/
public Object getTarget() {
return target;
} | 3.68 |
hadoop_AbfsOutputStream_toString | /**
* Appending AbfsOutputStream statistics to base toString().
*
* @return String with AbfsOutputStream statistics.
*/
@Override
public String toString() {
final StringBuilder sb = new StringBuilder(super.toString());
sb.append("AbfsOutputStream@").append(this.hashCode());
sb.append("){");
sb.append(output... | 3.68 |
hbase_TableOutputFormat_getRecordWriter | /**
* Creates a new record writer. Be aware that the baseline javadoc gives the impression that there
* is a single {@link RecordWriter} per job but in HBase, it is more natural if we give you a new
* RecordWriter per call of this method. You must close the returned RecordWriter when done.
* Failure to do so will d... | 3.68 |
flink_FloatParser_parseField | /**
* Static utility to parse a field of type float from a byte sequence that represents text
* characters (such as when read from a file stream).
*
* @param bytes The bytes containing the text data that should be parsed.
* @param startPos The offset to start the parsing.
* @param length The length of the byte se... | 3.68 |
hudi_SparkHoodieBackedTableMetadataWriter_create | /**
* Return a Spark based implementation of {@code HoodieTableMetadataWriter} which can be used to
* write to the metadata table.
* <p>
* If the metadata table does not exist, an attempt is made to bootstrap it but there is no guaranteed that
* table will end up bootstrapping at this time.
*
* @param conf
* @p... | 3.68 |
incubator-hugegraph-toolchain_FileUtil_countLines | /**
* NOTE: If there is no blank line at the end of the file,
* one line will be missing
*/
public static int countLines(File file) {
if (!file.exists()) {
throw new IllegalArgumentException(String.format(
"The file %s doesn't exist", file));
}
long fileLength = file.length();
... | 3.68 |
flink_FieldParser_endsWithDelimiter | /**
* Checks if the given bytes ends with the delimiter at the given end position.
*
* @param bytes The byte array that holds the value.
* @param endPos The index of the byte array where the check for the delimiter ends.
* @param delim The delimiter to check for.
* @return true if a delimiter ends at the given en... | 3.68 |
hadoop_LocalCacheDirectoryManager_getRelativePathForLocalization | /**
* This method will return relative path from the first available vacant
* directory.
*
* @return {@link String} relative path for localization
*/
public synchronized String getRelativePathForLocalization() {
if (nonFullDirectories.isEmpty()) {
totalSubDirectories++;
Directory newDir = new Directory(... | 3.68 |
flink_ColumnStats_getMinValue | /**
* Deprecated because Number type max/min is not well supported comparable type, e.g. {@link
* java.util.Date}, {@link java.sql.Timestamp}.
*
* <p>Returns null if this instance is constructed by {@link ColumnStats.Builder}.
*/
@Deprecated
public Number getMinValue() {
return minValue;
} | 3.68 |
AreaShop_AreaShop_getWorldEditHandler | /**
* Function to get WorldGuardInterface for version dependent things.
* @return WorldGuardInterface
*/
public WorldEditInterface getWorldEditHandler() {
return this.worldEditInterface;
} | 3.68 |
morf_RenameTable_indexes | /**
* @see org.alfasoftware.morf.metadata.Table#indexes()
*/
@Override
public List<Index> indexes() {
return baseTable.indexes();
} | 3.68 |
flink_DeclarativeSlotManager_freeSlot | /**
* Free the given slot from the given allocation. If the slot is still allocated by the given
* allocation id, then the slot will be marked as free and will be subject to new slot requests.
*
* @param slotId identifying the slot to free
* @param allocationId with which the slot is presumably allocated
*/
@Over... | 3.68 |
hbase_PrivateCellUtil_createFirstOnRowColTS | /**
* Creates the first cell with the row/family/qualifier of this cell and the given timestamp. Uses
* the "maximum" type that guarantees that the new cell is the lowest possible for this
* combination of row, family, qualifier, and timestamp. This cell's own timestamp is ignored.
* @param cell - cell
*/
public s... | 3.68 |
flink_Task_getExecutionState | /**
* Returns the current execution state of the task.
*
* @return The current execution state of the task.
*/
public ExecutionState getExecutionState() {
return this.executionState;
} | 3.68 |
flink_HsMemoryDataManager_getNextBufferIndexToConsume | // Write lock should be acquired before invoke this method.
@Override
public List<Integer> getNextBufferIndexToConsume(HsConsumerId consumerId) {
ArrayList<Integer> consumeIndexes = new ArrayList<>(numSubpartitions);
for (int channel = 0; channel < numSubpartitions; channel++) {
HsSubpartitionConsumerIn... | 3.68 |
zilla_ManyToOneRingBuffer_maxMsgLength | /**
* {@inheritDoc}
*/
public int maxMsgLength()
{
return maxMsgLength;
} | 3.68 |
hbase_MetricSampleQuantiles_insertBatch | /**
* Merges items from buffer into the samples array in one pass. This is more efficient than doing
* an insert on every item.
*/
private void insertBatch() {
if (bufferCount == 0) {
return;
}
Arrays.sort(buffer, 0, bufferCount);
// Base case: no samples
int start = 0;
if (samples.isEmpty()) {
... | 3.68 |
flink_CombinedWatermarkStatus_updateCombinedWatermark | /**
* Checks whether we need to update the combined watermark.
*
* <p><b>NOTE:</b>It can update {@link #isIdle()} status.
*
* @return true, if the combined watermark changed
*/
public boolean updateCombinedWatermark() {
long minimumOverAllOutputs = Long.MAX_VALUE;
// if we don't have any outputs minimumO... | 3.68 |
framework_ErrorEvent_getThrowable | /**
* Gets the contained throwable, the cause of the error.
*
* @return
*/
public Throwable getThrowable() {
return throwable;
} | 3.68 |
hudi_HoodieIndexUtils_tagAsNewRecordIfNeeded | /**
* Get tagged record for the passed in {@link HoodieRecord}.
*
* @param record instance of {@link HoodieRecord} for which tagging is requested
* @param location {@link HoodieRecordLocation} for the passed in {@link HoodieRecord}
* @return the tagged {@link HoodieRecord}
*/
public static <R> HoodieRecord<R> t... | 3.68 |
hbase_TableName_valueOf | /**
* Construct a TableName
* @throws IllegalArgumentException if fullName equals old root or old meta. Some code depends on
* this.
*/
public static TableName valueOf(String name) {
for (TableName tn : tableCache) {
if (name.equals(tn.getNameAsString())) {
return tn;
... | 3.68 |
morf_GraphBasedUpgrade_getPreUpgradeStatements | /**
* @return statements which must be executed before the upgrade
*/
public List<String> getPreUpgradeStatements() {
return preUpgradeStatements;
} | 3.68 |
hadoop_FederationBlock_initSubClusterPageItem | /**
* We will initialize the specific SubCluster's data within this method.
*
* @param tbody HTML TBody.
* @param subClusterInfo Sub-cluster information.
* @param lists Used to record data that needs to be displayed in JS.
*/
private void initSubClusterPageItem(TBODY<TABLE<Hamlet>> tbody,
SubClusterInfo subCl... | 3.68 |
rocketmq-connect_RocketMqDatabaseHistory_recoverRecords | /**
* Recover records
*
* @param records
*/
@Override
protected void recoverRecords(Consumer<HistoryRecord> records) {
DefaultLitePullConsumer consumer = null;
try {
consumer = RocketMqAdminUtil.initDefaultLitePullConsumer(rocketMqConfig, false);
consumer.start();
// Select message ... | 3.68 |
flink_SnapshotDirectory_cleanup | /**
* Calling this method will attempt delete the underlying snapshot directory recursively, if the
* state is "ongoing". In this case, the state will be set to "deleted" as a result of this
* call.
*
* @return <code>true</code> if delete is successful, <code>false</code> otherwise.
* @throws IOException if an ex... | 3.68 |
dubbo_AbstractTripleReactorSubscriber_subscribe | /**
* Binding the downstream, and call subscription#request(1).
*
* @param downstream downstream
*/
public void subscribe(final CallStreamObserver<T> downstream) {
if (downstream == null) {
throw new NullPointerException();
}
if (this.downstream == null && SUBSCRIBED.compareAndSet(false, true)) ... | 3.68 |
streampipes_Formats_smileFormat | /**
* Defines the transport format SMILE used by a data stream at runtime.
*
* @return The {@link org.apache.streampipes.model.grounding.TransportFormat} of type SMILE.
*/
public static TransportFormat smileFormat() {
return new TransportFormat(MessageFormat.SMILE);
} | 3.68 |
MagicPlugin_MageDataStore_obtainLock | /**
* Force-obtain a lock for a mage
*/
default void obtainLock(MageData mage) {} | 3.68 |
AreaShop_Utils_evaluateToDouble | /**
* Evaluate string input to a number.
* Uses JavaScript for expressions.
* @param input The input string
* @param region The region to apply replacements for and use for logging
* @return double evaluated from the input or a very high default in case of a script exception
*/
public static double evaluateToDou... | 3.68 |
MagicPlugin_Wand_setMage | // This should be used sparingly, if at all... currently only
// used when applying an upgrade to a wand while not held
public void setMage(Mage mage) {
this.mage = mage;
} | 3.68 |
hadoop_TaskPool_resetStatisticsContext | /**
* Reset the statistics context if it was set earlier.
* This unbinds the current thread from any statistics
* context.
*/
private void resetStatisticsContext() {
if (ioStatisticsContext != null) {
IOStatisticsContext.setThreadIOStatisticsContext(null);
}
} | 3.68 |
dubbo_AbstractZookeeperTransporter_fetchAndUpdateZookeeperClientCache | /**
* get the ZookeeperClient from cache, the ZookeeperClient must be connected.
* <p>
* It is not private method for unit test.
*
* @param addressList
* @return
*/
public ZookeeperClient fetchAndUpdateZookeeperClientCache(List<String> addressList) {
ZookeeperClient zookeeperClient = null;
for (String ad... | 3.68 |
flink_HiveParserSemanticAnalyzer_doPhase1 | /**
* Phase 1: (including, but not limited to): 1. Gets all the aliases for all the tables /
* subqueries and makes the appropriate mapping in aliasToTabs, aliasToSubq 2. Gets the location
* of the destination and names the clause "inclause" + i 3. Creates a map from a string
* representation of an aggregation tree... | 3.68 |
hbase_MetricsConnection_getDeleteTracker | /** deleteTracker metric */
public CallTracker getDeleteTracker() {
return deleteTracker;
} | 3.68 |
hadoop_RpcScheduler_addResponseTime | /**
* Store a processing time value for an RPC call into this scheduler.
*
* @param callName The name of the call.
* @param schedulable The schedulable representing the incoming call.
* @param details The details of processing time.
*/
@SuppressWarnings("deprecation")
default void addResponseTime(String callName,... | 3.68 |
framework_VAbstractTextualDate_cleanFormat | /**
* Clean date format string to make it suitable for
* {@link #getFormatString()}.
*
* @see #getFormatString()
*
* @param format
* date format string
* @return cleaned up string
*/
protected String cleanFormat(String format) {
// Remove unsupported patterns
// TODO support for 'G', era des... | 3.68 |
dubbo_DubboBootstrap_start | /**
* Start dubbo application
*
* @param wait If true, wait for startup to complete, or else no waiting.
* @return
*/
public DubboBootstrap start(boolean wait) {
Future future = applicationDeployer.start();
if (wait) {
try {
future.get();
} catch (Exception e) {
thro... | 3.68 |
pulsar_AuthorizationProvider_initialize | /**
* Perform initialization for the authorization provider.
*
* @param conf
* broker config object
* @param pulsarResources
* Resources component for access to metadata
* @throws IOException
* if the initialization fails
*/
default void initialize(ServiceConfiguration conf, P... | 3.68 |
framework_JSR356WebsocketInitializer_getAttributeName | /**
* Returns the name of the attribute in the servlet context where the
* pre-initialized Atmosphere object is stored.
*
* @param servletName
* The name of the servlet
* @return The attribute name which contains the initialized Atmosphere
* object
*/
public static String getAttributeName(Str... | 3.68 |
flink_ProducerMergedPartitionFileReader_lazyInitializeFileChannel | /**
* Initialize the file channel in a lazy manner, which can reduce usage of the file descriptor
* resource.
*/
private void lazyInitializeFileChannel() {
if (fileChannel == null) {
try {
fileChannel = FileChannel.open(dataFilePath, StandardOpenOption.READ);
} catch (IOException e) {... | 3.68 |
hudi_HoodieFunctionalIndexMetadata_fromJson | /**
* Deserialize from JSON string to create an instance of this class.
*
* @param json Input JSON string.
* @return Deserialized instance of HoodieFunctionalIndexMetadata.
* @throws IOException If any deserialization errors occur.
*/
public static HoodieFunctionalIndexMetadata fromJson(String json) throws IOExce... | 3.68 |
flink_InternalSourceReaderMetricGroup_watermarkEmitted | /**
* Called when a watermark was emitted.
*
* <p>Note this function should be called before the actual watermark is emitted such that
* chained processing does not influence the statistics.
*/
public void watermarkEmitted(long watermark) {
if (watermark == MAX_WATERMARK_TIMESTAMP) {
return;
}
... | 3.68 |
framework_AbstractClientConnector_getRpcProxy | /**
* Returns an RPC proxy for a given server to client RPC interface for this
* component.
*
* TODO more javadoc, subclasses, ...
*
* @param rpcInterface
* RPC interface type
*
* @since 7.0
*/
protected <T extends ClientRpc> T getRpcProxy(final Class<T> rpcInterface) {
// create, initialize an... | 3.68 |
hbase_LruBlockCache_evictBlocksByHfileName | /**
* Evicts all blocks for a specific HFile. This is an expensive operation implemented as a
* linear-time search through all blocks in the cache. Ideally this should be a search in a
* log-access-time map.
* <p>
* This is used for evict-on-close to remove all blocks of a specific HFile.
* @return the number of ... | 3.68 |
framework_ContainerHierarchicalWrapper_removeListener | /**
* @deprecated As of 7.0, replaced by
* {@link #removePropertySetChangeListener(Container.PropertySetChangeListener)}
*/
@Override
@Deprecated
public void removeListener(Container.PropertySetChangeListener listener) {
removePropertySetChangeListener(listener);
} | 3.68 |
flink_CrossOperator_projectFirst | /**
* Continues a ProjectCross transformation and adds fields of the first cross input.
*
* <p>If the first cross input is a {@link Tuple} {@link DataSet}, fields can be selected by
* their index. If the first cross input is not a Tuple DataSet, no parameters should be
* passed.
*
* <p>Fields of the first and se... | 3.68 |
hbase_ScheduledChore_cleanup | /**
* Override to run cleanup tasks when the Chore encounters an error and must stop running
*/
protected void cleanup() {
} | 3.68 |
framework_PushMode_isEnabled | /**
* Checks whether the push mode is using push functionality.
*
* @return <code>true</code> if this mode requires push functionality;
* <code>false</code> if no push functionality is used for this
* mode.
*/
public boolean isEnabled() {
return this != DISABLED;
} | 3.68 |
hbase_CompactionConfiguration_getMinLocalityToForceCompact | /**
* @return Block locality ratio, the ratio at which we will include old regions with a single
* store file for major compaction. Used to improve block locality for regions that
* haven't had writes in a while but are still being read.
*/
public float getMinLocalityToForceCompact() {
return minL... | 3.68 |
hbase_HFileArchiveManager_disable | /**
* Disable all archiving of files for a given table
* <p>
* Inherently an <b>asynchronous operation</b>.
* @param zooKeeper watcher for the ZK cluster
* @param table name of the table to disable
* @throws KeeperException if an unexpected ZK connection issues occurs
*/
private void disable(ZKWatcher zooKee... | 3.68 |
flink_RocksDBNativeMetricOptions_enableEstimateLiveDataSize | /** Returns an estimate of the amount of live data in bytes. */
public void enableEstimateLiveDataSize() {
this.properties.add(RocksDBProperty.EstimateLiveDataSize.getRocksDBProperty());
} | 3.68 |
hbase_MasterObserver_postSetSplitOrMergeEnabled | /**
* Called after setting split / merge switch
* @param ctx the coprocessor instance's environment
* @param newValue the new value submitted in the call
* @param switchType type of switch
*/
default void postSetSplitOrMergeEnabled(final ObserverContext<MasterCoprocessorEnvironment> ctx,
final boolean n... | 3.68 |
querydsl_PathBuilder_getCollection | /**
* Create a new Collection typed path
*
* @param <A>
* @param <E>
* @param property property name
* @param type property type
* @param queryType expression type
* @return property path
*/
public <A, E extends SimpleExpression<A>> CollectionPath<A, E> getCollection(String property, Class<A> type, Class<? sup... | 3.68 |
hbase_WALSplitUtil_writeRegionSequenceIdFile | /**
* Create a file with name as region's max sequence id
*/
public static void writeRegionSequenceIdFile(FileSystem walFS, Path regionDir, long newMaxSeqId)
throws IOException {
FileStatus[] files = getSequenceIdFiles(walFS, regionDir);
long maxSeqId = getMaxSequenceId(files);
if (maxSeqId > newMaxSeqId) {
... | 3.68 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.