1
0
mirror of https://github.com/chylex/Nextcloud-Desktop.git synced 2024-11-28 18:42:46 +01:00
Commit Graph

387 Commits

Author SHA1 Message Date
Olivier Goffart
1753ce651b Virtual Files: Allow to download a folder recursively from the socket API
Issue: #6466
2018-05-30 11:57:57 +02:00
Christian Kamm
3a7a6b0b9e Virtual files: Wipe virtual after download completes, not before
Otherwise a interrupted or unsuccessful download would mean that the
download-intend was forgotten. The next sync would reestablish the
virtual file instead.
2018-05-30 11:50:14 +02:00
Christian Kamm
252484e875 Virtual files: Only remove virtual file once on download
With thanks to @ogoffart for spotting the problem.
2018-05-30 10:39:49 +02:00
Christian Kamm
8f9f2b5462 Rename Placeholders to Virtual Files in code #6531 2018-05-23 09:57:00 +02:00
Christian Kamm
394ef439e0 Merge branch 'master' into 2.5 2018-05-17 13:23:20 +02:00
Olivier Goffart
e7e8a62bb7 Blacklist: remember the X-Request-ID
Issue #6420
Store the X-Request-ID in the SyncFileItem and also in the blacklist.
Note that for consistency reason, the X-Request-ID is also in the
SyncFileItem if the request succeeds.

Currently there is no UI to access it, but it can be queried with sql
commands
2018-05-15 18:11:01 +02:00
Christian Kamm
8d14f4357a Placeholder: Stop adding ignore pattern
Because we can't make older clients preserve the version directive that
was attached to it.

See #6504 and #6498
2018-05-15 14:26:35 +02:00
Christian Kamm
34d40e6c67 Placeholder: Don't contain "stub" 2018-05-15 14:26:35 +02:00
Christian Kamm
8b952d3741 TestChunkingNG: Remove unneeded test code 2018-05-15 09:42:54 +02:00
Christian Kamm
9555f8d75c Show a tray message when a folder watcher becomes unreliable #6119 2018-04-24 13:06:50 +02:00
Olivier Goffart
c5701f635a Fix test: QTemporaryDir::filePath was added in Qt 5.9 2018-04-19 17:01:31 +02:00
Christian Kamm
a5271b529b LocalDiscoveryTracker: Add unit test #6120 2018-04-19 10:58:46 +02:00
Christian Kamm
7c558394c1 LocalDiscoveryTracker: Separate from Folder and move to libsync
To allow relevant code to be closer together and for testing in
unittests without having to get a gui Folder.

See #6120
2018-04-19 10:58:46 +02:00
Christian Kamm
985a657f48 Merge remote-tracking branch 'origin/master' 2018-04-18 11:14:08 +02:00
Christian Kamm
9e8464e114 Merge branch 'placeholder-prototype' 2018-04-18 11:02:53 +02:00
Olivier Goffart
02b818af04 Download: Use the <s:message> from the reply in the error message if any
Issue: #6459
2018-04-18 10:57:16 +02:00
Olivier Goffart
0fdfb2cba3 Add a test for resuming downloads 2018-04-18 10:57:16 +02:00
Christian Kamm
65a2b1aa8a Placeholders: Fix migration issues
Some edgecases weren't covered and didn't have tests yet.
2018-04-18 10:27:51 +02:00
Christian Kamm
c2f84d7c3e Placeholders: Ignore placeholder files in older clients
To do this, we add the placeholder extension to the user exclude file
automatically. However, newer clients shouldn't use that exclude
pattern: so we also add version directives that allow making exclude
patterns dependent on the client version.
2018-04-18 10:27:51 +02:00
Christian Kamm
01bb241e48 Placeholders: Safe migration to older client versions
Now the db entries for placeholders will have the full placeholder
paths. That way older clients will, on remote discovery, delete the
placeholders and download the real files.
2018-04-18 10:27:51 +02:00
Christian Kamm
e2f2c9a153 Placeholders: Deal with conflicts when a placeholder exists
So "foo.owncloud" exists but the user adds a new "foo".
2018-04-18 10:27:51 +02:00
Olivier Goffart
a2191474eb Placeholders: Move the placeholder option from the account to the folder 2018-04-18 10:27:51 +02:00
Christian Kamm
798e60c9f6 On-demand downloading: Placeholder-file based prototype
- Controled by an option.
- New remote files start out as ItemTypePlaceholder, are created with a
  .owncloud extension.
- When their db entry is set to ItemTypePlaceholderDownload the next
  sync run will download them.
- Files that aren't in the placeholder state sync as usual.
- See test cases in testsyncplaceholders.

Missing:
- User ui for triggering placeholder file download
- Maybe: Going back from file to placeholder?
2018-04-18 10:27:51 +02:00
Christian Kamm
fa6ac9da23 Upload: Add more chunk resuming unit tests #6405 2018-04-17 13:48:13 +02:00
Olivier Goffart
2c18ea0a89 Uploads: Don't delete unexisting chunks
Since commit 4dc49ff3, we store an entry in the upload info table even
for non chunked uploads. However, if this fails we don't want to remove
non-existant stale chunks if the upload fails.

Without this commit, we would send a DELETE command to clean non-existant
chunks in the dav/uploads/ namespace.
2018-04-16 12:00:12 +02:00
Christian Kamm
afec3ccf6e Conflicts: Change tags to be more user friendly #6365
From "_conflict-user-yyyymmdd-hhmmss"
to   " (conflicted copy user yyyy-mm-dd hhmmss)"
2018-04-03 14:03:03 +02:00
Christian Kamm
28f68369be Blacklist: Add unittest #6411 2018-03-28 11:25:32 +02:00
Christian Kamm
25deaed9e5 Excludes: Expand doc, Desktop.ini only in root folder
The Desktop.ini exclude was added for 2.4 because we add such a file to
the synced folder on Windows. It doesn't need to cover subdirectories.
2018-03-27 12:43:53 +02:00
Olivier Goffart
0bf0f92949 OwnSql: Fixup after feedback for #6388 2018-03-15 19:30:21 +01:00
Olivier Goffart
978a129eed csync: Simplify csync_walk_local_tree/csync_walk_remote_tree
Small refactoring
2018-03-14 10:25:45 +01:00
Christian Kamm
86b30e36c2 Merge remote-tracking branch 'origin/2.4' 2018-03-12 10:24:25 +01:00
Christian Kamm
f82d61ea19 SyncEngine: Make "local discovery?" question available
Also fix the minor bug that was mentioned and add tests.
2018-03-06 13:02:54 +01:00
Olivier Goffart
22c7002d59 Move ClientProxy and ConnecitonValidator to gui
They are using the ConfigFile and are used to control
when to sync rather than for the sync itself
2018-02-26 16:11:46 +01:00
Olivier Goffart
7897b386b6 Utility::fsCasePreserving: remove UNIT_TESTING ifdef
Since the release package will be build with unit test, we don't
want to query the env variable at every call to fsCasePreserving.
So only test the env variable at startup.
And the testutility can still change the value.

(The env variable is still used from t8.pl and maybe smashbox)

Issue #6318
2018-02-21 11:28:31 +01:00
Markus Goetz
6f8248ebfd test/testsyncengine: testNoLocalEncoding is for Linux 2018-02-20 11:26:11 +01:00
Christian Kamm
ed2dfcf399 Conflicts with user name: Fix tests 2018-02-20 10:36:07 +01:00
Christian Kamm
6fc3bfc265 Conflicts: Add user name to conflict file name #6325
For the case of uploading conflict files only.
2018-02-20 10:10:34 +01:00
Christian Kamm
4a47f7e438 Merge remote-tracking branch 'origin/2.4' 2018-02-16 10:17:19 +01:00
Christian Kamm
73062e21a3 SyncJournal: Don't use LIKE with paths
Paths can contain the wildcards % and _ and that would lead to odd
behavior.

This patch also clarifies the behavior of avoidReadFromDbOnNextSync()
which previously dependend on whether "foo/bar" or "foo/bar/" was
passed as input.

Possibly affects #6322
2018-02-15 09:56:43 +01:00
Christian Kamm
e2b89c5afe TextXmlParse: Add truncated-xml testcase #6317 2018-01-22 14:05:08 +01:00
Christian Kamm
b9c7aa8df3 Sync: Deal with file/folder conflicts #6312
Previously conflicts with a different type on both ends lead to sync
errors. Now they are handled in the expected way: the local item gets
renamed and the remote item gets propagated downwards.

This also adds a unittest for the TYPE_CHANGE case. That one looks like
parts of it might be unified with CONFLICT cases.
2018-01-19 09:47:49 +01:00
Christian Kamm
4337e8532e Exclude matching: Speedup the full-path traversal case
Previously we'd use the full regex when the bname triggered a full-path
matching to take place. Now we have a simplified full-traversal regex
for this case that can be significantly faster to apply.

Triggered by #5017 but doesn't actually solve it.
2018-01-17 15:05:50 +01:00
Olivier Goffart
437d45981e Remove unused c_strlist 2018-01-13 13:58:17 +01:00
Olivier Goffart
3ae327ea8e Modernize out CMakeLists.txt
Mainly uses target_include_directories instead of include_directories
so libraries public include directory get automatically added when adding
the target in target_link_library
2018-01-13 13:58:17 +01:00
Olivier Goffart
5d0aa5f039 Remove unused c_path 2018-01-13 13:58:17 +01:00
Olivier Goffart
3ddd4b6f16 Get rid of csync_log
We use Qt's debugging code everywhere
2018-01-13 13:58:17 +01:00
Olivier Goffart
d948ed11a1 Csync: use QElapsedTimer and qCInfo instead of CSYNC_LOG and its own csync time function
This allow to remove all the csync time manipulation routne which are now unused
2018-01-13 13:58:17 +01:00
Olivier Goffart
257d8142b1 Build system: Get rid of QtVersionAbstraction.cmake
Use modern cmake with target_link_libraries and Qt5:: that
automatically add the include path and compile flags
2018-01-13 13:58:17 +01:00
Olivier Goffart
776bbbf7b1 Don't include sqlite3.h from headers
So that sqlite is not part of the public interface of csync
(and that the sqlite include path don't need to be passed when compiling
libsync or gui)
2018-01-13 13:58:17 +01:00
Olivier Goffart
9613f6437d Merge remote-tracking branch 'origin/2.4'
Conflicts:
	src/libsync/networkjobs.cpp
2018-01-11 10:46:50 +01:00