in client/sql/dataframewriter.go [37:68]
func (w *dataFrameWriterImpl) Save(path string) error {
saveMode, err := getSaveMode(w.saveMode)
if err != nil {
return err
}
var source *string
if w.formatSource != "" {
source = &w.formatSource
}
plan := &proto.Plan{
OpType: &proto.Plan_Command{
Command: &proto.Command{
CommandType: &proto.Command_WriteOperation{
WriteOperation: &proto.WriteOperation{
Input: w.relation,
Mode: saveMode,
Source: source,
SaveType: &proto.WriteOperation_Path{
Path: path,
},
},
},
},
},
}
responseClient, err := w.sparkSession.executePlan(plan)
if err != nil {
return err
}
return consumeExecutePlanClient(responseClient)
}