Skip to content

Unsupported placeholders in messages #4624

@pavel-jares-bcm

Description

@pavel-jares-bcm

Describe the bug

There are a lot of messages in APIML that defines placeholder out of the text. The best example it this one:

- key: org.zowe.apiml.discovery.errorParsingStaticDefinitionData
number: ZWEAD702
type: WARNING
text: "Unable to process static API definition data: '%s' - '%s'"
reason: "A problem occurred while parsing a static API definition file."
action: "Review the mentioned static API definition file for errors.\n
Refer to the specific log message to determine the exact cause of the problem:\n\n
- ServiceId is not defined in the file '%s'. The instance will not be created. Make sure to specify the ServiceId.\n
- The `instanceBaseUrls` parameter of %s is not defined. The instance will not be created. Make sure to specify the `InstanceBaseUrl` property.\n
- The API Catalog UI tile ID %s is invalid. The service %s will not have an API Catalog UI tile. Specify the correct catalog title ID.\n
- One of the instanceBaseUrl of %s is not defined. The instance will not be created. Make sure to specify the InstanceBaseUrl property.\n
- The URL %s does not contain a hostname. The instance of %s will not be created. The specified URL is malformed. Make sure to specify valid URL.\n
- The URL %s does not contain a port number. The instance of %s will not be created.\n
- The specified URL is missing a port number. Make sure to specify a valid URL.\n
- The URL %s is malformed. The instance of %s will not be created: The Specified URL is malformed. Make sure to specify a valid URL.\n
- The hostname of URL %s is unknown. The instance of %s will not be created: The specified hostname of the URL is invalid. Make sure to specify a valid hostname.\n
- Invalid protocol. The specified protocol of the URL is invalid. Make sure to specify valid protocol.\n
- Additional service metadata of %s in processing file %s could not be created: %s"

These values would be definitelly helpfull for customers, but the message does not support replacement placeholder out of text field.

These values looks for customer like an error.

Simply solution is to replace these messages with a text (without a real value). The best solution is to add support to messages and set all required argmuents in each code that generates the message.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    Unplanned Bugs

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions