Use yml in java spring boot to map map cannot be fetched through Environment environment

yml is described as follows

application:
   address:
    "0xb7716e1f5690a841d698dd64ae13727bf719b2cd": "4"
    "0x0f020200ad0729f19be98ddb26685d80359428b7": "5"

by injecting

into the springboot project
  import org.springframework.core.env.Environment;
  @Autowired
  Environment environment;


 Map<String,String> maps = environment.getProperty("application.address",Map.class);

it is fetched through environment in the method. If it returns null, what should I do?

Mar.19,2021

answer your own questions

in this case, you can only use @ ConfigurationProperties ("application") to fetch
and configure a member variable to receive

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e8a34d-5bdd6.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e8a34d-5bdd6.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?