Net-UpYun

 view release on metacpan or  search on metacpan

README  view on Meta::CPAN


  put($path,$bytes)
        # it will auto mkdir.
        my $ok = $upyun->put('/demo/1.txt','okokok');

    Upload content to the file, it will auto create directories.

    NOTE: According UpYun note, max directories deep level is limited to 10,
    be careful.

  get($path)
        say $upyun->get('/demo/1.txt');

    Get the file content.

  delete($path)
        my $ok = $upyun->delete('/demo/1.txt');

    Delete the file.

  reponse
        my $http_response = $upyun->response;

    Returns latest response,it's an instance of HTTP::Response.

  res_content
    Raw response content body.

  is_success
  is_error
    These methods indicate if the response was informational, successful, or
    an error. If the response code was 2xx code, is_success is true, else
    is_error is true.

  error_code
    The code is a 3 digit number that encode the overall outcome of the last
    HTTP response.

  error_message
    The message is a short human readable single line string that explains
    the last response code.

  do_request
    Internal, send signed request to server.

  sign
    Private.

TODOS
    Much jobs to do.

    *   handy client shell.

    *   copy/move file under same bucket or between different bucket.

    *   simple check file exists on remote ,no need to fetch its
        content,save bandwidth.

    *   display/compare files checksum(MD5) local and remote.

    *   streaming upload to save memory.

    *   useful utility, like tar/untar to/from upyun on fly.

    *   multi operation and performance requests in parallel.

    *   code clean and refactory.

AUTHOR
    Night Sailer(Pan Fan) <nightsailer{at}gmail_dot_com>

COPYRIGHT
    Copyright (C) Pan Fan(nightsailer)

LICENSE
    This library is free software; you can redistribute it and/or modify it
    under the same terms as Perl itself.



( run in 0.484 second using v1.01-cache-2.11-cpan-39bf76dae61 )