upload module to CPAN (http client)

L

Loofort

Hello all.
I'm developing perl http and ftp clients and want to upload it to
CPAN. It's my very first time. http://perldoc.perl.org/perlnewmod.html
told that it is good idea to discuss module with folk before upload.
So please point me to the right direction if I'm doing something
wrong. Here is short description :
- it works under linux
- based on EV and Coro
- support http/1.1, https, socks5
- several times faster than Coro::LWP

I think to prefix packages with "CTX" - meaning "context" since http
(and specially ftp) works in context - pass the cookies, understand
relative links, keep alive connections etc.
Here is file distribution:
CTX/
HTTP.pm - CTX::HTTP - based on CTX::EV::HTTP and used Coro
FTP.pm - CTX::FTP (similar to CTX::HTTP)
EV/
HTTP.pm - CTX::EV::HTTP based on EV event loop, get
CTX::EV::Socket (or Socks5 ) as connection constructor (cc)
FTP.pm - CTX::EV::FTP similar to CTX::EV::HTTP
FTP/
Command.pm
Data.pm
Socket.pm - CTX::EV::Socket - cc
Socks5.pm - CTX::EV::Socks5, get CTX::EV::Socket or
CTX::EV::Socks5 as cc


The simple example bellow makes 100 requests simultaneously :

use strict;
use CTX::HTTP;

async {
my $http = CTX::HTTP->new();
my $resp = $http->get('http://www.example.com/');
print "response code: ".$resp->code."\n";
} foreach (1..100);

EV::loop;
 
L

Loofort

It's signed by CAcert. Your browser probably doesn't have the root
certificate for that CA installed. You can get it fromhttp://www.cacert.org/index.php?id=3. (orhttps://www.cacert.org/index.php?id=3but there your browser will
complain about an invalid certificate, too).

        hp


Thanks all for the links. let's see the variants.
First I need to decide should it be top-level namespace? my first
thought was yes, since I create a set of modules and want to group it
under "one roof". And should it be descriptive name like CTX:: or
Multiple:: , Multi:: ; or can be like caption, brend name :) like
Loofort:: or some.
From the other hand it can be non top-level namespace. Maybe some
thing like NET::HTTP::Multy and NET::FTP::Multy. or this variant
Coro::Loofort:: or Coro::CTX::

It's hard to choose. currently I prefere the top-level namespace
Multy:: .
what you think?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,186
Members
46,740
Latest member
JudsonFrie

Latest Threads

Top