{"action":"opened","issue":{"url":"https://api.github.com/repos/micronaut-projects/micronaut-core/issues/776","repository_url":"https://api.github.com/repos/micronaut-projects/micronaut-core","labels_url":"https://api.github.com/repos/micronaut-projects/micronaut-core/issues/776/labels{/name}","comments_url":"https://api.github.com/repos/micronaut-projects/micronaut-core/issues/776/comments","events_url":"https://api.github.com/repos/micronaut-projects/micronaut-core/issues/776/events","html_url":"https://github.com/micronaut-projects/micronaut-core/issues/776","id":373591384,"node_id":"MDU6SXNzdWUzNzM1OTEzODQ=","number":776,"title":"Issue with binding a property of type Map<String, Map<>> ","user":{"login":"celcius112","id":1503748,"node_id":"MDQ6VXNlcjE1MDM3NDg=","avatar_url":"https://avatars1.githubusercontent.com/u/1503748?v=4","gravatar_id":"","url":"https://api.github.com/users/celcius112","html_url":"https://github.com/celcius112","followers_url":"https://api.github.com/users/celcius112/followers","following_url":"https://api.github.com/users/celcius112/following{/other_user}","gists_url":"https://api.github.com/users/celcius112/gists{/gist_id}","starred_url":"https://api.github.com/users/celcius112/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/celcius112/subscriptions","organizations_url":"https://api.github.com/users/celcius112/orgs","repos_url":"https://api.github.com/users/celcius112/repos","events_url":"https://api.github.com/users/celcius112/events{/privacy}","received_events_url":"https://api.github.com/users/celcius112/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-10-24T17:23:17Z","updated_at":"2018-10-24T17:23:17Z","closed_at":null,"author_association":"NONE","body":"### Steps to Reproduce\r\n\r\nWhen trying to bind a property of type `Map<String, Map<>>`, the inner Map type is lost at runtime. It becomes  a simple `LinkedHashMap`. \r\n\r\n### Expected Behaviour\r\n\r\nHere, I expect my Map value to be type-safe, and that a Map as value be possible with any types (see my example project for a more complex type).\r\n\r\n### Actual Behaviour\r\n\r\nGiven a property:\r\n```java\r\nprivate Map<String, Map<String, Integer>> myMap = new HashMap<>();\r\n```\r\nand a configuration file with property:\r\n```yaml\r\n  map:\r\n    key:\r\n      key2: \"test\"\r\n```\r\nmy field `myMap` will have an entry whose value is of type `Map<String, String>`.  \r\n\r\n### Environment Information\r\n\r\n- **Operating System**: MacOS\r\n- **Micronaut Version:** 1.0.0\r\n- **JDK Version:** 8\r\n\r\n### Example Application\r\n\r\nI have a more complex example [here](https://github.com/celcius112/micronaut-binding-map). Please refer to the unit test in `PropertiesTest`.\r\n\r\n"}}
{"actor":{"display_login":"celcius112"}}