In recent ClickHouse versions (21.3) Avro format for kafka does not work at all.
In ClickHouse 20.3 one Avro formatted kafka message can read, than stall forever.
Reportedly in ClickHouse prior 20.3 Avro formatted kafka messages work Ok while contain only single record
{
    factory.registerInputFormatProcessor("Avro", [](
        ReadBuffer & buf,
        const Block & sample,
        const RowInputFormatParams & params,
        const FormatSettings & settings)
    {
        return std::make_shared<AvroRowInputFormat>(sample, buf, params, settings);
    });
    factory.registerInputFormatProcessor("AvroConfluent",[](
        ReadBuffer & buf,
        const Block & sample,
        const RowInputFormatParams & params,
        const FormatSettings & settings)
    {
        return std::make_shared<AvroConfluentRowInputFormat>(sample, buf, params, settings);
    });
}
}
#else
namespace DB
{
class FormatFactory;
void registerInputFormatProcessorAvro(FormatFactory &)
{
}
}
#endif