Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-1702

WF Core StringBytesLengthValidator should not use error message considering characters

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Minor
    • 3.0.0.Alpha5
    • None
    • Management
    • None
    • Hide

      Add the node identifier attribute under transaction subsystem and start the server. The identifier string length is 23 but serve won't be started. If system default encoding is UTF-8.

      The identifier needs to be composed from characters e.g. U+10348 as mentioned on wikipedia page https://en.wikipedia.org/wiki/UTF-8
      (jira does not support this character to be pasted directly here)

      <core-environment node-identifier="">
      
      Show
      Add the node identifier attribute under transaction subsystem and start the server. The identifier string length is 23 but serve won't be started. If system default encoding is UTF-8 . The identifier needs to be composed from characters e.g. U+10348 as mentioned on wikipedia page https://en.wikipedia.org/wiki/UTF-8 (jira does not support this character to be pasted directly here) <core-environment node-identifier="">

    Description

      Current implementation of class StringBytesLengthValidator which is used by TransactionSubsystemRootResourceDefinition for validation of node-identifier element prints error message in format

      Caused by: javax.xml.stream.XMLStreamException: ParseError at [row,col]:[356,13]
      Message: "WFLYCTL0112: '' is an invalid value for parameter node-identifier. Values must have a maximum length of 23 characters"
      

      but the validator does not count characters of the string but bytes of the string. Then could occur if some none-ascii character are part of the node id that the string has length smaller than 23 but the message says that it's bigger.

      Attachments

        Issue Links

          Activity

            People

              chaowan@redhat.com Chao Wang
              ochaloup@redhat.com Ondrej Chaloupka (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: