Add raw export reanalyze flow for Redfish snapshots
This commit is contained in:
@@ -29,6 +29,7 @@ type Server struct {
|
||||
mu sync.RWMutex
|
||||
result *models.AnalysisResult
|
||||
detectedVendor string
|
||||
rawExport *RawExportPackage
|
||||
|
||||
jobManager *JobManager
|
||||
collectors *collector.Registry
|
||||
@@ -107,6 +108,22 @@ func (s *Server) GetResult() *models.AnalysisResult {
|
||||
return s.result
|
||||
}
|
||||
|
||||
func (s *Server) SetRawExport(pkg *RawExportPackage) {
|
||||
s.mu.Lock()
|
||||
defer s.mu.Unlock()
|
||||
s.rawExport = pkg
|
||||
}
|
||||
|
||||
func (s *Server) GetRawExport() *RawExportPackage {
|
||||
s.mu.RLock()
|
||||
defer s.mu.RUnlock()
|
||||
if s.rawExport == nil {
|
||||
return nil
|
||||
}
|
||||
cloned := *s.rawExport
|
||||
return &cloned
|
||||
}
|
||||
|
||||
// SetDetectedVendor sets the detected vendor name
|
||||
func (s *Server) SetDetectedVendor(vendor string) {
|
||||
s.mu.Lock()
|
||||
|
||||
Reference in New Issue
Block a user