question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Value deserialization error: Method not found..

See original GitHub issue

Description

I am using consumer with schema registry to consume Avro data. I am using AvroDeserializer to desrialize the data. It was working fine and suddenly it started showing this error:

InnerException = {"Method not found: 'System.Threading.Tasks.Task1<System.String> Confluent.SchemaRegistry.ISchemaRegistryClient.GetSchemaAsync(Int32)'."}

Message = “Local: Value deserialization error”

StackTrace = " at Confluent.Kafka.Consumer2.Consume(Int32 millisecondsTimeout)\r\n at Confluent.Kafka.Consumer2.Consume(CancellationToken cancellationToken)\r\n `

This my consumer: ` using (var schemaRegistry = new CachedSchemaRegistryClient(schemaRegistryConfig)) using (var consumer = new ConsumerBuilder<string, Order>(consumerConfig) .SetValueDeserializer(new AvroDeserializer<Order>(schemaRegistry).AsSyncOverAsync()) .SetErrorHandler((_, e) => Console.WriteLine($“Error: {e.Reason}”)) .Build()) { consumer.Subscribe(“topic”);

            try
            {
                while (true)
                {
                    try
                    {
                        var consumeResult = consumer.Consume(cts.Token);
                        Console.WriteLine(consumeResult.Value.ToString());
                    }
                    catch (ConsumeException e)
                    {
                        Console.WriteLine($"Consume error: {e.Error.Reason}");
                    }
                }
            }
            catch (OperationCanceledException)
            {
                consumer.Close();
            }
        }`

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:2
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

7reactions
mhowlettcommented, Apr 9, 2020

https://www.nuget.org/packages/Confluent.SchemaRegistry.Serdes.Avro/

Confluent.SchemaRegistry 1.4 and Confluent.SchemaRegistry.Serdes 1.3 are not compatible - the error you are seeing is expected.

0reactions
AliYussefcommented, Apr 9, 2020

@mhowlett Thanks, everything works fine now. I will close the issue since it is solved. Using Confluent.SchemaRegistry.Serdes.Avro insted of Confluent.SchemaRegistry.Serdes solved the problem.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Confluent.Schema.Registry .NET Avro Deserialization Error
I currently have a netcore 2.0 console application that produces Avro messages, however when I attempt to consume them, the deserializer is ...
Read more >
How to handle deserialization errors using ksqlDB
In this tutorial, learn how to handle deserialization errors in a stream of events using ksqlDB, with step-by-step instructions and examples.
Read more >
SerializationException: There was an error deserializing ...
This error means the response is HTML not JSON. Use the Visual Studio debugger to physically read the response. It could be an...
Read more >
Jackson Exceptions - Problems and Solutions
Finally, we'll briefly discuss Jackson “No such method” errors. ... JsonMappingException: Cannot Deserialize Value of Type java.lang.
Read more >
Apache Kafka Reference Guide
Reactive Messaging invokes your method on an I/O thread. See the Quarkus Reactive ... By default, it deduces the serializer from the value...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found