Prevent Indexing everything

I hope someone can point out the error in my mapping. I am attempting to prevent indexing inner properties of params that are "too deep". The params property can be almost anything; the shallow properties are interesting, but the deeper ones can be ignored. The mapping I am currently using still indexes everything.

I am using version 1.7.1

Thank you

"mappings": {
    "_default_": {
        "dynamic_templates": [
                "default_deep_param": {
                    "match_pattern": "regex",
                    "match": "params\\.\\w+\\.\\w+\\..+",
                    "mapping": {
                        "index": "no"
        "_all": {
            "enabled": False
        "_source": {
            "compress": True,
            "enabled": True
        "properties": {
            "params": {
                "type": "object",
                "dynamic": True