opensearch-sdk-java icon indicating copy to clipboard operation
opensearch-sdk-java copied to clipboard

[Extensions] Remove `routeNamePrefix` to use extensionName and update the NamedRoute regex pattern.

Open DarshitChanpura opened this issue 2 years ago • 1 comments

Coming from https://github.com/opensearch-project/opensearch-sdk-java/pull/868. Adding routeNamePrefix has a tendency to complicate the design, as a new setting is introduced. As an improvement to address this complication, a change is proposed to use extensionName as the prefix, and update the regex validation pattern in NamedRoute to also include -. Ask: Check if this is needed?

@owaiskazi19 Please update the description as necessary as you had thoughts on it.

DarshitChanpura avatar Jul 11 '23 17:07 DarshitChanpura

2.9.0 code freeze is imminent. We need to wrap up this discussion promptly and if we are relaxing NamedRoutes that needs to happen ASAP.

This whole prefix conversation is:

  • around an optional Base superclass
  • just a convenience to avoid users defining a constant somewhere and using it

If we're concerned about complicating the design can we just simply remove the prefix method?

dbwiddis avatar Jul 11 '23 17:07 dbwiddis