Commit Graph

5859 Commits

Author SHA1 Message Date
Olivier Goffart
dfdcd3ff54 Move: Fix move detection in directory move on the other side 2019-01-22 08:14:12 +01:00
Olivier Goffart
8407f8b9e6 Move: add comments and tests 2019-01-22 08:14:12 +01:00
Olivier Goffart
303922b80f Move: add more test and fix move within moves 2019-01-22 08:14:12 +01:00
Olivier Goffart
a4990c0a85 Rename: fix renamed folder moved into renamed folder issue
Issue #6694
2019-01-22 08:14:12 +01:00
Christian Kamm
f0fb15fecb vfs: Update pinning context menu to be less confusing
Seeing "Currently available online only" for a currently hydrated file
was odd. It makes sense since current hydration status and pin state are
independent.

The new text will say something like "Currently available, but marked
online only" to better indicate that the file might be dehydrated later
since it wasn't pinned.
2019-01-18 11:16:43 +01:00
Christian Kamm
1b594102c7 Vfs: Switch on/off only when sync isn't running #6936
Avoids some situations that might cause data loss.
2019-01-18 11:16:14 +01:00
Christian Kamm
c4c5e4e14c Folder: Add selective sync / ui related flags
supportsSelectiveSync(): clearer than !supportsVirtualFiles() and allows
  extra logic

isVfsOnOffSwitchPending(): Somewhat awkward way of dealing with the
  phase between a user requesting vfs state to be switched and it
  actually happening
2019-01-18 11:16:14 +01:00
Christian Kamm
c5705de4cc SyncEngine: Rename phase finishing slots
slotDiscoveryJobFinished -> slotDiscoveryFinished
slotFinished -> slotPropagationFinished

This should be clearer. Particular the
slotFinished -> finalize -> emit finished()
chain was confusing before.
2019-01-18 11:16:14 +01:00
Christian Kamm
28dcceb3e4 Discovery: Fix aborting during discovery #6972 2019-01-18 11:16:14 +01:00
Christian Kamm
90a8eaa949 vfs suffix: Ignore server files or synced files with the suffix #6953 2019-01-18 11:03:01 +01:00
Christian Kamm
55eda59d05 Discovery: Ensure selective sync lists are sorted #6958 2019-01-18 11:00:13 +01:00
Christian Kamm
ad81454cdc vfs: Add vfs migration options to folder context menu
This allows enabling and disabling vfs.

To distinguish this operation from setting the root pin state, the
availability setting is adjusted as well to be similar to the
menu that shows in the shell extensions.
2019-01-18 10:59:12 +01:00
Christian Kamm
44a579d32c vfs: Allow retrieving of pin state paths and flags 2019-01-18 10:59:12 +01:00
Christian Kamm
67f5585033 Result: Add copy/move ctor/op=
It has a destructor and these operations make sense. Particularly the
move is important for code like:

Result<x, y> foo() { Result<x, y> v; return v; }

because the move-ctor will not autogenerate if x or y are not trivially
destructible.
2019-01-18 10:59:12 +01:00
Christian Kamm
44715c7ef3 vfs: Change per-folder message on vfs support
I'm unsure this note is all that useful. Remove entirely?
2019-01-18 10:59:12 +01:00
Christian Kamm
3f45e0defe vfs: Allow (de-)hydrating the full sync folder 2019-01-18 10:59:12 +01:00
Christian Kamm
46098a160d vfs: Don't assume suffix mode for old folders
That would break with old folders that use selective sync.
2019-01-18 10:59:12 +01:00
Christian Kamm
bd93002759 vfs: Disable selective sync if vfs support is available 2019-01-18 10:59:12 +01:00
Christian Kamm
421c0b447e Merge remote-tracking branch 'origin/2.5' 2019-01-15 11:18:24 +01:00
Christian Kamm
6627d8139d Settings: Fix copyable text on version 'link' #6974
I don't see how to disable the right-click "Copy Link Location" context
menu, but we can make it copy the version text instead.
2019-01-15 10:09:40 +01:00
Christian Kamm
990a458e87 Wizard: Ensure client cert doesn't get lost #6911 2019-01-14 20:52:14 +01:00
Christian Kamm
c74bc5d867 Wizard: Drop unused function 2019-01-14 20:52:14 +01:00
Dominik Schmidt
5a9bbee708 Add macdeployqt target to make its invocation easier 2019-01-14 12:21:06 +01:00
Dominik Schmidt
772f3d2dbf Do not run macdeployqt.py from CMake. 2019-01-14 12:21:06 +01:00
Markus Goetz
a3f3546879 Sync: Display theme in debug log 2019-01-11 11:28:53 +01:00
Christian Kamm
7ac09fc4db sqlite: Set exclusive locking_mode to avoid WAL issues #6881
Can be overridden with OWNCLOUD_SQLITE_LOCKING_MODE
2019-01-11 10:59:37 +01:00
Dominik Schmidt
872bb99a58 Fix lookup of system wide settings 2019-01-11 10:36:33 +01:00
Christian Kamm
e87660ba28 Merge remote-tracking branch 'origin/2.5' 2019-01-10 10:08:03 +01:00
Markus Goetz
b05440fd9d qtmacgoodies: Improve our cmake use 2019-01-09 17:51:37 +01:00
Christian Kamm
f0ef500318 Update qtmacgoodies for an OSX crash fix #6930
The updated code in qtmacgoodies uses private headers.
2019-01-09 17:51:37 +01:00
Christian Kamm
0dd48d3a06 SocketAPI: Overhaul ui for 'available locally' vs 'online only'
For #6815
2019-01-07 10:15:37 +01:00
Christian Kamm
eeff9ccb69 Db: Add wiping of pin state for subtrees 2019-01-07 10:15:37 +01:00
Christian Kamm
df1723c9b2 vfs: Remove newFilesAreVirtual - use root PinState instead
This unifies how to deal with pin states.

Also enable reading a folders direct pin state vs its effective pin
state.
2019-01-07 10:09:03 +01:00
Olivier Goffart
3313de9066 Discovery: Handle the blacklistFiles from the server capabilities
Issue #434

Ideally one could add the blacklist to the exlucde reggexp, but this
is simpler
2018-12-22 18:19:37 +01:00
Christian Kamm
979cea3a38 Progress: Virtual file creation needs no transfer progress #6933
Treat virtual file creation as a size-less action, similar to
propagating renames or deletions.
2018-12-21 09:22:39 +01:00
Christian Kamm
8fb9c4ab5e vfs: Show "new files are virtual" option only with vfs
If there's no vfs possibility, showing it makes little sense.
2018-12-19 14:51:40 +01:00
Christian Kamm
4e2546d476 vfs: SocketAPI actions adjust pin state of directories #6815
Downloading a folder also sets its pin state; releasing a folder sets
its pin state.
2018-12-19 14:04:24 +01:00
Christian Kamm
fac6ad354f vfs: Use PinState in sync algorithm #6815
New files are virtual if the file's pin state is OnlineOnly.
2018-12-19 14:04:24 +01:00
Christian Kamm
446002bcb4 vfs: Introduce PinState db storage #6815
The idea is to allow folders (and later maybe files?) to be
- pinned to be available locally
- pinned to be online only
- inherit their pin from the parent

Where this pinning only controls the default for new files.
Subfolders may have a different pin state, and contained files
may be hydrated or dehydrated based on user actions.

This value is stored in a new 'flags' table. The idea is to store
data there that doesn't necessarily exist for each metadata entry.
The selective sync state could be migrated to this table.
2018-12-19 14:04:24 +01:00
Olivier Goffart
3eabe35520 Discovery: Set right direction when restoring deleted discovery because it has modified files
(Catched by a faillure of t1.pl)
2018-12-19 10:54:48 +01:00
Olivier Goffart
964c84a07e AccountSettings: add an item to open the folder in the browser
from the selective sync context menu

Issue: #6471
2018-12-19 10:54:02 +01:00
Olivier Goffart
07c134b67e Port the exclude test to the QTest Framework
This is just a port to QtTest, I did not change the layout of the test.
I did search and replace to replace the assert with QCOMPARE/QVERIFY
I still call setup and setup_init like before (only explicitly, now)

Also ported the preformence tests to QBENCHMAK because windows don't have
gettimeofday.

Relates #6358
2018-12-19 10:53:34 +01:00
Christian Kamm
5211d9a8b1 Database: Change path for new dbs to .sync_* #5904
This is to avoid issues on OSX, where the ._ prefix has special meaning.

Originally (before 2.3.2) ._ was necessary to guarantee exclusion. But
since then the .sync_ prefix is excluded as well.

This does not affect existing database files.
2018-12-19 10:14:25 +01:00
Christian Kamm
e97d42933e Vfs: Have a static list of potential plugins for now
Fixes in-source builds and other cases where more non-plugin directories
are created in src/libsync/vfs.
2018-12-18 15:17:04 +01:00
Christian Kamm
0b35d901eb Vfs: Ensure older versions gracefully ignore winvfs folders
Previously there'd likely be a mess if a 2.6 winvfs folder was attempted
to be used with a 2.5 client. Now the older clients will ignore these
folders.
2018-12-18 15:16:40 +01:00
Christian Kamm
d7020f77f7 Vfs plugins: Available plugins must load
A plugin that can't be loaded due to dependency issues should not be
considered as available.
2018-12-18 15:16:21 +01:00
Olivier Goffart
e3c98422d2 sqlite: Update bundled version to 3.26.0
For OS X and Windows.
2018-12-18 12:20:18 +01:00
Olivier Goffart
3b0a21028c SyncEngine: Ensure that the paths passed to the discovery ends with slashes
This was making the tx.pl test fail
2018-12-18 11:06:31 +01:00
Olivier Goffart
aa05ce40f8 Logging: do not write to a temporary logdir if --logfile is passed
I guess the logger->isLoggingToFile was supposed to check that.
But this is not returning the right value if we did not enter the
logfile already.

Issue #6909
2018-12-17 14:27:01 +01:00
Olivier Goffart
8fac2bf5d1 Propagator: Don't abort sync on error 503
Only do it when it is actually a maintenance mode

Issues #5088, #5859, https://github.com/owncloud/enterprise/issues/2637
2018-12-17 12:37:54 +01:00