I'm writing some bytes to gcs and would like to use the JSON API wrappers provided by Google, but with a timeout. Currently I have this:
storage = new Storage
.Builder(GoogleNetHttpTransport...)
StorageObject storageObject = new StorageObject().setBucket(bucket).setName(path);
Storage.Objects.Insert insertObject =
storage.objects().insert(bucket, storageObject, content).setName(path);
insertObject.execute();
}
Is there a simple way to add a timeout to either CloudStorage, StorageObject or the .execute?