LoggableException extends RuntimeException implements LoggableKeysAndValues<LoggableException> { @Nonnull @Override public LoggableException addLogInfo(@Nonnull String description, Object object) { loggableKeysAndValuesImpl.addLogInfo(description, object); return this; } LoggableException(@Nonnull String msg, @Nullable Object ... keyValues);  LoggableException(Throwable cause);  LoggableException(@Nonnull String msg, @Nullable Throwable cause);  LoggableException(@Nonnull String msg); @Nonnull @Override Map<String, Object> getLogInfo(); @Nonnull @Override LoggableException addLogInfo(@Nonnull String description, Object object); @Nonnull @Override LoggableException addLogInfo(@Nonnull Object ... keyValue); @Nonnull @Override Object[] exportLogInfo();  }
@Test public void oddLogInfoValues() { assertThrows(IllegalArgumentException.class, () -> new LoggableException("odd number of log info!", "k1", "v1", "k2")); assertThrows(IllegalArgumentException.class, () -> new LoggableException("odd in call!").addLogInfo("k1", "v1", "k2")); }