name
stringlengths
12
178
code_snippet
stringlengths
8
36.5k
score
float64
3.26
3.68
flink_CheckpointConfig_setCheckpointStorage_rdh
/** * Configures the application to write out checkpoint snapshots to the configured directory. See * {@link FileSystemCheckpointStorage} for more details on checkpointing to a file system. * * @param checkpointDirectory * The path to write checkpoint metadata to. * @see #setCheckpointStorage(String) */ @Publi...
3.26
flink_CheckpointConfig_setCheckpointInterval_rdh
/** * Sets the interval in which checkpoints are periodically scheduled. * * <p>This setting defines the base interval. Checkpoint triggering may be delayed by the * settings {@link #setMaxConcurrentCheckpoints(int)} and {@link #setMinPauseBetweenCheckpoints(long)}. * * @param checkpointInterval * The checkpoi...
3.26
flink_CheckpointConfig_getMaxConcurrentCheckpoints_rdh
/** * Gets the maximum number of checkpoint attempts that may be in progress at the same time. If * this value is <i>n</i>, then no checkpoints will be triggered while <i>n</i> checkpoint * attempts are currently in flight. For the next checkpoint to be triggered, one checkpoint * attempt would need to finish or ex...
3.26
flink_CheckpointConfig_setMinPauseBetweenCheckpoints_rdh
/** * Sets the minimal pause between checkpointing attempts. This setting defines how soon the * checkpoint coordinator may trigger another checkpoint after it becomes possible to trigger * another checkpoint with respect to the maximum number of concurrent checkpoints (see {@link #setMaxConcurrentCheckpoints(int)})...
3.26
flink_CheckpointConfig_m0_rdh
/** * Sets the mode for externalized checkpoint clean-up. Externalized checkpoints will be enabled * automatically unless the mode is set to {@link ExternalizedCheckpointCleanup#NO_EXTERNALIZED_CHECKPOINTS}. * * <p>Externalized checkpoints write their meta data out to persistent storage and are ...
3.26
flink_CheckpointConfig_setMaxConcurrentCheckpoints_rdh
/** * Sets the maximum number of checkpoint attempts that may be in progress at the same time. If * this value is <i>n</i>, then no checkpoints will be triggered while <i>n</i> checkpoint * attempts are currently in flight. For the next checkpoint to be triggered, one checkpoint * attempt would need to finish or ex...
3.26
flink_CheckpointConfig_setTolerableCheckpointFailureNumber_rdh
/** * This defines how many consecutive checkpoint failures will be tolerated, before the whole job * is failed over. The default value is `0`, which means no checkpoint failures will be * tolerated, and the job will fail on first reported checkpoint failure. */ public void setTolerableCheckpointFailureNumber(int ...
3.26
flink_Tuple_getTupleClass_rdh
// -------------------------------------------------------------------------------------------- /** * Gets the class corresponding to the tuple of the given arity (dimensions). For example, * {@code getTupleClass(3)} will return the {@code Tuple3.class}. * * @param arity * The arity of the tuple class to get. *...
3.26
flink_Tuple_newInstance_rdh
// -------------------------------------------------------------------------------------------- // The following lines are generated. // -------------------------------------------------------------------------------------------- // BEGIN_OF_TUPLE_DEPENDENT_CODE // GENERATED FROM org.apache.flink.api.java.tuple.TupleGe...
3.26
flink_FirstValueWithRetractAggFunction_getArgumentDataTypes_rdh
// -------------------------------------------------------------------------------------------- // Planning // -------------------------------------------------------------------------------------------- @Override public List<DataType> getArgumentDataTypes() { return Collections.singletonList(valueDataType); }
3.26
flink_SqlUniqueSpec_symbol_rdh
/** * Creates a parse-tree node representing an occurrence of this keyword at a particular position * in the parsed text. */ public SqlLiteral symbol(SqlParserPos pos) { return SqlLiteral.createSymbol(this, pos); }
3.26
flink_InputChannel_increaseBackoff_rdh
/** * Increases the current backoff and returns whether the operation was successful. * * @return <code>true</code>, iff the operation was successful. Otherwise, <code>false</code>. */ protected boolean increaseBackoff() { // Backoff is disabled if (initialBackoff == 0) { return false; } if ...
3.26
flink_InputChannel_notifyChannelNonEmpty_rdh
/** * Notifies the owning {@link SingleInputGate} that this channel became non-empty. * * <p>This is guaranteed to be called only when a Buffer was added to a previously empty input * channel. The notion of empty is atomically consistent with the flag {@link BufferAndAvailability#moreAvailable()} when polling the n...
3.26
flink_InputChannel_checkError_rdh
// ------------------------------------------------------------------------ // Error notification // ------------------------------------------------------------------------ /** * Checks for an error and rethrows it if one was reported. * * <p>Note: Any {@link PartitionException} instances should not be transformed ...
3.26
flink_InputChannel_checkpointStarted_rdh
/** * Called by task thread when checkpointing is started (e.g., any input channel received * barrier). */ public void checkpointStarted(CheckpointBarrier barrier) throws CheckpointException { }
3.26
flink_InputChannel_setError_rdh
/** * Atomically sets an error for this channel and notifies the input gate about available data to * trigger querying this channel by the task thread. */ protected void setError(Throwable cause) { if (this.cause.compareAndSet(null, checkNotNull(cause))) { // Notify the input gate. notifyChanne...
3.26
flink_InputChannel_notifyRequiredSegmentId_rdh
/** * Notify the upstream the id of required segment that should be sent to netty connection. * * @param segmentId * segment id indicates the id of segment. */ public void notifyRequiredSegmentId(int segmentId) throws IOException { }
3.26
flink_InputChannel_checkpointStopped_rdh
/** * Called by task thread on cancel/complete to clean-up temporary data. */ public void checkpointStopped(long checkpointId) { }
3.26
flink_InputChannel_getChannelIndex_rdh
// ------------------------------------------------------------------------ // Properties // ------------------------------------------------------------------------ /** * Returns the index of this channel within its {@link SingleInputGate}. */ public int getChannelIndex() { return channelInfo.getInputChannelId...
3.26
flink_InputChannel_getChannelInfo_rdh
/** * Returns the info of this channel, which uniquely identifies the channel in respect to its * operator instance. */ public InputChannelInfo getChannelInfo() { return channelInfo;}
3.26
flink_InputChannel_unsynchronizedGetNumberOfQueuedBuffers_rdh
// ------------------------------------------------------------------------ // Metric related method // ------------------------------------------------------------------------ public int unsynchronizedGetNumberOfQueuedBuffers() { return 0; }
3.26
flink_InputChannel_getCurrentBackoff_rdh
// ------------------------------------------------------------------------ // Partition request exponential backoff // ------------------------------------------------------------------------ /** * Returns the current backoff in ms. */ protected int getCurrentBackoff() { return currentBackoff <= 0 ? 0 : currentB...
3.26
flink_DataType_getConversionClass_rdh
/** * Returns the corresponding conversion class for representing values. If no conversion class * was defined manually, the default conversion defined by the logical type is used. * * @see LogicalType#getDefaultConversion() * @return the expected conversion class */ public Class<?> getConversionClass() { ret...
3.26
flink_DataType_getFieldNames_rdh
// -------------------------------------------------------------------------------------------- // Utilities for Common Data Type Transformations // -------------------------------------------------------------------------------------------- /** * Returns the first-level field names for the provided {@link DataType}. ...
3.26
flink_DataType_getFields_rdh
/** * Returns an ordered list of fields starting from the provided {@link DataType}. * * <p>Note: This method returns an empty list for every {@link DataType} that is not a composite * type. */ public static List<DataTypes.Field> getFields(DataType dataType) { final List<String> names = getFieldNames(dataType)...
3.26
flink_DataType_performEarlyClassValidation_rdh
// -------------------------------------------------------------------------------------------- /** * This method should catch the most common errors. However, another validation is required in * deeper layers as we don't know whether the data type is used for input or output declaration. */ private static <C> Class...
3.26
flink_DataType_getFieldDataTypes_rdh
/** * Returns the first-level field data types for the provided {@link DataType}. * * <p>Note: This method returns an empty list for every {@link DataType} that is not a composite * type. */ public static List<DataType> getFieldDataTypes(DataType dataType) { final LogicalType type = dataType.getLogicalType()...
3.26
flink_BinaryArrayWriter_reset_rdh
/** * First, reset. */ @Override public void reset() { this.cursor = fixedSize; for (int i = 0; i < nullBitsSizeInBytes; i += 8) { segment.putLong(i, 0L); } this.segment.putInt(0, numElements); }
3.26
flink_BinaryArrayWriter_createNullSetter_rdh
// -------------------------------------------------------------------------------------------- /** * Creates an for accessor setting the elements of an array writer to {@code null} during * runtime. * * @param elementType * the element type of the array */public static NullSetter createNullSetter(LogicalType e...
3.26
flink_BinaryArrayWriter_complete_rdh
/** * Finally, complete write to set real size to row. */ @Override public void complete() { array.pointTo(segment, 0, cursor); }
3.26
flink_IntermediateResult_getPartitionById_rdh
/** * Returns the partition with the given ID. * * @param resultPartitionId * ID of the partition to look up * @throws NullPointerException * If partition ID <code>null</code> * @throws IllegalArgumentException * Thrown if unknown partition ID * @return Intermediate result partition with the given ID */...
3.26
flink_IntermediateResult_getConsumersParallelism_rdh
/** * Currently, this method is only used to compute the maximum number of consumers. For dynamic * graph, it should be called before adaptively deciding the downstream consumer parallelism. */ int getConsumersParallelism() { List<JobEdge> consumers = intermediateDataSet.getConsumers(); checkState(!consumers...
3.26
flink_JsonPlanEdge_fromExecEdge_rdh
/** * Build {@link JsonPlanEdge} from an {@link ExecEdge}. */ static JsonPlanEdge fromExecEdge(ExecEdge execEdge) { return new JsonPlanEdge(execEdge.getSource().getId(), execEdge.getTarget().getId(), execEdge.getShuffle(), execEdge.getExchangeMode()); }
3.26
flink_FloatValue_read_rdh
// -------------------------------------------------------------------------------------------- @Override public void read(DataInputView in) throws IOException { this.value = in.readFloat(); }
3.26
flink_FloatValue_getBinaryLength_rdh
// -------------------------------------------------------------------------------------------- @Override public int getBinaryLength() { return 4; }
3.26
flink_PojoSerializer_createRegisteredSubclassSerializers_rdh
/** * Creates an array of serializers for provided list of registered subclasses. Order of returned * serializers will correspond to order of provided subclasses. */ private static TypeSerializer<?>[] createRegisteredSubclassSerializers(LinkedHashSet<Class<?>> registeredSubclasses, ExecutionConfig executionConfig) {...
3.26
flink_PojoSerializer_getRegisteredSubclassesFromExecutionConfig_rdh
// -------------------------------------------------------------------------------------------- // Utilities // -------------------------------------------------------------------------------------------- /** * Extracts the subclasses of the base POJO class registered in the execution config. */ private static Linked...
3.26
flink_PojoSerializer_writeObject_rdh
// -------------------------------------------------------------------------------------------- private void writeObject(ObjectOutputStream out) throws IOException, ClassNotFoundException { out.defaultWriteObject(); out.writeInt(fields.length); for (Field field : fields) { FieldSerializer.serializeField(field, out); }...
3.26
flink_PojoSerializer_buildSnapshot_rdh
/** * Build and return a snapshot of the serializer's parameters and currently cached serializers. */ private static <T> PojoSerializerSnapshot<T> buildSnapshot(Class<T> pojoType, LinkedHashMap<Class<?>, Integer> registeredSubclassesToTags, TypeSerializer<?>[] registeredSubclassSerializers, Field[] fields, TypeSeri...
3.26
flink_PojoSerializer_snapshotConfiguration_rdh
// -------------------------------------------------------------------------------------------- // Serializer configuration snapshotting & compatibility // -------------------------------------------------------------------------------------------- @Override public PojoSerializerSnapshot<T> snapshotConfiguration() { re...
3.26
flink_PojoSerializer_findField_rdh
/** * Finds and returns the order (0-based) of a POJO field. Returns -1 if the field does not exist * for this POJO. */ private int findField(String fieldName) {int foundIndex = 0; for (Field field : fields) { if ((field != null) && fieldName.equals(field.getName())) { return foundIndex; } foundIndex++; } return -...
3.26
flink_PojoSerializer_createRegisteredSubclassTags_rdh
/** * Builds map of registered subclasses to their class tags. Class tags will be integers starting * from 0, assigned incrementally with the order of provided subclasses. */private static LinkedHashMap<Class<?>, Integer> createRegisteredSubclassTags(LinkedHashSet<Class<?>> registeredSubclasses) { final LinkedHash...
3.26
flink_PojoSerializer_getSubclassSerializer_rdh
/** * Fetches cached serializer for a non-registered subclass; also creates the serializer if it * doesn't exist yet. * * <p>This method is also exposed to package-private access for testing purposes. */ TypeSerializer<?> getSubclassSerializer(Class<?> subclass) { TypeSerializer<?> result = subclassSerializerCach...
3.26
flink_PojoSerializer_getPojoClass_rdh
// -------------------------------------------------------------------------------------------- // Configuration access // -------------------------------------------------------------------------------------------- Class<T> getPojoClass() { return clazz; }
3.26
flink_RunLengthDecoder_initWidthAndPacker_rdh
/** * Initializes the internal state for decoding ints of `bitWidth`. */ private void initWidthAndPacker(int bitWidth) { Preconditions.checkArgument((bitWidth >= 0) && (bitWidth <= 32), "bitWidth must be >= 0 and <= 32"); this.bitWidth = bitWidth; this.bytesWidth = BytesUtils.paddedByteCountFromBits(bitWi...
3.26
flink_RunLengthDecoder_readDictionaryIdData_rdh
/** * It is used to decode dictionary IDs. */private void readDictionaryIdData(int total, WritableIntVector c, int rowId) { int left = total; while (left > 0) { if (this.currentCount == 0) { this.readNextGroup(); } int n = Math.min(left, this.currentCount); swi...
3.26
flink_RunLengthDecoder_initFromStream_rdh
/** * Init from input stream. */ void initFromStream(int valueCount, ByteBufferInputStream in) throws IOException {this.in = in; if (fixedWidth) { // initialize for repetition and definition levels if (readLength) { int length = readIntLittleEndian(); this.in = in.sliceStre...
3.26
flink_RunLengthDecoder_readDictionaryIds_rdh
/** * Decoding for dictionary ids. The IDs are populated into `values` and the nullability is * populated into `nulls`. */ void readDictionaryIds(int total, WritableIntVector values, WritableColumnVector nulls, int rowId, int level, RunLengthDecoder data) { int left = total; while (left > 0) { if (th...
3.26
flink_RunLengthDecoder_readUnsignedVarInt_rdh
/** * Reads the next varint encoded int. */ private int readUnsignedVarInt() throws IOException { int value = 0; int v7 = 0; int b; do { b = in.read(); value |= (b & 0x7f) << v7; v7 += 7; } while ((b & 0x80) != 0 ); return value;}
3.26
flink_RunLengthDecoder_readNextGroup_rdh
/** * Reads the next group. */ void readNextGroup() { try { int header = readUnsignedVarInt(); this.mode = ((header & 1) == 0) ? MODE.RLE : MODE.PACKED; switch (mode) { case RLE : this.currentCount = header >>> 1; this.currentValue = readIntL...
3.26
flink_RunLengthDecoder_readIntLittleEndian_rdh
/** * Reads the next 4 byte little endian int. */ private int readIntLittleEndian() throws IOException { int ch4 = in.read(); int ch3 = in.read(); int ch2 = in.read(); int ch1 = in.read(); return (((ch1 << 24) + (ch2 << 16)) + (ch3 << 8)) + ch4; }
3.26
flink_RunLengthDecoder_readIntLittleEndianPaddedOnBitWidth_rdh
/** * Reads the next byteWidth little endian int. */ private int readIntLittleEndianPaddedOnBitWidth() throws IOException { switch (bytesWidth) { case 0 : return 0; case 1 : return in.read();case 2 : { int ch2 = in.read(); int ch...
3.26
flink_SimpleVersionedSerialization_readVersionAndDeSerialize_rdh
/** * Deserializes the version and datum from a byte array. The first four bytes will be read as * the version, in <i>big-endian</i> encoding. The remaining bytes will be passed to the * serializer for deserialization, via {@link SimpleVersionedSerializer#deserialize(int, * byte[])}. * * @param serializer * Th...
3.26
flink_SimpleVersionedSerialization_writeVersionAndSerializeList_rdh
/** * Serializes the version and data into a stream. * * <p>Data serialized via this method can be deserialized via {@link #readVersionAndDeserializeList(SimpleVersionedSerializer, DataInputView)}. * * <p>The first eight bytes will be occupied by the version, as returned by {@link SimpleVersionedSerializer#getVers...
3.26
flink_SimpleVersionedSerialization_writeVersionAndSerialize_rdh
/** * Serializes the version and datum into a byte array. The first four bytes will be occupied by * the version (as returned by {@link SimpleVersionedSerializer#getVersion()}), written in * <i>big-endian</i> encoding. The remaining bytes will be the serialized datum, as produced by * {@link SimpleVersionedSerializ...
3.26
flink_SimpleVersionedSerialization_readVersionAndDeserializeList_rdh
/** * Deserializes the version and data from a stream. * * <p>This method deserializes data serialized via {@link #writeVersionAndSerializeList(SimpleVersionedSerializer, List, DataOutputView)} . * * <p>The first four bytes will be interpreted as the version. The next four bytes will be * interpreted as the lengt...
3.26
flink_HiveASTParseUtils_parse_rdh
/** * Parses the Hive query. */ public static HiveParserASTNode parse(String command, HiveParserContext ctx, String viewFullyQualifiedName) throws HiveASTParseException { HiveASTParseDriver pd = new HiveASTParseDriver();HiveParserASTNode v1 = pd.parse(command, ctx, viewFullyQualifiedName); v1 = findR...
3.26
flink_KvStateSerializer_deserializeList_rdh
/** * Deserializes all values with the given serializer. * * @param serializedValue * Serialized value of type List&lt;T&gt; * @param serializer * Serializer for T * @param <T> * Type of the value * @return Deserialized list or <code>null</code> if the serialized value is <code>null</code> * @throws IOE...
3.26
flink_KvStateSerializer_deserializeMap_rdh
/** * Deserializes all kv pairs with the given serializer. * * @param serializedValue * Serialized value of type Map&lt;UK, UV&gt; * @param keySerializer * Serializer for UK * @param valueSerializer * Serializer for UV * @param <UK> * Type of the key * @param <UV> * Type of the value. * @return D...
3.26
flink_KvStateSerializer_deserializeKeyAndNamespace_rdh
/** * Deserializes the key and namespace into a {@link Tuple2}. * * @param serializedKeyAndNamespace * Serialized key and namespace * @param keySerializer * Serializer for the key * @param namespaceSerializer * Serializer for the namespace * @param <K> * Key type * @param <N> * Namespace * @retur...
3.26
flink_KvStateSerializer_m0_rdh
// ------------------------------------------------------------------------ // Generic serialization utils // ------------------------------------------------------------------------ /** * Serializes the key and namespace into a {@link ByteBuffer}. * * <p>The serialized format matches the RocksDB state backend key f...
3.26
flink_KvStateSerializer_deserializeValue_rdh
/** * Deserializes the value with the given serializer. * * @param serializedValue * Serialized value of type T * @param serializer * Serializer for T * @param <T> * Type of the value * @return Deserialized value or <code>null</code> if the serialized value is <code>null</code> * @throws IOException * ...
3.26
flink_KvStateSerializer_serializeMap_rdh
/** * Serializes all values of the Iterable with the given serializer. * * @param entries * Key-value pairs to serialize * @param keySerializer * Serializer for UK * @param valueSerializer * Serializer for UV * @param <UK> * Type of the keys * @param <UV> * Type of the values * @return Serialized...
3.26
flink_ClusterEntrypointUtils_createTaskManagerWorkingDirectory_rdh
/** * Creates the working directory for the TaskManager process. This method ensures that the * working directory exists. * * @param configuration * to extract the required settings from * @param envelopedResourceId * identifying the TaskManager process * @return working directory * @throws IOException * ...
3.26
flink_ClusterEntrypointUtils_getPoolSize_rdh
/** * Gets and verify the io-executor pool size based on configuration. * * @param config * The configuration to read. * @return The legal io-executor pool size. */ public static int getPoolSize(Configuration config) { final int poolSize = config.getInteger(ClusterOptions.CLUSTER_IO_EXECUTOR_POOL_SIZE, 4 * ...
3.26
flink_ClusterEntrypointUtils_parseParametersOrExit_rdh
/** * Parses passed String array using the parameter definitions of the passed {@code ParserResultFactory}. The method will call {@code System.exit} and print the usage * information to stdout in case of a parsing error. * * @param args * The String array that shall be parsed. * @param parserResultFactory * ...
3.26
flink_ClusterEntrypointUtils_configureUncaughtExceptionHandler_rdh
/** * Sets the uncaught exception handler for current thread based on configuration. * * @param config * the configuration to read. */ public static void configureUncaughtExceptionHandler(Configuration config) { Thread.setDefaultUncaughtExceptionHandler(new ClusterUncaughtExceptionHandler(config.get(ClusterO...
3.26
flink_ClusterEntrypointUtils_generateJobManagerWorkingDirectoryFile_rdh
/** * Generates the working directory {@link File} for the JobManager process. This method does not * ensure that the working directory exists. * * @param configuration * to extract the required settings from * @param resourceId * identifying the JobManager process * @return working directory file */ @Visi...
3.26
flink_ClusterEntrypointUtils_createJobManagerWorkingDirectory_rdh
/** * Creates the working directory for the JobManager process. This method ensures that the * working diretory exists. * * @param configuration * to extract the required settings from * @param envelopedResourceId * identifying the TaskManager process * @return working directory * @throws IOException * ...
3.26
flink_Explainable_explain_rdh
/** * Returns the AST of this object and the execution plan to compute the result of the given * statement. * * @param extraDetails * The extra explain details which the result of this method should include, * e.g. estimated cost, changelog mode for streaming * @return AST and the execution plan. */ default...
3.26
flink_MigrationUtils_skipSerializedStates_rdh
/** * Skips bytes corresponding to serialized states. In flink 1.6+ the states are no longer kept * in state. */ static void skipSerializedStates(DataInputView in) throws IOException { TypeSerializer<String> nameSerializer = StringSerializer.INSTANCE; TypeSerializer<State.StateTyp...
3.26
flink_PendingCheckpointStats_reportSubtaskStats_rdh
// ------------------------------------------------------------------------ // Callbacks from the PendingCheckpoint instance // ------------------------------------------------------------------------ /** * Reports statistics for a single subtask. * * @param jobVertexId * ID of the...
3.26
flink_PendingCheckpointStats_m0_rdh
/** * Reports a failed pending checkpoint. * * @param failureTimestamp * Timestamp of the failure. * @param cause * Optional cause of the failure. */ FailedCheckpointStats m0(long failureTimestamp, @Nullable Throwable cause) { return new FailedCheckpointStats(checkpointId, triggerTimestamp, props, number...
3.26
flink_CheckpointStatsStatus_isInProgress_rdh
/** * Returns whether the checkpoint is in progress. * * @return <code>true</code> if checkpoint is in progress, <code>false</code> otherwise. */ public boolean isInProgress() { return this == IN_PROGRESS; }
3.26
flink_WindowTrigger_triggerTime_rdh
/** * Returns the trigger time of the window, this should be called after TriggerContext * initialized. */ protected long triggerTime(W window) { return toEpochMillsForTimer(window.maxTimestamp(), ctx.getShiftTimeZone()); }
3.26
flink_Topology_getPipelinedRegionOfVertex_rdh
/** * The pipelined region for a specified vertex. * * @param vertexId * the vertex id identifying the vertex for which the pipelined region should be * returned * @return the pipelined region of the vertex * @throws IllegalArgumentException * if there is no vertex in this topology with the specified * ...
3.26
flink_FileMergingSnapshotManager_getManagedDirName_rdh
/** * Generate an unique managed directory name for one subtask. * * @return the managed directory name. */ public String getManagedDirName() { return String.format("%s_%d_%d_", operatorIDString, f0, parallelism).replaceAll("[^a-zA-Z0-9\\-]", "_"); }
3.26
flink_StreamTaskNetworkInputFactory_create_rdh
/** * Factory method for {@link StreamTaskNetworkInput} or {@link RescalingStreamTaskNetworkInput} * depending on {@link InflightDataRescalingDescriptor}. */ public static <T> StreamTaskInput<T> create(CheckpointedInputGate checkpointedInputGate, TypeSerializer<T> inputSerializer, IOManager ioManager, StatusWatermar...
3.26
flink_ProcessWindowFunction_clear_rdh
/** * Deletes any state in the {@code Context} when the Window expires (the watermark passes its * {@code maxTimestamp} + {@code allowedLateness}). * * @param context * The context to which the window is being evaluated * @throws Exception * The function may throw exceptions to fail the program and trigger r...
3.26
flink_SpeculativeExecutionVertex_isOriginalAttempt_rdh
/** * Returns whether the given attempt is the original execution attempt of the execution vertex, * i.e. it is created along with the creation of resetting of the execution vertex. */ public boolean isOriginalAttempt(int attemptNumber) { return attemptNumber == originalAttemptNumber; }
3.26
flink_SpeculativeExecutionVertex_archiveFailedExecution_rdh
/** * Remove execution from currentExecutions if it is failed. It is needed to make room for * possible future speculative executions. * * @param executionAttemptId * attemptID of the execution to be removed */ public void archiveFailedExecution(ExecutionAttemptID executionAttemptId) { if (this.f0.size() <=...
3.26
flink_AvroParquetWriters_forGenericRecord_rdh
/** * Creates a ParquetWriterFactory that accepts and writes Avro generic types. The Parquet * writers will use the given schema to build and write the columnar data. * * @param schema * The schema of the generic type. */ public static ParquetWriterFactory<GenericRecord> forGenericRecord(Schema schema) { fi...
3.26
flink_AvroParquetWriters_forReflectRecord_rdh
/** * Creates a ParquetWriterFactory for the given type. The Parquet writers will use Avro to * reflectively create a schema for the type and use that schema to write the columnar data. * * @param type * The class of the type to write. */ public static <T> ParquetWriterFactory<T> forReflectRecord(Class<T> type)...
3.26
flink_AvroParquetWriters_forSpecificRecord_rdh
/** * Creates a ParquetWriterFactory for an Avro specific type. The Parquet writers will use the * schema of that specific type to build and write the columnar data. * * @param type * The class of the type to write. */ public static <T extends SpecificRecordBase> ParquetWriterFactory<T> forSpecificRecord(Class<...
3.26
flink_ParameterTool_fromSystemProperties_rdh
/** * Returns {@link ParameterTool} from the system properties. Example on how to pass system * properties: -Dkey1=value1 -Dkey2=value2 * * @return A {@link ParameterTool} */ public static ParameterTool fromSystemProperties() { return fromMap(((Map) (System.getProperties()))); }
3.26
flink_ParameterTool_getConfiguration_rdh
// ------------------------- Export to different targets ------------------------- /** * Returns a {@link Configuration} object from this {@link ParameterTool}. * * @return A {@link Configuration} */ public Configuration getConfiguration() { final Configuration conf = new Configuration(); for (Map.En...
3.26
flink_ParameterTool_getProperties_rdh
/** * Returns a {@link Properties} object from this {@link ParameterTool}. * * @return A {@link Properties} */ public Properties getProperties() { Properties props = new Properties();props.putAll(this.f0); return props; }
3.26
flink_ParameterTool_getNumberOfParameters_rdh
// ------------------ Get data from the util ---------------- /** * Returns number of parameters in {@link ParameterTool}. */ @Override public int getNumberOfParameters() {return f0.size(); }
3.26
flink_ParameterTool_fromPropertiesFile_rdh
/** * Returns {@link ParameterTool} for the given InputStream from {@link Properties} file. * * @param inputStream * InputStream from the properties file * @return A {@link ParameterTool} * @throws IOException * If the file does not exist * @see Properties */ public static ParameterTool fromPropertiesFile...
3.26
flink_ParameterTool_createPropertiesFile_rdh
/** * Create a properties file with all the known parameters (call after the last get*() call). Set * the default value, if overwrite is true. * * @param pathToFile * Location of the default properties file. * @param overwrite * Boolean flag indicating whether or not to overwrite the file * @throws IOExcept...
3.26
flink_ParameterTool_fromArgs_rdh
// ------------------ Constructors ------------------------ /** * Returns {@link ParameterTool} for the given arguments. The arguments are keys followed by * values. Keys have to start with '-' or '--' * * <p><strong>Example arguments:</strong> --key1 value1 --key2 value2 -key3 value3 * * @param args * Input a...
3.26
flink_ParameterTool_m0_rdh
/** * Check if value is set. */ @Override public boolean m0(String value) { addToDefaults(value, null); unrequestedParameters.remove(value); return f0.containsKey(value); }
3.26
flink_ParameterTool_fromMap_rdh
/** * Returns {@link ParameterTool} for the given map. * * @param map * A map of arguments. Both Key and Value have to be Strings * @return A {@link ParameterTool} */ public static ParameterTool fromMap(Map<String, String> map) { Preconditions.checkNotNull(map, "Unable to initialize from empty map"); ...
3.26
flink_ParameterTool_get_rdh
/** * Returns the String value for the given key. If the key does not exist it will return null. */ @Override public String get(String key) { addToDefaults(key, null); unrequestedParameters.remove(key); return f0.get(key); }
3.26
flink_ParameterTool_readObject_rdh
// ------------------------- Serialization --------------------------------------------- private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException { in.defaultReadObject(); defaultData = new ConcurrentHashMap<>(f0.size()); unrequestedParameters = Collections.newSetFromMap(new ...
3.26
flink_ParameterTool_mergeWith_rdh
// ------------------------- Interaction with other ParameterUtils ------------------------- /** * Merges two {@link ParameterTool}. * * @param other * Other {@link ParameterTool} object * @return The Merged {@link ParameterTool} */ public ParameterTool mergeWith(ParameterTool other) { final Map<String, Str...
3.26
flink_ParameterTool_toMap_rdh
// ------------------------- ExecutionConfig.UserConfig interface ------------------------- @Override public Map<String, String> toMap() { return f0; }
3.26
flink_ModifyKindSet_toChangelogMode_rdh
/** * Returns the default {@link ChangelogMode} from this {@link ModifyKindSet}. */ public ChangelogMode toChangelogMode() { ChangelogMode.Builder builder = ChangelogMode.newBuilder(); if (this.contains(ModifyKind.INSERT)) { builder.addContainedKind(RowKind.INSERT); ...
3.26
flink_ModifyKindSet_minus_rdh
/** * Returns a new set of ModifyKind which is this set minus the other set, i.e. {@code this.kinds * - that.kinds}. For example: [I,U,D] minus [I] = [U,D] [I,U] minus [U,D] = [I] [I,U,D] minus * [I,U,D] = [] */ public ModifyKindSet minus(ModifyKindSet other) { Set<ModifyKind> result = EnumSet.noneOf(ModifyKi...
3.26
flink_ModifyKindSet_union_rdh
// -------------------------------------------------------------------------------------------- /** * Returns the union of a number of ModifyKindSets. */ public static ModifyKindSet union(ModifyKindSet... modifyKindSets) { Builder builder = newBuilder(); for (ModifyKindSet set : modifyKindSets) { for (ModifyKind...
3.26