保存文件到云上，阻塞直到保存成功返回

@param path 文件相对路径
@param data 文件内容
@return successful/unsuccessful unit response
779721
@SuppressWarnings("unused")
    public static Completable save(String path, String data) {
        Map<String, Object> map = new HashMap<String, Object>() {{
            put("path", path);
            put("data", data);
        }};
        return SingleRxXian.call("cosService", "cosWrite", map).toCompletable();
    }
1237099
public String getData(String path) throws ZooKeeperException {
        byte[] data = getDataRaw(path);
        return data != null ? new String(data, UTF8) : null;
    }
1366800
public Response put(String path) throws IOException, RESTException {
        return put(path, null, null);
    }
818101
public GetData get(String path) {
        GetData command = new GetData();
        command.path(path);
        action.setCommand(command);
        return command;
    }
117822
public boolean load(String path)
    {
        String binPath = path + Predefine.BIN_EXT;
        if (load(ByteArrayStream.createByteArrayStream(binPath))) return true;
        if (!loadTxt(path)) return false;
        try
        {
            logger.info("正在缓存" + binPath);
            DataOutputStream out = new DataOutputStream(IOUtil.newOutputStream(binPath));
            save(out);
            out.close();
        }
        catch (Exception e)
        {
            logger.warning("缓存" + binPath + "失败：\n" + TextUtility.exceptionToString(e));
        }

        return true;
    }
955698
def post(self, path, data=None):
        """"""
        data = data or {}
        response = requests.post(self.url(path), data=to_json(data), headers=self.request_header())
        return self.parse_response(response)
736962
public boolean setData(String path, String value, boolean createNodes)
            throws ZooKeeperException {
        return _write(path, value != null ? value.getBytes(UTF8) : null, createNodes);
    }
58590
public void writeToFile(String path) {
        try {
            try (OutputStream os = new FileOutputStream(path)) {
                InputStreams.transferTo(body(), os);
            }
        } catch (IOException e) {
            throw new RequestsException(e);
        } finally {
            close();
        }
    }
266544
public function write($path, array $data = [])
    {
        return $this->post($this->buildPath($path), ['body' => json_encode($data)]);
    }
626175
public static String readResource(String path) {
        try {
            File file = ResourceUtil.getResourceFile(path);
            return ResourceUtil.readFromFileIntoString(file);
        } catch (Exception e) {
            throw new DataUtilException("Failed to load resource", e);
        }
    }
978306
def save(self, path):
        

        data = self.encode()

        with open(path, "wb") as out:
            out.write(data)
286866
public Response put(String path, Formattable data) throws AuthyException {
        return request(Resource.METHOD_PUT, path, data, getDefaultOptions());
    }
72923
public FSDataOutputStream create(Path f, Progressable progress) throws IOException {
    return create(f, CreateOptions.progress(progress)); 
  }
860384
public static void saveTo(String path, InputStream in) throws IOException {
        if (in == null)
            throw new IllegalArgumentException("input stream cannot be null");
        if (path == null)
            throw new IllegalArgumentException("path cannot be null");

        try (OutputStream out = new BufferedOutputStream(
                                        Files.newOutputStream(
                                                Paths.get(path), 
                                                StandardOpenOption.CREATE, 
                                                StandardOpenOption.APPEND))) {
            byte[] bytes = new byte[1024];
            for (int x = in.read(bytes); x != -1; x = in.read(bytes))
                out.write(bytes, 0, x);
        }
    }
1349102
public static void saveFile(String path, String content) throws IOException {
        saveFile(path, content, false);
    }
844609
public String get(String path, Response data) {
		return request("GET", path, data, getDefaultOptions());
	}
980373
public function create($path, array $data)
    {
        $data = array_merge($data, ['path' => $path]);

        return File::create($data);
    }