Skip to content

Commit

Permalink
Default Empty Map for PF configurationProperties
Browse files Browse the repository at this point in the history
The default behavior was to throw an `UnsupportedOperationException` which
effectively makes the `MockProducerFactory` unusable without subclassing,
e.g. in `spring-integration-kafka`, which calls that method to examine some
properties.

Change the default behavior to return an empty map.
  • Loading branch information
garyrussell authored Jun 8, 2023
1 parent 54601b1 commit 206e68f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ default void reset() {
* @since 2.5
*/
default Map<String, Object> getConfigurationProperties() {
throw new UnsupportedOperationException("This implementation doesn't support this method");
return Collections.emptyMap();
}

/**
Expand Down

0 comments on commit 206e68f

Please sign in to comment.