"Legacy Source Thread" line in logs

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

"Legacy Source Thread" line in logs

KristoffSC
Hi all,
When I run Flink from IDE i can see this prefix in logs
"Legacy Source Thread"

Running the same job as JobCluster on docker, this prefix is not present.
What this prefix means?
Btw, I'm using [1] as ActiveMQ connector.

Thanks.

[1]
https://github.com/apache/bahir-flink/tree/master/flink-connector-activemq





--
Sent from: http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/
Reply | Threaded
Open this post in threaded view
|

Re: "Legacy Source Thread" line in logs

Arvid Heise-3
Hi KristoffSC,

the short answer is: you have probably differently configured logger. They log in a different format or level.

The longer answer: all source connectors currently use the legacy source thread. That will only change with FLIP-27 [1] being widely adapted. It was originally planned to come sooner, that's why the name of the source thread contains "legacy".
Even a bit further into the details: in Flink <1.9, each task used several threads for doing things. With 1.9, all tasks now use a single thread with a mailbox model (kind of like an java.util.concurrent.Executor). However, one type of tasks couldn't be refactored: source tasks. They had to stick with the old model, because the source interfaces assume that each source connector spawns his own thread and pushes it's messages. The new interfaces with FLIP-27 will be pull-based, so that we can also use the mailbox model for that.


On Fri, Mar 27, 2020 at 12:40 PM KristoffSC <[hidden email]> wrote:
Hi all,
When I run Flink from IDE i can see this prefix in logs
"Legacy Source Thread"

Running the same job as JobCluster on docker, this prefix is not present.
What this prefix means?
Btw, I'm using [1] as ActiveMQ connector.

Thanks.

[1]
https://github.com/apache/bahir-flink/tree/master/flink-connector-activemq





--
Sent from: http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/
tuk
Reply | Threaded
Open this post in threaded view
|

Re: "Legacy Source Thread" line in logs

tuk
In reply to this post by KristoffSC
I am also observing the same in Flink 1.13.0 running in yarn.

Can someone let me know when does the log shows up?

2021-06-23T13:41:45.761Z WARN grid.task.MetricSdmStalenessUtils Legacy Source Thread - Source: MetricSource -> Filter -> MetricStoreMapper -> (Filter -> Timestamps/Watermarks -> Map -> Flat Map, Sink: FlinkKafkaProducer11, Sink: TSDBSink14) (1/1)#0 updateMetricStalenessInHisto:32 Received a non-positive staleness = -194239 at 1624455705761