[Java] Improve response and error handling from server.
This improves/fixes a couple of things:
It's possible for the server to reply with a 207 (multi-status) code, which implies that one or more events in the batch might have been improperly formatted. Let's handle this condition in the same way we handle actual errors (400 and above).
In addition, when sending events, the EventProcessor only catches IOExceptions, when in fact there might be other types of exceptions that come from the EventSender. If an uncaught exception reaches the Executor that is running the sending task, the executor might not run the task again, causing events to stop being sent altogether for the remainder of the VM lifecycle. Even though catching all exceptions is a Bad Thing, in this rare case catching everything is actually beneficial and will help us track down problems easier.
Bug: T353680