Flink Kafka consumer SimpleStringSchema [Deprecated]

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

Flink Kafka consumer SimpleStringSchema [Deprecated]

Vijayendra Yadav
Hi Team,


new SimpleStringSchema()  --> Is showing Deprecated in my IntelliJ. Although it's working fine, Wanted to check if there is a replacement for it ?



val properties = new Properties()
properties.setProperty("bootstrap.servers", "localhost:9092")
properties.setProperty("group.id", "test")
stream = env
    .addSource(new FlinkKafkaConsumer[String]("topic", new SimpleStringSchema(), properties))

Regards,
Vijay
Reply | Threaded
Open this post in threaded view
|

Re: Flink Kafka consumer SimpleStringSchema [Deprecated]

r_khachatryan
Hi Vijay,

The javadoc for org.apache.flink.streaming.util.serialization.SimpleStringSchema says
you should Use org.apache.flink.api.common.serialization.SimpleStringSchema instead.

Regards,
Roman


On Mon, Aug 3, 2020 at 5:31 PM Vijayendra Yadav <[hidden email]> wrote:
Hi Team,


new SimpleStringSchema()  --> Is showing Deprecated in my IntelliJ. Although it's working fine, Wanted to check if there is a replacement for it ?



val properties = new Properties()
properties.setProperty("bootstrap.servers", "localhost:9092")
properties.setProperty("group.id", "test")
stream = env
    .addSource(new FlinkKafkaConsumer[String]("topic", new SimpleStringSchema(), properties))

Regards,
Vijay
Reply | Threaded
Open this post in threaded view
|

Re: Flink Kafka consumer SimpleStringSchema [Deprecated]

Vijayendra Yadav
Thank You Roman. There is one more:  env.setStateBackend

Deprecated: setStateBackend from org.apache.flink.streaming.api.scala

Regards,
Vijay

On Mon, Aug 3, 2020 at 9:21 AM Khachatryan Roman <[hidden email]> wrote:
Hi Vijay,

The javadoc for org.apache.flink.streaming.util.serialization.SimpleStringSchema says
you should Use org.apache.flink.api.common.serialization.SimpleStringSchema instead.

Regards,
Roman


On Mon, Aug 3, 2020 at 5:31 PM Vijayendra Yadav <[hidden email]> wrote:
Hi Team,


new SimpleStringSchema()  --> Is showing Deprecated in my IntelliJ. Although it's working fine, Wanted to check if there is a replacement for it ?



val properties = new Properties()
properties.setProperty("bootstrap.servers", "localhost:9092")
properties.setProperty("group.id", "test")
stream = env
    .addSource(new FlinkKafkaConsumer[String]("topic", new SimpleStringSchema(), properties))

Regards,
Vijay