MCPcopy Index your code
hub / github.com/APIParkLab/APIPark / List

Method List

module/plugin-cluster/iml.go:99–117  ·  view source on GitHub ↗
(ctx context.Context, clusterId string)

Source from the content-addressed store, hash-verified

97}
98
99func (m *imlPluginClusterModule) List(ctx context.Context, clusterId string) ([]*dto.Item, error) {
100
101 configPartitions, err := m.service.ListCluster(ctx, clusterId, plugin_model.OpenKind)
102 if err != nil {
103 return nil, err
104 }
105 return utils.SliceToSlice(configPartitions, func(s *plugin_cluster.ConfigPartition) *dto.Item {
106 return &dto.Item{
107
108 Name: s.Plugin,
109 Cname: s.Cname,
110 Desc: s.Desc,
111 Extend: s.Extend,
112 Operator: auto.UUIDP(s.Operator),
113 Update: (*auto.TimeLabel)(s.Update),
114 Create: (*auto.TimeLabel)(s.Create),
115 }
116 }), nil
117}
118
119func (m *imlPluginClusterModule) Get(ctx context.Context, clusterId string, name string) (config *dto.PluginOutput, render plugin_model.Render, er error) {
120 if clusterId == "" {

Callers

nothing calls this directly

Calls 1

ListClusterMethod · 0.65

Tested by

no test coverage detected