mirror of https://github.com/grafana/grafana.git
				
				
				
			Scopes: increase limit on list calls to storage (#92687)
scopes: increase limit on list calls to storage Signed-off-by: bergquist <carl.bergquist@gmail.com>
This commit is contained in:
		
							parent
							
								
									c0b2fafd5e
								
							
						
					
					
						commit
						56d35d32e2
					
				|  | @ -71,7 +71,7 @@ func (r *findREST) Connect(ctx context.Context, name string, opts runtime.Object | |||
| 		results := &scope.FindScopeNodeChildrenResults{} | ||||
| 
 | ||||
| 		raw, err := r.scopeNodeStorage.List(ctx, &internalversion.ListOptions{ | ||||
| 			Limit: 1000, | ||||
| 			Limit: 10000, | ||||
| 		}) | ||||
| 
 | ||||
| 		if err != nil { | ||||
|  | @ -80,6 +80,7 @@ func (r *findREST) Connect(ctx context.Context, name string, opts runtime.Object | |||
| 		} | ||||
| 
 | ||||
| 		all, ok := raw.(*scope.ScopeNodeList) | ||||
| 
 | ||||
| 		if !ok { | ||||
| 			responder.Error(fmt.Errorf("expected ScopeNodeList")) | ||||
| 			return | ||||
|  |  | |||
|  | @ -64,7 +64,9 @@ func (f *findScopeDashboardsREST) Connect(ctx context.Context, name string, opts | |||
| 	} | ||||
| 
 | ||||
| 	return http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) { | ||||
| 		raw, err := f.scopeDashboardStorage.List(ctx, &internalversion.ListOptions{}) | ||||
| 		raw, err := f.scopeDashboardStorage.List(ctx, &internalversion.ListOptions{ | ||||
| 			Limit: 10000, | ||||
| 		}) | ||||
| 		if err != nil { | ||||
| 			w.WriteHeader(500) | ||||
| 			return | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue