Code Room
Code reviewHard
Question
Review this Java client. `paymentClient` internally retries 3 times with 1s backoff (up to ~4s) before giving up.
What a strong answer looks like
Separate real bugs from style. Rank issues by severity, point at the root cause rather than the symptom, and suggest a concrete fix — specific and kind.
Learn the concepts
Future<ChargeResult> f = executor.submit(() -> paymentClient.charge(req));try { return f.get(1, TimeUnit.SECONDS);} catch (TimeoutException e) { f.cancel(true); return retryCharge(req); // our own retry: submit again, get(1s) again}Run or narrate your approach, then ask the coach.