Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-6229

Introduce a new setting in ExceptionSettings to control whether to throw exception or log a WARN when requesting for markup id on non-renderable component

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 7.4.0
    • 8.0.0-M2, 7.5.0
    • wicket
    • None

    Description

      From dev@ (http://markmail.org/message/shqbyreferrpxv3q):

      What do you think on adding a new setting to ExceptionSettings that says whether to log a WARN (default, as it does now) or to throw exception when setOutputMarkupId/setOutputMarkupPlaceholderTag() are used on component with #setRenderBodyOnly(true) or attached to <wicket:container> ?

      I've had few occasions in the past few months where colleagues of mine use <wicket:container> and later try to update it with Ajax. The WARN log is buried amongst other logs (and developers usually simply ignore WARNs) and I see it is hard for them to find out the reason.

      If the setting proves to be useful then we can throw an exception in DEV mode and log a WARN in PROD mode.

      https://github.com/apache/wicket/blob/bec52515f1bb2570f09140ba6f457c369f3a56b1/wicket-core/src/main/java/org/apache/wicket/Component.java#L4019-L4035

      Attachments

        Issue Links

          Activity

            People

              mgrigorov Martin Tzvetanov Grigorov
              mgrigorov Martin Tzvetanov Grigorov
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: