Skip to content

Commit

Permalink
Merge pull request #5994 from pferraro/WFCORE-6824
Browse files Browse the repository at this point in the history
WFCORE-6824 ServiceNameFactory.resolveServiceName(UnaryServiceDescriptor) throws ISE if resolved to a NullaryServiceDescriptor
  • Loading branch information
yersan authored May 13, 2024
2 parents cee7969 + 69b9357 commit 9814c28
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,10 @@ public static ServiceName resolveServiceName(QuaternaryServiceDescriptor<?> desc
}

private static ServiceName parseServiceName(Map.Entry<String, String[]> resolved) {
return parseServiceName(resolved.getKey()).append(resolved.getValue());
ServiceName result = parseServiceName(resolved.getKey());
String[] values = resolved.getValue();
// ServiceName.append(...) throws an ISE if called with empty array
return (values.length > 0) ? result.append(values) : result;
}

static void clearCache() {
Expand Down

0 comments on commit 9814c28

Please sign in to comment.