in client/sql/sparksession.go [128:143]
func (s *sparkSessionImpl) executePlan(plan *proto.Plan) (proto.SparkConnectService_ExecutePlanClient, error) {
request := proto.ExecutePlanRequest{
SessionId: s.sessionId,
Plan: plan,
UserContext: &proto.UserContext{
UserId: "na",
},
}
// Append the other items to the request.
ctx := metadata.NewOutgoingContext(context.Background(), s.metadata)
executePlanClient, err := s.client.ExecutePlan(ctx, &request)
if err != nil {
return nil, fmt.Errorf("failed to call ExecutePlan in session %s: %w", s.sessionId, err)
}
return executePlanClient, nil
}