DeltaSpike
  1. DeltaSpike
  2. DELTASPIKE-114

@ConfigProperty based on ConfigResolver

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.1-incubating
    • Fix Version/s: 0.2-incubating
    • Component/s: Core
    • Labels:
      None

      Description

      example:
      @Produces
      public MyBean produceMyBean(@ConfigProperty("propertyA") String propertyA, @ConfigProperty("propertyB") String propertyB)
      //...
      }

      we have an agreement for it ( http://s.apache.org/mlW )

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open In Progress In Progress
        4m 26s 1 Gerhard Petracek 07/Mar/12 21:40
        In Progress In Progress Resolved Resolved
        32d 23h 58m 1 Gerhard Petracek 09/Apr/12 22:38
        Resolved Resolved Closed Closed
        12d 17h 45m 1 Mark Struberg 22/Apr/12 16:23
        Mark Struberg made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Hide
        Mark Struberg added a comment -

        shipped in deltaspike-0.2-incubating

        Show
        Mark Struberg added a comment - shipped in deltaspike-0.2-incubating
        Gerhard Petracek made changes -
        Status In Progress [ 3 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Gerhard Petracek made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        Gerhard Petracek made changes -
        Field Original Value New Value
        Description @Produces
        public MyBean produceMyBean(@ConfigProperty("propertyA") String propertyA, @ConfigProperty("propertyB") String propertyB)
          //...
        }
        example:
        @Produces
        public MyBean produceMyBean(@ConfigProperty("propertyA") String propertyA, @ConfigProperty("propertyB") String propertyB)
          //...
        }

        we have an agreement for it ( http://s.apache.org/mlW )
        Hide
        Gerhard Petracek added a comment -

        optional support for:

        @ConfigProperty(name = "pool_size", eager = true, converter = StringToIntegerConverter.class)
        public @interface PoolSize
        {
        }

        @Inject
        @PoolSize
        private int configuredPoolSize;

        eager should be true by default -> the configured value gets converted during bootstrapping (if the value has an invalid format the bootstrapping process fails).
        if eager is false, the configured value will be converted directly before the injection (e.g. for values stored in dynamic config-sources).

        Show
        Gerhard Petracek added a comment - optional support for: @ConfigProperty(name = "pool_size", eager = true, converter = StringToIntegerConverter.class) public @interface PoolSize { } @Inject @PoolSize private int configuredPoolSize; eager should be true by default -> the configured value gets converted during bootstrapping (if the value has an invalid format the bootstrapping process fails). if eager is false, the configured value will be converted directly before the injection (e.g. for values stored in dynamic config-sources).
        gonzalad created issue -

          People

          • Assignee:
            Gerhard Petracek
            Reporter:
            gonzalad
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development