Start prefetching based on the user's prefetch settings.
(self)
| 73 | self._thread = None |
| 74 | |
| 75 | def start_configured(self) -> None: |
| 76 | """Start prefetching based on the user's prefetch settings.""" |
| 77 | mode = getattr(self.mycli, 'prefetch_schemas_mode', PrefetchMode.ALWAYS.value) |
| 78 | schema_list = getattr(self.mycli, 'prefetch_schemas_list', []) |
| 79 | parsed = parse_prefetch_config(mode, schema_list) |
| 80 | if parsed is not None and not parsed: |
| 81 | # ``never`` or ``listed`` with an empty list — nothing to do. |
| 82 | return |
| 83 | self._start(parsed) |
| 84 | |
| 85 | def prefetch_schema_now(self, schema: str) -> None: |
| 86 | """Fetch *schema* immediately on a background thread. |