Skip to content

Commit

Permalink
MINOR: fix rawtype warning in StandbyTask (#17203)
Browse files Browse the repository at this point in the history
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
  • Loading branch information
mjsax committed Sep 16, 2024
1 parent f1c011a commit aaf3fc0
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@ public class StandbyTask extends AbstractTask implements Task {
private final Sensor updateSensor;
private final StreamsMetricsImpl streamsMetrics;

@SuppressWarnings("rawtypes")
protected final InternalProcessorContext processorContext;
protected final InternalProcessorContext<?, ?> processorContext;

/**
* @param id the ID of this task
Expand All @@ -61,7 +60,6 @@ public class StandbyTask extends AbstractTask implements Task {
* @param stateMgr the {@link ProcessorStateManager} for this task
* @param stateDirectory the {@link StateDirectory} created by the thread
*/
@SuppressWarnings("rawtypes")
StandbyTask(final TaskId id,
final Set<TopicPartition> inputPartitions,
final ProcessorTopology topology,
Expand All @@ -70,7 +68,7 @@ public class StandbyTask extends AbstractTask implements Task {
final ProcessorStateManager stateMgr,
final StateDirectory stateDirectory,
final ThreadCache cache,
final InternalProcessorContext processorContext) {
final InternalProcessorContext<?, ?> processorContext) {
super(
id,
topology,
Expand Down Expand Up @@ -333,11 +331,6 @@ public void addRecords(final TopicPartition partition, final Iterable<ConsumerRe
throw new IllegalStateException("Attempted to add records to task " + id() + " for invalid input partition " + partition);
}

@SuppressWarnings("rawtypes")
InternalProcessorContext processorContext() {
return processorContext;
}

/**
* Produces a string representation containing useful information about a Task.
* This is useful in debugging scenarios.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ Collection<Task> createTasks(final Map<TaskId, Set<TopicPartition>> tasksToBeCre
partitions,
stateUpdaterEnabled);

final InternalProcessorContext<Object, Object> context = new ProcessorContextImpl(
final InternalProcessorContext<?, ?> context = new ProcessorContextImpl(
taskId,
applicationConfig,
stateManager,
Expand Down Expand Up @@ -147,7 +147,7 @@ StandbyTask createStandbyTask(final TaskId taskId,
final Set<TopicPartition> inputPartitions,
final ProcessorTopology topology,
final ProcessorStateManager stateManager,
final InternalProcessorContext<Object, Object> context) {
final InternalProcessorContext<?, ?> context) {
final StandbyTask task = new StandbyTask(
taskId,
inputPartitions,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -598,7 +598,7 @@ private StandbyTask createStandbyTask() {
streamsMetrics
);

final InternalProcessorContext context = new ProcessorContextImpl(
final InternalProcessorContext<?, ?> context = new ProcessorContextImpl(
taskId,
config,
stateManager,
Expand Down

0 comments on commit aaf3fc0

Please sign in to comment.