beets/docs/plugins
Sam Thursfield 2fa3717731 Optimise FormattedMapping when querying a specific set of fields
This changes greatly improves the speed of `beet export` and `beet info`
when the `--include-keys` option is used. It also removes the globbing
feature of `--include-keys` that was added in #1295. (See #3762 for
discussion).

Listing all fields for an item requires querying the database to find
any flex attributes. This is slow when done for every item being
exported. We already have a way for the user to specify a fixed set
of keys, but we previously queried everything and filtered it afterwards.
The new approach is more efficient.

Code that iterates through all fields now have to handle invalid field
names. The export and info plugins output invalid fields as None.

Timings before:

    > /usr/bin/time beet export -i title,path,artist -l  Bob Dylan
    13.26user 20.22system 0:34.01elapsed 98%CPU (0avgtext+0avgdata 52544maxresident)k

    > /usr/bin/time beet export -l  Bob Dylan
    12.93user 20.15system 0:33.58elapsed 98%CPU (0avgtext+0avgdata 53632maxresident)k

Timings after:

    > /usr/bin/time beet export -l  Bob Dylan
    13.33user 20.17system 0:34.02elapsed 98%CPU (0avgtext+0avgdata 53500maxresident)k

    > /usr/bin/time beet export -i title,path,artist -l  Bob Dylan
    0.49user 0.07system 0:00.56elapsed 98%CPU (0avgtext+0avgdata 50496maxresident)k

Notice the dramatic speedup in the last example!
2021-05-01 23:41:09 +02:00
..
absubmit.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
acousticbrainz.rst Issue #2860 Fetch more acousticbrainz fields 2019-07-23 20:25:26 -04:00
aura.rst AURA: Small updates to docs and set server version 2021-03-07 18:24:57 +00:00
badfiles.rst Add docs for badfiles' check_on_import option. 2021-03-24 16:55:28 -05:00
bareasc.rst Make unicode handling explicit, to support python 2 and 3. 2021-03-16 16:29:57 +00:00
beatport.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
beetsweb.png Recompress png file (#2552) 2017-05-05 19:52:55 +01:00
bpd.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
bpm.rst Remove write option from bpm and use import.write 2016-05-06 17:50:27 +01:00
bpsync.rst Fix spelling 2019-10-05 20:59:47 -07:00
bucket.rst docs: fix some markup issues and typos 2019-04-27 12:43:13 +10:00
chroma.rst Swap links 2020-10-08 00:35:03 -07:00
convert.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
deezer.rst docs/plugins: Centralize documentation of source_weight option 2019-10-01 21:19:35 +02:00
discogs.rst Fix #3608: Replace discogs-client with python3-discogs-client 2021-02-27 10:09:23 +13:00
duplicates.rst slight language tweak in duplicates plugin docs 2016-09-10 16:53:53 -04:00
edit.rst edit: add documentation 2016-02-05 13:12:46 +01:00
embedart.rst Docs tweaks for #3493 2020-02-26 19:15:44 -08:00
embyupdate.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
export.rst export: Add --format=jsonlines option 2020-10-02 12:41:29 +02:00
fetchart.rst fetchart/artresizer: add max_filesize support (#3560) 2021-03-23 12:00:14 +01:00
filefilter.rst Update filefilter.rst 2015-01-26 23:26:54 +01:00
fish.rst Rewrite Fish completion plugin docs & code comments 2020-03-04 07:15:46 +01:00
freedesktop.rst docs: fix some markup issues and typos 2019-04-27 12:43:13 +10:00
fromfilename.rst docs: add plugin name in "how to configure" sentences 2014-10-28 23:23:10 +01:00
ftintitle.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
fuzzy.rst doc: emphasize options names by using bold font instead of fixed width 2014-11-07 22:13:25 +01:00
gmusic.rst docs: fix some markup issues and typos 2019-04-27 12:43:13 +10:00
hook.rst Refine docs for the hook plugin 2016-04-30 15:12:07 -07:00
ihate.rst Remove stray space in docs 2016-01-18 16:08:54 -05:00
importadded.rst importadded: adapt doc for new option preserve_write_mtimes 2016-03-22 06:24:09 +01:00
importfeeds.rst doc: emphasize options names by using bold font instead of fixed width 2014-11-07 22:13:25 +01:00
index.rst Add documentation for bareasc to the plugins index. 2021-03-15 15:53:14 +00:00
info.rst Optimise FormattedMapping when querying a specific set of fields 2021-05-01 23:41:09 +02:00
inline.rst Add docs note for custom-field sorting, fix typo 2015-11-25 19:15:01 +01:00
ipfs.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
keyfinder.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
kodiupdate.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
lastgenre.rst lastgenre: Make TitleCasing optional 2020-12-15 23:37:16 +00:00
lastimport.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
loadext.rst Add loadext plugin 2019-04-21 15:10:28 +01:00
lyrics.rst Shorten a ReST underline 2021-03-28 14:23:38 -04:00
mbcollection.rst docs: clarify mbcollection options 2020-06-08 16:29:33 -04:00
mbsubmit.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
mbsync.rst docs: fix some markup issues and typos 2019-04-27 12:43:13 +10:00
metasync.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
missing.rst beetsplug: implement missing -a -t 2017-03-18 19:05:46 -04:00
mpdstats.rst Fix docs and changelog 2021-02-22 14:28:14 +01:00
mpdupdate.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
parentwork.rst Get the date of the parentwork, which may be different from the date of the child work. 2020-07-03 09:35:15 -07:00
permissions.rst Updated permissions plugin docs 2015-02-17 11:41:15 +01:00
play.rst docs: fix some markup issues and typos 2019-04-27 12:43:13 +10:00
playlist.rst Fix simple typo: speicifying -> specifying 2019-11-12 08:07:37 +11:00
plexupdate.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
random.rst Docs fixes for #2322 2016-12-26 16:10:46 -05:00
replaygain.rst Disable replaygain parallelism during import 2020-12-21 19:19:20 +01:00
rewrite.rst docs: add plugin name in "how to configure" sentences 2014-10-28 23:23:10 +01:00
scrub.rst doc: emphasize options names by using bold font instead of fixed width 2014-11-07 22:13:25 +01:00
smartplaylist.rst Spelling & changelog for #3334 2019-07-24 22:13:53 -04:00
sonosupdate.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
spotify.rst docs/plugins: Centralize documentation of source_weight option 2019-10-01 21:19:35 +02:00
subsonicplaylist.rst Update docs/plugins/subsonicplaylist.rst 2020-05-05 10:45:43 +02:00
subsonicupdate.rst Add broken link checker to integration test (#3703) 2020-09-04 15:42:36 -05:00
the.rst doc: emphasize options names by using bold font instead of fixed width 2014-11-07 22:13:25 +01:00
thumbnails.rst Update a lot of URLs to use HTTPS 2019-06-05 03:11:49 +02:00
types.rst Fix example of Types plugin documentation 2015-10-18 13:46:39 +02:00
unimported.rst improvements from review #2 2019-10-15 21:54:35 +02:00
web.rst Documentation and changelog for web `readonly` option fixing #3870. 2021-03-11 23:09:51 +00:00
zero.rst Punctuation improvements 2019-08-01 09:32:33 -04:00