faed70fe03
content disposition tweaks (attachment by default, ui target=_blank)
2022-02-03 16:54:37 +01:00
2173ca5b51
add a --clean param
2022-02-03 16:54:36 +01:00
dc72b0a34c
only insert ADDED on first add
2022-02-03 10:12:26 +01:00
3cd3df27c0
"ADDED" entry for files
2022-02-03 09:54:51 +01:00
a5912ae3d2
move preview generation off the route thread
2022-02-03 00:11:35 +01:00
f20928ddfe
rustfmt
2022-02-02 17:13:23 +01:00
6aa804584d
add (some) lang tests, implement "in" logic
2022-02-02 17:13:11 +01:00
cb22756a47
separate endpoint for attr overwrites, implement AttributeUpdate
2022-02-02 00:45:05 +01:00
9c940e7c23
add explicit quick_check/disable_synchronous flags, ?full param to rescan endpoint
2022-01-31 17:26:31 +01:00
466f870d6f
add Meta queries, check db version on start
2022-01-31 15:57:35 +01:00
768a608b02
add "built" crate
2022-01-31 15:19:48 +01:00
34847f3321
fix search ("contains" query, UpObject params bug)
2022-01-30 16:20:02 +01:00
fa5626af4f
allow only one job of a type to be in progress at once
2022-01-30 16:00:29 +01:00
3a64adc935
containers -> groups
2022-01-28 23:32:13 +01:00
8c8d58847a
separate value_string and value_number columns
...
to be able to utilize SQL queries better for ranges, comparisons, etc.
2022-01-28 18:17:14 +01:00
8b9947c2e4
fix no-default-features build
2022-01-28 14:21:07 +01:00
ddfe103e7a
add LBLs to base types
2022-01-27 17:42:59 +01:00
19b25666c6
show PDFs in BlobPreview, add ?inline query param to /raw/
2022-01-27 15:55:48 +01:00
538ccc27ec
refactor address tests to use results
2022-01-27 10:53:19 +01:00
01029053c9
add url address type
2022-01-27 10:51:26 +01:00
b095f900f6
test addresses encoding/decoding on equivalence and not just representation
2022-01-26 17:07:58 +01:00
fa957794e5
encode/decode -> b58_encode/decode
2022-01-26 16:55:23 +01:00
4a02921bbd
send a http 303 if thumbnail isn't applicable
2022-01-24 18:26:53 +01:00
d508cd0a74
add image previews
2022-01-24 17:04:27 +01:00
1f058670f8
don't duplicate file if it already exists
2022-01-23 15:01:14 +01:00
3cc0dcff45
also LBL uploaded file
2022-01-23 14:55:49 +01:00
c1698061d5
file fns return addresses
2022-01-23 14:55:40 +01:00
dd16a96125
canonicalize paths before normalization, fix symlink bug
2022-01-23 14:51:54 +01:00
893a87a094
unify adding files via rescans and ui
2022-01-23 14:50:37 +01:00
ef59090859
separate adding file into its own fn, refactor private fn names
2022-01-23 13:03:27 +01:00
a4caf9b8b3
fix insert_entry retval
2022-01-22 17:45:46 +01:00
0920fec0ce
add immutable entries for size, etc (does nothing for now)
2022-01-21 17:59:53 +01:00
a91711adc8
only disable sqlite synchronous mode on initial update
2022-01-21 17:57:51 +01:00
ecaea693c6
reformat (?)
2022-01-21 17:03:50 +01:00
b4b41e45e3
desktop enables are actually disabled
2022-01-19 20:42:36 +01:00
e489fd7b5a
--no-desktop implies --no-browser
2022-01-19 20:36:02 +01:00
7def06e153
copy & remove instead of persist/rename
2022-01-18 22:43:55 +01:00
d46f449e4b
file upload
...
todo:
- don't return file hash in ListingResult, solve this marking problem in general?
- work around persisterror across filesystems
- add proper BLOB metadata
2022-01-18 17:05:45 +01:00
1521f25132
impl Hashable for Path, not just PathBuf
2022-01-18 16:59:59 +01:00
b3b6c2d2a8
raise global payload limit
2022-01-18 16:59:46 +01:00
a2b9ec4c75
move "?" out of upend macros
2022-01-18 16:59:32 +01:00
338be4be10
/raw/ queries of entries
2022-01-14 22:04:53 +01:00
2f6a265af8
alike value queries do not include addresses
2022-01-13 20:31:50 +01:00
8ceb310d9e
preparations for a separate attr update endpoint
2022-01-09 21:18:19 +01:00
952475b92b
fix missed reporting on path cleanups
2022-01-08 12:21:04 +01:00
368eb90d5b
fix compile with no default features
2022-01-07 00:52:09 +01:00
091a02d530
add endpoint to list all attributes
2022-01-06 23:23:35 +01:00
a43a9d6caf
thumbnails -> previews
2021-12-27 13:13:53 +01:00
d11d20f210
fix tests due to tempdir -> tempfile change
2021-12-27 12:36:38 +01:00
6b95e59acf
try next port if taken
2021-12-27 11:58:01 +01:00
3186b9ce6e
add video thumbnailing via ffmpeg
2021-12-26 18:16:37 +01:00
aa67b93e4e
improve mime & content-disposition for thumbnails
2021-12-26 17:40:47 +01:00
5f8182e9b7
switch from tree_magic to mini_tree_magic
2021-12-25 11:35:37 +01:00
a608659baa
thumbnails module, "text thumbnails" on backend
2021-12-23 23:45:46 +01:00
0f3dd88193
clippy fixes, no default feature compile fix
2021-12-23 11:18:04 +01:00
0058a9fcdd
test db open newness
2021-12-23 11:11:36 +01:00
ce9e552844
rewrite database module as a struct instead of bare fns
2021-12-23 11:10:16 +01:00
b2768cbad9
add warning on parent native open
2021-12-22 11:56:06 +01:00
2ccfce6058
remove some file-centric language
2021-12-21 23:16:10 +01:00
057ac8e35f
open dir instead of 403 on native executable
2021-12-21 17:43:29 +01:00
b52d664cd4
error logging in native open
2021-12-21 16:05:27 +01:00
7d0b23e955
impl fromstr for query
2021-12-21 12:01:40 +01:00
8e71e34a09
add not queries into uplang
...
somewhat awkwardly implemented as multiqueries, but hey
2021-12-21 11:50:46 +01:00
2d1a3b9ba7
better test of list_roots
2021-12-21 11:26:20 +01:00
7a1d0a5024
add native/default file open
2021-12-19 22:38:41 +01:00
ac1e110b02
optional "desktop" feature
2021-12-19 20:09:44 +01:00
c44afd0376
default vault name is dirname
2021-12-19 18:53:10 +01:00
ffedb89e03
todo
2021-12-18 00:14:47 +01:00
64906a1049
separate hier_roots endpoint, resolve via redirects
2021-12-17 23:42:58 +01:00
e0a603d154
remove list_hier, retrieve_object retrieves attrs of attrs, rework /api/hier
2021-12-17 23:04:35 +01:00
1194a4439e
list_path also fetches attrs of attrs
2021-12-17 19:44:00 +01:00
a33943bdb7
handle root /hier/ query
2021-12-17 14:15:56 +01:00
43d7b06c2b
Revert "update dependencies"
...
This reverts commit 58d74d985c
.
2021-12-10 14:57:46 +01:00
58d74d985c
update dependencies
2021-12-09 22:03:55 +01:00
7adaecdafc
re-enable synchronous mode more robustly through a drop guard
2021-12-05 23:31:19 +01:00
b49315e22b
update mtime if same hash to avoid hashing next time
2021-12-05 22:57:47 +01:00
cb832b6789
lock concurrent fetch_or_creates to prevent inconsistencies
2021-12-05 22:36:16 +01:00
dacfc57d11
truncate WAL log on start
2021-12-05 20:30:31 +01:00
cec3c4891e
set synchronous to NORMAL for all connections
2021-12-05 19:06:04 +01:00
64cdbf08bc
only process files in rescan, finally fix tests
2021-12-05 13:26:27 +01:00
365987f261
UpdatePathOutcome includes a "Failed" variant with path and error
2021-12-05 13:26:18 +01:00
b5a013e973
put upend into its own subdir, fix self-scanning
2021-12-05 12:43:43 +01:00
10eaab6e2d
logging, fix "database locked" errors on init
2021-12-05 12:23:02 +01:00
c8b8a76bba
logging
2021-12-05 12:10:41 +01:00
636da63c76
disable browser/ui serving if folder not found
2021-12-04 22:43:37 +01:00
4233a5da46
improve fs rescan logging
2021-12-04 21:58:16 +01:00
4b1a8c862c
turn off synchronous mode during fs resyncs
2021-12-04 21:43:13 +01:00
99c4a4e488
turn on WAL mode
2021-12-04 21:30:50 +01:00
bc97b8bc8f
move all inserts into a single transaction
2021-12-04 18:49:11 +01:00
dd765ee94b
add lru cache to resolve_path fn
2021-12-04 18:33:40 +01:00
4403f518c9
cargo clippy fixes
2021-12-04 16:46:13 +01:00
6edf550a95
logging in hash
2021-12-04 16:45:16 +01:00
2448169d64
small optimizations in fs import
2021-12-04 16:45:06 +01:00
5b973ea868
add hierarchy manipulation tests
2021-12-02 22:18:43 +01:00
da776bbcf3
return to old (orphanized) multi-root hierarchy
2021-12-02 21:52:43 +01:00
1df746596f
clean up db type code to better match actual usage
2021-12-02 21:30:11 +01:00
00cac1bca1
[db/ui] remove instantiations, use plain relations with aliases instead
2021-10-29 18:05:03 +02:00
30189b42a5
[db] fix clippy warnings
2021-10-29 15:49:53 +02:00
939297f91b
[db] follow symlinks
2021-10-28 17:24:47 +02:00
eec053a58a
[db] add basic tests for fs, hierarchies, database
2021-10-24 17:26:39 +02:00
d07c9fd339
[db] add --no-ui param
2021-10-19 22:23:46 +02:00
96d0ec3be7
introduce the concept of a hierarchy root
2021-08-18 11:06:39 +02:00
2944ce3d81
fix missing hier_label_attr, add trace to list_hier
2021-08-18 11:06:38 +02:00
fbee24978b
ensure UNode is non-empty
2021-08-18 11:06:37 +02:00
816f04fc86
upend hierarchies - first step
...
separate hierarchies.rs module from filesystem.rs, simplify and fix path handling
2021-08-18 11:06:36 +02:00
0b45f29319
macros into their own file, fix imports
2021-07-26 23:10:12 +02:00
2b6886645b
more cleanup and refactoring and moving
...
move models.rs and schema.rs into database::inner
create util module (with hash and jobs)
2021-07-26 21:14:51 +02:00
754c315cd2
refactor database.rs into separate files
2021-07-26 21:00:05 +02:00
5953c733cf
INSTANCED -> INSTANCES, sort of (also see #11 )
2021-06-28 20:39:24 +02:00
942ccf1c40
mark failed jobs with a specific state, prevent from lingering in ui
2021-06-20 16:46:45 +02:00
682eca3e5a
allow insertion of invariants via api
2021-06-20 14:07:15 +02:00
0beca214df
forgotten DIR_HAS attr in FS_DIR
2021-06-19 17:59:54 +02:00
2a3c1a5326
add more attrs to BLOB type
2021-06-19 15:56:10 +02:00
86294ebf53
create macros for common (type) inserts
2021-06-19 15:54:32 +02:00
841dc7c07b
mention data in base58 decode fail
2021-06-19 15:01:46 +02:00
b78e38162e
forgotten takes_value for --db-path
2021-06-19 13:11:27 +02:00
06d30433e5
allow specifying path to db on cli
2021-06-19 12:32:05 +02:00
fa1e366e5b
logging in query()
2021-06-18 19:01:05 +02:00
9c71eea8e1
return version info in /api/info
2021-06-18 18:28:18 +02:00
415450ccae
add TYPE_INSTANCED, BLOB is INSTANCED by FS_FILE
2021-06-06 23:50:27 +02:00
e0eb20aba7
add BLOB TYPE
2021-06-04 15:14:58 +02:00
4468262f50
fix bug adding duplicate Files
...
initialize digest in _process_directory_entry via once_cell
2021-05-28 23:36:00 +02:00
8044137531
add vault --name option, /api/info endpoint
2021-05-06 20:23:20 +02:00
7f358932f6
fix /latest endpoint
2021-05-06 20:10:40 +02:00
9df88d1ad5
fix clippy hints
2021-04-24 00:08:17 +02:00
7420fd45d8
add /api/files endpoint, refactor retrieve_file()
2021-04-23 23:28:58 +02:00
c2705d328d
get rid of uneccessary expects/unwraps in open_upend; logging
2021-04-19 00:34:01 +02:00
d32334088e
[backend] list_roots() returns Addresses directly, fix bug with resolving parentless directories
2021-04-04 23:24:52 +02:00
4804cea634
rewrite fetch_or_create_dir slightly for more clarity
2021-04-04 18:44:01 +02:00
da4d7e6758
attach mime entry directly to file hash; add mtime & size
2021-03-25 21:29:49 +01:00
54c1ea711d
do not log requests to /api/jobs
2021-03-24 20:37:42 +01:00
c422f89d18
add mime type to filesystem update step
2021-03-22 23:07:39 +01:00
Tomáš Mládek
b051529da6
better logging in rescan_vault()
2021-03-20 16:49:01 +01:00
Tomáš Mládek
b773dbc49c
TYPE_ID attr, type of TYPE
...
(todo: clean up, deduplicate code...)
2021-03-19 00:03:34 +01:00
Tomáš Mládek
0f006ea32c
fix invariant calculation/insertion
2021-03-18 22:42:03 +01:00
Tomáš Mládek
e38bab5957
remove ensure_invariant now that it's unnecessary
2021-03-15 22:37:09 +01:00
Tomáš Mládek
2ffbd4934b
refer to types via address, not identifier
...
also rework invariant entries, add addressable trait
2021-03-15 22:32:04 +01:00
Tomáš Mládek
ce36c97f2a
add basic types
2021-03-14 22:16:28 +01:00
Tomáš Mládek
6f31ef5e15
Address can also refer to an Attribute (String)
2021-03-14 12:41:38 +01:00
Tomáš Mládek
21e7ee7538
finish renaming target/key/value to entity/attribute/value
2021-03-14 10:44:13 +01:00
Tomáš Mládek
6e7cdd9887
rename reimport_directory to rescan_vault
2021-03-06 22:14:17 +01:00
Tomáš Mládek
05d0fa7a87
ignore UniqueViolation errors in inserts
2021-03-06 18:23:31 +01:00
Tomáš Mládek
8751e57433
add latest_files endpoint
2021-02-21 19:51:23 +01:00
Tomáš Mládek
61a470dfe3
models::File uses Hash instead of plain Vec<u8>
2021-02-21 19:43:28 +01:00
Tomáš Mládek
105a9c7e0b
fix http error code for PUT /obj
2021-02-21 17:49:34 +01:00
Tomáš Mládek
dc05b05873
fix object deletion, identity attr insertion
2021-02-21 17:36:41 +01:00
Tomáš Mládek
e462801823
fix entry addresses for /api/obj
2021-02-21 17:08:33 +01:00
Tomáš Mládek
302f435c5d
/query returns map with hashes
2021-02-21 12:30:17 +01:00
Tomáš Mládek
550e8d5c0f
fix http error code for /query
2021-02-21 10:38:31 +01:00
Tomáš Mládek
ed5ea08335
add "jobs", endpoint to query vault update progress
2021-02-20 17:36:19 +01:00
Tomáš Mládek
5096e1eece
refactoring: remove query_entries(), from_sexp into TryFrom, query_to_sqlite is a method
2021-02-20 12:39:19 +01:00
Tomáš Mládek
001fad3145
remove "unsafe unwraps"
2021-02-20 12:39:18 +01:00
Tomáš Mládek
c0e1f42533
consolidate API routes, remove lookup_by_filename
2021-02-20 12:12:48 +01:00
Tomáš Mládek
f5dd4141b1
adjacent tagging for EntryValue
2021-02-20 12:10:03 +01:00
Tomáš Mládek
cc4d7209be
fix FromStr for Address
2021-02-19 22:35:05 +01:00
Tomáš Mládek
ae812b33d1
add hash encode/decode test
2021-02-19 22:27:54 +01:00
Tomáš Mládek
3fb436708b
attempt (?) to return hash from insert_entry, improve error logging
2021-02-19 22:18:31 +01:00
Tomáš Mládek
3ad31a482d
add an "insert entry" (PUT) endpoint
2021-02-19 21:58:35 +01:00
Tomáš Mládek
dc71bec67a
implement Serialize/Deserialize for Entry, Address, remove as_json
...
+ cosmetics (to_str -> to_string)
2021-02-19 21:56:25 +01:00
Tomáš Mládek
99f6c6c052
remove InnerEntry, consolidate into Entry
2021-02-19 20:27:30 +01:00
Tomáš Mládek
db5235bbd5
run cargo update
, fix incorrect imports
2021-02-18 19:20:52 +01:00
Tomáš Mládek
22dd315c47
cargo clippy fixes
2021-02-17 21:45:20 +01:00
Tomáš Mládek
1bbcc00d65
add "contains" symbol
2021-02-17 21:40:51 +01:00
Tomáš Mládek
ac02450b8b
fix "OR TRUE" variant; remove Option<> from query_to_sqlite()
2021-02-12 11:56:29 +01:00
Tomáš Mládek
98a9c88173
add upend query lang -> sqlite conversion; first working prototype
2021-02-12 02:06:39 +01:00
Tomáš Mládek
f950e02113
add s-exp query language parsing
...
also rename t/k/v to e/a/v, misc. fixes
2021-02-07 20:18:55 +01:00
bb2a8e909f
cargo clippy fix
2020-09-30 01:33:36 +02:00
f586b93af5
remove "|| true" from init update logic; add command-line opt for that
2020-09-30 01:31:59 +02:00
02c65ded8e
return an enum signifying action taken from fs update functions
2020-09-30 01:31:48 +02:00
7fd537a948
add DELETE endpoint for objects, update URLs (/get/ -> /obj/)
2020-09-29 00:55:09 +02:00
2307c7bd57
expand query_entries for fuzzier queries; fix filename lookup
2020-09-29 00:30:00 +02:00
9a5a7383a4
add bulk_retrieve_objects, add base inspect view, upgrade typescript, add swrv...
...
fix type issues, better http errors on mangled addresses
2020-09-25 02:45:17 +02:00
0e424c4e8c
switch to Vue 3 in ui
2020-09-25 01:11:04 +02:00
6e449088a0
add update duration print out
2020-09-23 23:11:50 +02:00
80541fe978
non-duplicate updates (without updating virtual fs structure yet)
2020-09-22 00:41:59 +02:00
63ffe42907
lock update pool behind r/w lock; increase timeout to 30s
...
to-do - integrate r/w lock into pool directly?
2020-09-20 20:14:05 +02:00
400b0d11f2
^^ take that back, likely not necessary in this case
2020-09-20 19:42:53 +02:00
ec9b31292e
handle canonicalization errors
2020-09-20 19:40:36 +02:00
967e3a3c7d
lint
2020-09-20 19:32:28 +02:00
0e0afae089
parallelize hashing with rayon
2020-09-20 19:28:44 +02:00
9823f646cd
move all reimport db writes into a transaction
2020-09-20 17:17:43 +02:00
e0a03b30fa
split business code in reimport_directory in a separate function
2020-09-20 16:29:16 +02:00
00e0dc288c
remove DbExecutor, store plain pool in state; refactor into functions
...
also put loggersink in util.rs
2020-09-15 19:26:47 +02:00
36e3c4a145
move LoggerSink to util.rs
2020-09-14 21:18:53 +02:00
01a737285c
clippy fixes
2020-09-14 01:16:01 +02:00
c9c005eff0
strip and relativize paths on fs import
2020-09-13 20:43:45 +02:00
ff457faca3
hierarchy listing endpoint, fix trailing slash upath parsing
2020-09-13 20:10:18 +02:00
2b92a1ad67
validate path on string parse
2020-09-13 19:20:32 +02:00
d505653866
reorganize code in database.rs
2020-09-13 16:30:01 +02:00
267bca92bf
/raw/ endpoint does not take plain hash but an encode, add Entry.as_json()
2020-09-13 14:28:58 +02:00
b245b50e15
fix retrieveobject
2020-09-13 13:24:35 +02:00
0464d2712e
remove encode() where unnecessary, add /get/{object} route
2020-09-13 13:22:18 +02:00
3cf3343326
files are separate objects
2020-09-12 23:07:50 +02:00
762a7914a1
first somewhat working version of import!
2020-09-12 22:50:14 +02:00
fc7635bf70
--reinitialize param, logging
2020-09-12 15:02:03 +02:00
6895b076be
display methods
2020-09-12 14:43:42 +02:00
1d952b34dd
various fixes, fleshing out, directory retrieval / creation
2020-09-12 14:31:53 +02:00
e49d4c9ff5
implement entity system, first step
2020-09-07 21:21:54 +02:00
add9dd012f
update models, fix build, add chrono
2020-09-06 12:32:17 +02:00
d7bbb5396c
first database draft
2020-09-06 12:02:55 +02:00