Root mapping definition has unsupported parameters (mapper_parsing_exception)

I am new to elasticsearch and I am stucked in a problem from couple of days. I have tried different solution provided on stackoverflow ES forum and other websites but they didn't work for me that's why I am posting this question. I am really sorry for the duplicate.

I am trying to add tokenizer": "uax_url_email" so that i can easily search email with query.

But when I am setting the mapping it Elastic Search is giving me this error Root mapping definition has unsupported parameters (mapper_parsing_exception)

I have tried to delete the index and recreate it but it also didn' help.

My mapping link.

http://localhost:9200/users/user/_mapping

My mappings

{
"settings": {
            "analysis": {
                "analyzer": {
                    "urls-links-emails": {
                        "type": "custom",
                        "tokenizer": "uax_url_email"
                    }
                }
            }
        },
        "mappings":{
            "user": {
                "properties": {
                    "id" : {"type": "long"},
                    "first_name" : {"type": "text"},
                    "middle_name" : {"type": "text"},
                    "last_name" : {"type": "text"},
                    "full_name" : {"type": "text"},
                    "image" : {"type": "text"},
                    "email" : {"type": "text", "analyzer": "urls-links-emails"},
                    "mobile_number" : {"type": "text"},
                    "profile_image" : {"type": "text"},
                    "thumbnail" : {"type": "text"},
                    "role" : {"type": "text"},
                    "role_id" : {"type": "byte"},
                    "joined_date" : {"type": "date", "format": "yyyy-MM-dd HH:mm:ss"},
                    "updated_date" : {"type": "date", "format": "yyyy-MM-dd HH:mm:ss"}
                }
            }
        }
    }

This is the error

{
    "error": {
        "root_cause": [
            {
                "type": "mapper_parsing_exception",
                "reason": "Root mapping definition has unsupported parameters:  [settings : {analysis={analyzer={urls-links-emails={type=custom, tokenizer=uax_url_email}}}}] [mappings : {user={properties={id={type=long}, first_name={type=text}, middle_name={type=text}, last_name={type=text}, full_name={type=text}, image={type=text}, email={type=text, analyzer=urls-links-emails}, mobile_number={type=text}, profile_image={type=text}, thumbnail={type=text}, role={type=text}, role_id={type=byte}, joined_date={type=date, format=yyyy-MM-dd HH:mm:ss}, updated_date={type=date, format=yyyy-MM-dd HH:mm:ss}}}}]"
            }
        ],
        "type": "mapper_parsing_exception",
        "reason": "Root mapping definition has unsupported parameters:  [settings : {analysis={analyzer={urls-links-emails={type=custom, tokenizer=uax_url_email}}}}] [mappings : {user={properties={id={type=long}, first_name={type=text}, middle_name={type=text}, last_name={type=text}, full_name={type=text}, image={type=text}, email={type=text, analyzer=urls-links-emails}, mobile_number={type=text}, profile_image={type=text}, thumbnail={type=text}, role={type=text}, role_id={type=byte}, joined_date={type=date, format=yyyy-MM-dd HH:mm:ss}, updated_date={type=date, format=yyyy-MM-dd HH:mm:ss}}}}]"
    },
    "status": 400
}

Thanks for help

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