File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ TusClient client = new TusClient();
18
18
19
19
// Configure tus HTTP endpoint. This URL will be used for creating new uploads
20
20
// using the Creation extension
21
- client. setUploadCreationURL(new URL (" http ://master.tus.io/files" ));
21
+ client. setUploadCreationURL(new URL (" https ://master.tus.io/files" ));
22
22
23
23
// Enable resumable uploads by storing the upload URL in memory
24
24
client. enableResuming(new TusURLMemoryStore ());
@@ -42,6 +42,13 @@ TusExecutor executor = new TusExecutor() {
42
42
// upload and get a TusUploader in return. This class is responsible for opening
43
43
// a connection to the remote server and doing the uploading.
44
44
TusUploader uploader = client. resumeOrCreateUpload(upload);
45
+
46
+ // Alternatively, if your tus server does not support the Creation extension
47
+ // and you obtained an upload URL from another service, you can instruct
48
+ // tus-java-client to upload to a specific URL. Please note that this is usually
49
+ // _not_ necessary and only if the tus server does not support the Creation
50
+ // extension. The Vimeo API would be an example where this method is needed.
51
+ // TusUploader uploader = client.beginOrResumeUploadFromURL(upload, new URL("https://tus.server.net/files/my_file"));
45
52
46
53
// Upload the file in chunks of 1KB sizes.
47
54
uploader. setChunkSize(1024 );
You can’t perform that action at this time.
0 commit comments