# Avro Schema convert to Elasticsearch mapping

**URL:** <https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438>\
**Category:** Elasticsearch\
**Created:** [March 5, 2018, 5:46am UTC](https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438 "2018-03-05T05:46:36Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![happyprg](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/happyprg/32/681_2.png) [@happyprg](https://discuss.elastic.co/u/happyprg)\
**Post date:** [March 5, 2018, 5:46am UTC](https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438/1 "2018-03-05T05:46:37Z")

</div>

I saw the below issue on this forum

> [@How to convert Avro Schema to Elastic Search Mapping?](https://discuss.elastic.co/t/how-to-convert-avro-schema-to-elastic-search-mapping/114749):
>
> How to convert Avro Schema to Elastic Search Mapping? I have Avro records in Kafka and I want to insert these records into Elastic search in JSON so I can read and also query them but before I do that I want to create a mapping for my records. I have Avro schema and I am wondering the easiest way to convert that into ElasticSearch Mapping?

So I made this project for solving it.

> **[GitHub - happyprg/AvroSchemaRegistryConvertToESMapping:...](https://github.com/happyprg/AvroSchemaRegistryConvertToESMapping)**
>
> AvroSchemaRegistryConvertToESMapping. Contribute to happyprg/AvroSchemaRegistryConvertToESMapping development by creating an account on GitHub.

 ![readme](https://us1.discourse-cdn.com/elastic/original/3X/2/c/2c1bcbe233a95a1ec95a1163fabb5dcb34a1c7fc.png)  
It has two features.  
First, you can load Avro schema using Registry API  
Secondly, you can convert Avro schema to Elasticsearch Mapping simplify

Thank you!

---

<div class="post-metadata">

**Author:** ![kant\_kodali](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kant_kodali/32/50637_2.png) [@kant\_kodali](https://discuss.elastic.co/u/kant_kodali)\
**Post date:** [March 6, 2018, 4:32pm UTC](https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438/2 "2018-03-06T16:32:13Z")

</div>

> [@happyprg](#):
>
> So I made this project for solving it.

@happyprg Where is this project? Is it open source? How can I use it?

---

<div class="post-metadata">

**Author:** ![happyprg](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/happyprg/32/681_2.png) [@happyprg](https://discuss.elastic.co/u/happyprg)\
**Post date:** [March 7, 2018, 12:51am UTC](https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438/3 "2018-03-07T00:51:08Z")

</div>

Of course.  
You can find out at here

> **[happyprg/AvroSchemaRegistryConvertToESMapping](https://github.com/happyprg/AvroSchemaRegistryConvertToESMapping)**
>
> AvroSchemaRegistryConvertToESMapping

Please use it.

2018년 3월 7일 (수) 오전 1:42, Kant Kodali [elastic@discoursemail.com](mailto:elastic@discoursemail.com)님이 작성:

---

<div class="post-metadata">

**Author:** ![happyprg](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/happyprg/32/681_2.png) [@happyprg](https://discuss.elastic.co/u/happyprg)\
**Post date:** [March 7, 2018, 12:53am UTC](https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438/4 "2018-03-07T00:53:28Z")

</div>

And if you need it. I will prepare online converter,  
Then you dont need to run application

---

<div class="post-metadata">

**Author:** ![Neelotpaul\_Roy](https://avatars.discourse-cdn.com/v4/letter/n/aca169/32.png) [@Neelotpaul\_Roy](https://discuss.elastic.co/u/Neelotpaul_Roy)\
**Post date:** [March 22, 2018, 9:23am UTC](https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438/5 "2018-03-22T09:23:25Z")

</div>

Hi @happyprg

that's a nice solution you have provided.

I have to implement something like the below and create a design. Please see if you have any inputs for this -

I want to get the schema information stored in schema registry to elastic search with out using Elastic connector provided which loads the payload from kafka to ELK.  
My use case states to move only the schema information from schema registry to Elastic search, without involving into payload from kafka to elastic search.

I am consuming schema information through REST api into registry, but how can i move the data from registry to ELK stack?

I think the above solution helps, but just wanted to understand in detail.

wam regards,  
Neelotpaul

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [April 19, 2018, 9:26am UTC](https://discuss.elastic.co/t/avro-schema-convert-to-elasticsearch-mapping/122438/6 "2018-04-19T09:26:28Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
