Empty partition id causing 500 internal server error in partition feature flag implementation
If featureFlag.strategy=dataPartition
and a user makes a API call with empty data-partition-id then a 500 Internal Server Error is returned. Ideally a 4xx error should be returned in such cases where user provide incorrect input.
As per the above code, 500 internal server error is thrown because partitionProvider.get(headers.getPartitionId())
will throw a PartitionException in case of empty data-partition-id.