CurlAxel - PHP file download accelerator

Status
Not open for further replies.
Good script, and most definitely good effort right there. But a quick look through it, and the way you're accelerating downloads (using Curl) is not efficient at all. As it stands, curl/php is not good with file streaming/handling. And curl was most definitely not built with multi threaded downloading as it's pioneer or trump feature; it's just there.

I'll go through it in detail and suggest improvements. But beyond that, good effort.

Google 'Aria2' and then Google 'Aria2Web'. Then look through Aria2Web and see if you can create a simpler class based on that for users of WJ. Aria2 is an excellent command line download accelerator for Linux; and coding a PHP XML-RPC gateway for it, which is simpler (and works) would be a great idea.

i will work on it, i've already started studying it. But i don't want to drop the current project, the aria wrapper will be another project. Because Aria is really good, but those who want to make very small yet smart script, CurlAxel would be better :)
 
Hi, Lifetalk,

JokerHacker's idea was originated from my thread here, we already had this discussion, as mentioned in that thread Aria's XML-RPC is very badly documented so it'll be very hard to build as scripts as such with Aria's API, if you're able to prove us wrong, feel free to do so ;)

The XML documentation is non-existent, true. BUT, remember that there's already 2 PHP implementations out there - it's a matter of picking code from one of them, because as it stands, it's way too feature rich (most of them, if not all, not needed). Documentation is not necessary, as long as you have code out there to work with ;)
 
The XML documentation is non-existent, true. BUT, remember that there's already 2 PHP implementations out there - it's a matter of picking code from one of them, because as it stands, it's way too feature rich (most of them, if not all, not needed). Documentation is not necessary, as long as you have code out there to work with ;)

i'll use class-IXR Library for the xmlrpc client :D

Robin H, me too xD
 
Good job.

As pretty much everyone on here has heard me say before though, choosing PHP to code some application in which has large amounts of data handling and transfer isn't the best idea. Either way you do it, it'll use quite the amount of memory compared to other languages.

Also do note that download accelerators (in theory, technically) are completely useless unless the server you're downloading from forces some speed limit. Downloading some file at your full speed is obviously going to be the same speed as downloading that same file in multiple streams.

Like I said though, good job.

P.S. Best part of that code is the regex, even if you didn't write it yourself, just because regex is awesome (I wrote 30 lines of it yesterday).
 
Last edited:
Good job.

As pretty much everyone on here has heard me say before though, choosing PHP to code some application in which has large amounts of data handling and transfer isn't the best idea. Either way you do it, it'll use quite the amount of memory compared to other languages.
.

Unless you use a third party application via it's XML-RPC based API to handle the downloads; then you're just using PHP as an interface of sorts with the file handling being left to the actual application that was designed to do just that ;)
 
Jokerhacker, I don't mean to bother you too much, but can you explain me how I can integrate your script with Rapidleech, so passing on the download properties, and then the download progress back to Rapidleech?

Thank you

(also feel free to contact me by PM or MSN!)
 
No mean to be an ass, but if someone wants to run this faster, they should use a system command using the software called axel. With cURL, the only upside I can think of is that you can return it into a string faster, but on the user-end it will be just as slow... ? Or is the only advantage just the fact that you don't have to install any extra software? eitherway, congrats on the script, nicely coded.

^oh, and it will be less strain on the server if it was via command line right?
 
No mean to be an ass, but if someone wants to run this faster, they should use a system command using the software called axel. With cURL, the only upside I can think of is that you can return it into a string faster, but on the user-end it will be just as slow... ? Or is the only advantage just the fact that you don't have to install any extra software? eitherway, congrats on the script, nicely coded.

^oh, and it will be less strain on the server if it was via command line right?
Hi, again, we had this same discussion in another thread, JokerHacker said he could create a PHP based (CURL) download accelerator, that's why he made it.

Feel free to give us some input in this thread, thanks ^_^
 
Last edited by a moderator:
Jokerhacker, I don't mean to bother you too much, but can you explain me how I can integrate your script with Rapidleech, so passing on the download properties, and then the download progress back to Rapidleech?

Thank you

(also feel free to contact me by PM or MSN!)

Well, it's not about bothering me, but to be honest, i have RL's code and i never understood it xD
Maybe someone who understands it can integrate it :)
 
No mean to be an ass, but if someone wants to run this faster, they should use a system command using the software called axel. With cURL, the only upside I can think of is that you can return it into a string faster, but on the user-end it will be just as slow... ? Or is the only advantage just the fact that you don't have to install any extra software? eitherway, congrats on the script, nicely coded.

^oh, and it will be less strain on the server if it was via command line right?

this class would be used for some purposes, maybe someone who wants (as i said before) a very lightweight script yet smart.
I'm working on another one using Aria2 :) it will be way more efficient B-)
 
Last edited by a moderator:
Unless you use a third party application via it's XML-RPC based API to handle the downloads; then you're just using PHP as an interface of sorts with the file handling being left to the actual application that was designed to do just that ;)

I already did that, somewhere in my collection of random things i've coded ;)
 
Status
Not open for further replies.
Back
Top