Files
CLIProxyAPI/internal/pluginhost/loader_unsupported.go
Luis Pater b5b724d06d fix(pluginhost): reuse content-addressed plugin shadow copies across restarts
- Reuse existing content-addressed shadow binaries in `<plugin_dir>/.shadow` (with a per-directory shared cache fallback) and verify target digests before creating any temporary files.
- Publish shadow binaries without unlinking active targets and coordinate plugin loading with stale shadow cleanup via OS-level file locks.
- Add regression tests covering cross-restart shadow reuse, zero-write cache hits, fallback isolation, and concurrent load/prune coordination.

Closes: #7323
2026-11-07 18:10:39 +08:00

18 lines
423 B
Go

//go:build !cgo && !windows
package pluginhost
import "fmt"
type unsupportedLoader struct{}
func (unsupportedLoader) Open(file pluginFile, host *Host) (pluginClient, error) {
return nil, fmt.Errorf("standard dynamic library plugin loading requires cgo on this platform: %s", file.Path)
}
func defaultPluginLoader() pluginLoader {
return unsupportedLoader{}
}
func cleanupStaleShadowPlugins(string, []pluginFile) {}