Using the sample code (Drive Java REST API V3) below, I am trying to download a portion of a file from google drive.
Drive.Revisions.Get get = service.revisions().get(fileId, revisionId)
.setFields(FilterConstants.OBJECT_REVISION);
MediaHttpDownloader downloader = get.getMediaHttpDownloader();
downloader.setContentRange(fromByte, toByte);
inputStream = get.executeMediaAsInputStream();
But this is not working for me. Can someone help me how to resolve this issue?
The following code works for me. The trick was to set Range header correctly
@Venkat, based on Partial download,
Range: bytes=500-999
Sample: