Documentation
¶
Index ¶
- type App
- func (a *App) AddFilesToQueue() error
- func (a *App) ApplyPendingConfig() error
- func (a *App) CancelJob(id string) error
- func (a *App) CancelUpload() error
- func (a *App) ClearQueue() error
- func (a *App) DebugQueueItem(id string) (map[string]interface{}, error)
- func (a *App) DiscardPendingConfig() error
- func (a *App) DownloadNZB(id string) error
- func (a *App) GetAppStatus() AppStatus
- func (a *App) GetAppliedConfig() (*config.ConfigData, error)
- func (a *App) GetAutoPauseReason() string
- func (a *App) GetConfig() (*config.ConfigData, error)
- func (a *App) GetConfigPath() string
- func (a *App) GetLoggingStatus() map[string]interface{}
- func (a *App) GetLogs() (string, error)
- func (a *App) GetLogsPaginated(limit, offset int) (string, error)
- func (a *App) GetMigrationStatus() (map[string]interface{}, error)
- func (a *App) GetNZB(id string) (content string, fileName string, err error)
- func (a *App) GetNntpPoolMetrics() (NntpPoolMetrics, error)
- func (a *App) GetOutputDirectory() string
- func (a *App) GetPendingConfigStatus() map[string]interface{}
- func (a *App) GetProcessorStatus() ProcessorStatus
- func (a *App) GetQueueItems(params PaginationParams) (*PaginatedQueueResult, error)
- func (a *App) GetQueueStats() (QueueStats, error)
- func (a *App) GetRunningJobs() ([]processor.RunningJobItem, error)
- func (a *App) GetRunningJobsDetails() ([]processor.RunningJobDetails, error)
- func (a *App) GetWatchDirectory() string
- func (a *App) GetWatcherStatus() watcher.WatcherStatusInfo
- func (a *App) HandleDroppedFiles(filePaths []string) error
- func (a *App) HasPendingConfigChanges() bool
- func (a *App) IsLegacyDatabase() (bool, error)
- func (a *App) IsProcessingAutoPaused() bool
- func (a *App) IsProcessingPaused() bool
- func (a *App) IsUploading() bool
- func (a *App) MigrateTo(version int64) error
- func (a *App) NavigateToDashboard()
- func (a *App) NavigateToSettings()
- func (a *App) PauseProcessing() error
- func (a *App) RecreateDatabase() error
- func (a *App) RemoveFromQueue(id string) error
- func (a *App) ResetDatabase() error
- func (a *App) ResumeProcessing() error
- func (a *App) RetryJob(id string) error
- func (a *App) RollbackMigration() error
- func (a *App) RunMigrations() error
- func (a *App) SaveConfig(configData *config.ConfigData) error
- func (a *App) SelectConfigFile() (string, error)
- func (a *App) SelectOutputDirectory() (string, error)
- func (a *App) SelectTempDirectory() (string, error)
- func (a *App) SelectWatchDirectory() (string, error)
- func (a *App) SetQueueItemPriority(id string, priority int) error
- func (a *App) SetWebEventEmitter(emitter func(eventType string, data interface{}))
- func (a *App) SetWebMode(isWeb bool)
- func (a *App) SetupWizardComplete(wizardData SetupWizardData) error
- func (a *App) Shutdown()
- func (a *App) Startup(ctx context.Context)
- func (a *App) TestProviderConnectivity(serverData ServerData) ValidationResult
- func (a *App) UploadFiles() error
- func (a *App) ValidateNNTPServer(serverData ServerData) ValidationResult
- type AppPaths
- type AppStatus
- type CompressedMetrics
- type MetricSummary
- type NntpPoolMetrics
- type NntpProviderMetrics
- type PaginatedQueueResult
- type PaginationParams
- type ProcessorStatus
- type QueueItem
- type QueueStats
- type ServerData
- type SetupWizardData
- type ValidationResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
App struct for the Wails application
func (*App) AddFilesToQueue ¶
AddFilesToQueue adds multiple files to the queue for processing
func (*App) ApplyPendingConfig ¶ added in v0.0.13
ApplyPendingConfig manually applies pending configuration changes
func (*App) CancelUpload ¶
CancelUpload is no longer used - individual jobs are cancelled via CancelJob This function is kept for backward compatibility but does nothing
func (*App) ClearQueue ¶
ClearQueue removes all completed and failed items from the queue via queue
func (*App) DebugQueueItem ¶
DebugQueueItem returns debug information about a queue item
func (*App) DiscardPendingConfig ¶ added in v0.0.13
DiscardPendingConfig discards pending configuration changes
func (*App) DownloadNZB ¶
DownloadNZB downloads the NZB file for a completed item
func (*App) GetAppStatus ¶
GetAppStatus returns the current application status
func (*App) GetAppliedConfig ¶ added in v0.0.13
func (a *App) GetAppliedConfig() (*config.ConfigData, error)
GetAppliedConfig returns the currently applied configuration (ignoring pending)
func (*App) GetAutoPauseReason ¶ added in v0.0.20
GetAutoPauseReason returns the reason for automatic pause, if any
func (*App) GetConfig ¶
func (a *App) GetConfig() (*config.ConfigData, error)
GetConfig returns the current configuration (pending config if available, otherwise applied config)
func (*App) GetConfigPath ¶
GetConfigPath returns the path to the configuration file
func (*App) GetLoggingStatus ¶ added in v0.0.10
GetLoggingStatus returns information about logging configuration
func (*App) GetLogsPaginated ¶
GetLogsPaginated returns paginated log content limit: number of lines to return (0 = use original 1MB limit) offset: number of lines to skip from the end (0 = start from most recent)
func (*App) GetMigrationStatus ¶ added in v0.0.22
GetMigrationStatus returns the current migration status
func (*App) GetNZB ¶ added in v0.0.22
GetNZBContent returns the content of an NZB file for a completed item
func (*App) GetNntpPoolMetrics ¶ added in v0.0.16
func (a *App) GetNntpPoolMetrics() (NntpPoolMetrics, error)
GetNntpPoolMetrics returns NNTP connection pool metrics from the singleton pool manager
func (*App) GetOutputDirectory ¶
GetOutputDirectory returns the current output directory
func (*App) GetPendingConfigStatus ¶ added in v0.0.13
GetPendingConfigStatus returns the status of pending config changes
func (*App) GetProcessorStatus ¶
func (a *App) GetProcessorStatus() ProcessorStatus
GetProcessorStatus returns processor status information
func (*App) GetQueueItems ¶
func (a *App) GetQueueItems(params PaginationParams) (*PaginatedQueueResult, error)
GetQueueItems returns the current queue items from the queue
func (*App) GetQueueStats ¶
func (a *App) GetQueueStats() (QueueStats, error)
GetQueueStats returns statistics about the queue via queue
func (*App) GetRunningJobs ¶
func (a *App) GetRunningJobs() ([]processor.RunningJobItem, error)
GetRunningJobs returns currently running jobs from the processor
func (*App) GetRunningJobsDetails ¶ added in v0.0.13
func (a *App) GetRunningJobsDetails() ([]processor.RunningJobDetails, error)
GetRunningJobsDetails returns detailed information about currently running jobs
func (*App) GetWatchDirectory ¶
GetWatchDirectory returns the current watch directory
func (*App) GetWatcherStatus ¶ added in v0.0.24
func (a *App) GetWatcherStatus() watcher.WatcherStatusInfo
GetWatcherStatus returns the current status of the watcher
func (*App) HandleDroppedFiles ¶
HandleDroppedFiles processes files that are dropped onto the application window
func (*App) HasPendingConfigChanges ¶ added in v0.0.13
HasPendingConfigChanges returns whether there are pending config changes
func (*App) IsLegacyDatabase ¶ added in v0.0.22
IsLegacyDatabase checks if the database is a legacy (non-goose) database
func (*App) IsProcessingAutoPaused ¶ added in v0.0.20
IsProcessingAutoPaused returns whether the processor was automatically paused due to provider unavailability
func (*App) IsProcessingPaused ¶ added in v0.0.14
IsProcessingPaused returns whether the processor is currently paused
func (*App) IsUploading ¶
IsUploading returns whether any uploads are in progress (via processor)
func (*App) NavigateToDashboard ¶
func (a *App) NavigateToDashboard()
NavigateToDashboard emits an event to navigate to the dashboard page
func (*App) NavigateToSettings ¶
func (a *App) NavigateToSettings()
NavigateToSettings emits an event to navigate to the settings page
func (*App) PauseProcessing ¶ added in v0.0.14
PauseProcessing pauses the processor to prevent new jobs from starting
func (*App) RecreateDatabase ¶ added in v0.0.22
RecreateDatabase drops all tables and recreates them using migrations
func (*App) RemoveFromQueue ¶
RemoveFromQueue removes an item from the queue via queue
func (*App) ResetDatabase ¶ added in v0.0.22
ResetDatabase drops all tables and re-runs all migrations
func (*App) ResumeProcessing ¶ added in v0.0.14
ResumeProcessing resumes the processor to allow new jobs to start
func (*App) RollbackMigration ¶ added in v0.0.22
RollbackMigration rolls back the last applied migration
func (*App) RunMigrations ¶ added in v0.0.22
RunMigrations runs all pending migrations
func (*App) SaveConfig ¶
func (a *App) SaveConfig(configData *config.ConfigData) error
SaveConfig saves the configuration
func (*App) SelectConfigFile ¶
SelectConfigFile allows user to select a config file
func (*App) SelectOutputDirectory ¶
SelectOutputDirectory allows user to select an output directory
func (*App) SelectTempDirectory ¶
SelectTempDirectory allows user to select a temporary directory for PAR2 files
func (*App) SelectWatchDirectory ¶
SelectWatchDirectory allows user to select a watch directory
func (*App) SetQueueItemPriority ¶
SetQueueItemPriority updates the priority of a pending queue item by id and reorders the queue
func (*App) SetWebEventEmitter ¶
SetWebEventEmitter sets the event emitter function for web mode
func (*App) SetWebMode ¶
SetWebMode sets the application to web mode
func (*App) SetupWizardComplete ¶ added in v0.0.7
func (a *App) SetupWizardComplete(wizardData SetupWizardData) error
SetupWizardComplete saves the configuration from the setup wizard
func (*App) Shutdown ¶ added in v0.0.16
func (a *App) Shutdown()
Shutdown gracefully shuts down the application and closes all resources
func (*App) Startup ¶
Startup is called when the app starts. The context is saved so we can call the runtime methods
func (*App) TestProviderConnectivity ¶ added in v0.0.20
func (a *App) TestProviderConnectivity(serverData ServerData) ValidationResult
TestProviderConnectivity tests an individual provider's connectivity using the new nntppool method
func (*App) UploadFiles ¶
UploadFiles uploads the selected files using the queue system
func (*App) ValidateNNTPServer ¶ added in v0.0.7
func (a *App) ValidateNNTPServer(serverData ServerData) ValidationResult
ValidateNNTPServer validates an NNTP server configuration using TestProviderConnectivity
type AppPaths ¶
AppPaths holds the various paths needed by the application
func GetAppPaths ¶
GetAppPaths returns the appropriate paths for the current operating system
type AppStatus ¶ added in v0.0.8
type AppStatus struct {
HasConfig bool `json:"hasConfig"`
ConfigPath string `json:"configPath"`
Uploading bool `json:"uploading"`
CriticalConfigError bool `json:"criticalConfigError"`
Error string `json:"error"`
IsFirstStart bool `json:"isFirstStart"`
HasServers bool `json:"hasServers"`
ServerCount int `json:"serverCount"`
ValidServerCount int `json:"validServerCount"`
ConfigValid bool `json:"configValid"`
NeedsConfiguration bool `json:"needsConfiguration"`
}
AppStatus represents the current application status
type CompressedMetrics ¶ added in v0.0.20
type CompressedMetrics struct {
Timestamp string `json:"timestamp"`
Period string `json:"period"` // "daily" or "weekly"
TotalBytesUploaded int64 `json:"totalBytesUploaded"`
TotalArticlesPosted int64 `json:"totalArticlesPosted"`
AverageUploadSpeed float64 `json:"averageUploadSpeed"`
AverageSuccessRate float64 `json:"averageSuccessRate"`
TotalErrors int64 `json:"totalErrors"`
AverageConnections float64 `json:"averageConnections"`
}
CompressedMetrics represents compressed historical metrics for daily/weekly periods (legacy)
type MetricSummary ¶ added in v0.0.20
type MetricSummary struct {
StartTime string `json:"startTime"`
EndTime string `json:"endTime"`
TotalConnectionsCreated int64 `json:"totalConnectionsCreated"`
TotalConnectionsDestroyed int64 `json:"totalConnectionsDestroyed"`
TotalAcquires int64 `json:"totalAcquires"`
TotalReleases int64 `json:"totalReleases"`
TotalErrors int64 `json:"totalErrors"`
TotalRetries int64 `json:"totalRetries"`
TotalAcquireWaitTime int64 `json:"totalAcquireWaitTime"`
TotalBytesDownloaded int64 `json:"totalBytesDownloaded"`
TotalBytesUploaded int64 `json:"totalBytesUploaded"`
TotalArticlesRetrieved int64 `json:"totalArticlesRetrieved"`
TotalArticlesPosted int64 `json:"totalArticlesPosted"`
TotalCommandCount int64 `json:"totalCommandCount"`
TotalCommandErrors int64 `json:"totalCommandErrors"`
AverageConnectionsPerHour float64 `json:"averageConnectionsPerHour"`
AverageErrorRate float64 `json:"averageErrorRate"`
AverageSuccessRate float64 `json:"averageSuccessRate"`
AverageAcquireWaitTime int64 `json:"averageAcquireWaitTime"`
WindowCount int `json:"windowCount"`
}
MetricSummary represents aggregated metrics for a time period
type NntpPoolMetrics ¶ added in v0.0.16
type NntpPoolMetrics struct {
Timestamp string `json:"timestamp"`
Uptime float64 `json:"uptime"`
ActiveConnections int `json:"activeConnections"`
UploadSpeed float64 `json:"uploadSpeed"`
CommandSuccessRate float64 `json:"commandSuccessRate"`
ErrorRate float64 `json:"errorRate"`
TotalAcquires int64 `json:"totalAcquires"`
TotalBytesUploaded int64 `json:"totalBytesUploaded"`
TotalArticlesRetrieved int64 `json:"totalArticlesRetrieved"`
TotalArticlesPosted int64 `json:"totalArticlesPosted"`
AverageAcquireWaitTime float64 `json:"averageAcquireWaitTime"`
TotalErrors int64 `json:"totalErrors"`
Providers []NntpProviderMetrics `json:"providers"`
// Daily and Weekly compressed metrics from nntppool v1.3.1+
DailyMetrics *MetricSummary `json:"dailyMetrics,omitempty"`
WeeklyMetrics *MetricSummary `json:"weeklyMetrics,omitempty"`
}
NntpPoolMetrics represents NNTP connection pool metrics
type NntpProviderMetrics ¶ added in v0.0.16
type NntpProviderMetrics struct {
Host string `json:"host"`
Username string `json:"username"`
State string `json:"state"`
TotalConnections int `json:"totalConnections"`
MaxConnections int `json:"maxConnections"`
AcquiredConnections int `json:"acquiredConnections"`
IdleConnections int `json:"idleConnections"`
TotalBytesUploaded int64 `json:"totalBytesUploaded"`
TotalArticlesPosted int64 `json:"totalArticlesPosted"`
SuccessRate float64 `json:"successRate"`
AverageConnectionAge float64 `json:"averageConnectionAge"`
}
NntpProviderMetrics represents metrics for individual NNTP providers
type PaginatedQueueResult ¶ added in v0.0.26
type PaginatedQueueResult struct {
Items []QueueItem `json:"items"`
TotalItems int `json:"totalItems"`
TotalPages int `json:"totalPages"`
CurrentPage int `json:"currentPage"`
ItemsPerPage int `json:"itemsPerPage"`
HasNext bool `json:"hasNext"`
HasPrev bool `json:"hasPrev"`
}
PaginatedQueueResult contains paginated queue items and metadata
type PaginationParams ¶ added in v0.0.26
type PaginationParams struct {
Page int `json:"page"` // 1-based page number
Limit int `json:"limit"` // Items per page
SortBy string `json:"sortBy"` // Sort field: "created", "priority", "status", "filename"
Order string `json:"order"` // Sort order: "asc", "desc"
}
PaginationParams defines parameters for paginated queries
type ProcessorStatus ¶ added in v0.0.8
type ProcessorStatus struct {
HasProcessor bool `json:"hasProcessor"`
RunningJobs int `json:"runningJobs"`
RunningJobIDs []string `json:"runningJobIDs"`
}
ProcessorStatus represents the current processor status
type QueueItem ¶
type QueueItem struct {
ID string `json:"id"`
Path string `json:"path"`
FileName string `json:"fileName"`
Size int64 `json:"size"`
Status string `json:"status"`
RetryCount int `json:"retryCount"`
Priority int `json:"priority"`
ErrorMessage *string `json:"errorMessage"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`
CompletedAt *time.Time `json:"completedAt"`
NzbPath *string `json:"nzbPath"`
}
QueueItem represents a queue item for the frontend - matches queue.QueueItem
type QueueStats ¶ added in v0.0.8
type QueueStats struct {
Total int `json:"total"`
Pending int `json:"pending"`
Running int `json:"running"`
Complete int `json:"complete"`
Error int `json:"error"`
}
QueueStats represents queue statistics
type ServerData ¶ added in v0.0.7
type ServerData struct {
Host string `json:"host"`
Port int `json:"port"`
Username string `json:"username"`
Password string `json:"password"`
SSL bool `json:"ssl"`
MaxConnections int `json:"maxConnections"`
}
ServerData represents the server configuration data from the frontend
type SetupWizardData ¶ added in v0.0.7
type SetupWizardData struct {
Servers []ServerData `json:"servers"`
OutputDirectory string `json:"outputDirectory"`
WatchDirectory string `json:"watchDirectory"`
}
SetupWizardData represents the complete setup wizard data from the frontend
type ValidationResult ¶ added in v0.0.7
ValidationResult represents the result of server validation