You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

server_pod.go 855 B

1234567891011121314151617181920212223242526272829303132
  1. package server
  2. import (
  3. "context"
  4. "gitlink.org.cn/JCCE/PCM/adaptor/pod_adaptor/server/pod"
  5. "gitlink.org.cn/JCCE/PCM/lan_trans/idl/pbpod"
  6. "github.com/golang/glog"
  7. "google.golang.org/grpc/codes"
  8. "google.golang.org/grpc/status"
  9. )
  10. // ListPodDetail return pod detail
  11. func (s *Server) ListPodDetail(ctx context.Context, req *pbpod.ListDetailReq) (*pbpod.ListDetailResp, error) {
  12. resp, err := pod.ListDetail(ctx, req)
  13. if err != nil {
  14. glog.Errorf("ListPodDetail error %+v", err)
  15. return nil, status.Errorf(codes.Internal, err.Error())
  16. }
  17. return resp, nil
  18. }
  19. //ListPod return pod list
  20. func (s *Server) ListPod(ctx context.Context, req *pbpod.ListReq) (*pbpod.ListResp, error) {
  21. resp, err := pod.List(ctx, req)
  22. if err != nil {
  23. glog.Errorf("ListPod error %+v", err)
  24. return nil, status.Errorf(codes.Internal, err.Error())
  25. }
  26. return resp, nil
  27. }

PCM is positioned as Software stack over Cloud, aiming to build the standards and ecology of heterogeneous cloud collaboration for JCC in a non intrusive and autonomous peer-to-peer manner.