question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Allow to fetch multiple config parameters as a Map

See original GitHub issue

Description

As a:

  • Application user/user of the configuration itself
  • API user (application developer)
  • SPI user (container or runtime developer)
  • Specification implementer

…I need to be able to: fetch multiple configuration parameters with same type as a Map

@ConfigProperty("my.prefix")
Map<String, String> configs

or fetch multiple configuration parameters with different type as a scoped Config

@ConfigProperty("my.prefix")
Config configs

…which enables me to:

Avoid the more generic

@inject
Config config

config.getValue("my.prefix." + myDynamicKey, String.class)
``

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:2
  • Comments:18 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
rmanibuscommented, Aug 31, 2022

@radcortez I would be happy to work on it. I’m not sure about what need to be included in this PR: documentation, tck and that’s it ?

1reaction
radcortezcommented, Aug 29, 2022

It is unlikely that this will be added to MP Config, since most of the effort is in Jakarta Config (which will take a while). Anyway, if anyone in the community wants to work on it, I’m happy to review it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Correct way to pass multiple values for same parameter name ...
Most applications use the first option you have shown: http://server/action?id=a&id=b .
Read more >
How to make multiple values per key in a Java map possible ...
Need to add multiple values to a key in a Java HashMap but can't figure out how to do it? Here are three...
Read more >
ConfigMaps - Kubernetes
A ConfigMap is an API object used to store non-confidential data in key-value pairs. Pods can consume ConfigMaps as environment variables, ...
Read more >
git-fetch Documentation - Git
Keep downloaded pack. --multiple. Allow several <repository> and <group> arguments to be specified. No <refspec>s may be specified.
Read more >
ConfigMaps | Developer Guide - OpenShift Documentation
Many applications require configuration using some combination of ... syntax that allows literal values to be supplied directly on the command line:.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found