Hello everyone,

I am new to the avro-c library, and trying to get some experience with it. At the moment, I wrote a very simple program that is supposed to write a single record of a simple schema to a file.

The program source is over there: https://gist.github.com/titouanc/0df61b807d06ca7611cc6708f12fc938.

When I run my program, I obtain the following output:

Unable to write Avro record to file: Datum too large for file block size

which is produced by https://gist.github.com/titouanc/0df61b807d06ca7611cc6708f12fc938#file-test-avro-c-L34 . The only reference to a similar error message is http://apache-avro.679487.n3.nabble.com/Value-too-large-for-file-block-size-td4028424.html but i really doubt I have the same issue, as the size of my record should be much more lower than 16kiB.


To write this small piece of code, I draw inspiration from the quickstop example (https://github.com/apache/avro/blob/release-1.9.1/lang/c/examples/quickstop.c). If I compile and run this example, it runs just fine.


Finally, I made a small modification to my program to use the same schema as the quickstop example. Here is the modified version: https://gist.github.com/titouanc/b18c0c54657db4e1f0361e0be9f710f3.
This one actually works perfectly !


Could anyone help me to understand this issue ?

Best regards,

Titouan Christophe

Reply via email to