Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Avro >> mail # user >> IDL protocol to programmatic API schema


Copy link to this message
-
IDL protocol to programmatic API schema
I want to declare an Client-Server (at the moment there are two ways
mentions on Avro site |NettyServer| or |HTTPServer|) app using Avro. For
that I want to define protocol using IDL files. Only thing I type in
file is IDL protocol AVDL.

*1. Now how do I read the AVDL into programmatic model?*

I found the IDLProtocolMojo
<http://avro.apache.org/docs/1.7.5/api/java/org/apache/avro/mojo/IDLProtocolMojo.html>
but all methods protected so no access. I know that I can use
|SchemaBuilder| bu it is for defining schema in code and I want to get
the |Schema| object read from AVDL definition written in hand.

I do NOT really want to use |Avro Tools| because I want the program to
do it all in code no outer commands.

*2. Can simmilar thing be done also with protocol definition displayd in
JSON in AVPR instead of IDL in AVDL?*

NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB