#1
|
|||
|
|||
![]()
Hi.
Is there any way to make jdownload2 ignore download links that are slow to download? For example if i have 2 files: The first downloaded with 5mb/sec and the other one with 1mb/sec. I want to continue download the fast and ignore the slow. Can i do that? If i can how exactly do it? Doesn't matter the host or the link or the file. |
#2
|
||||
|
||||
![]()
@Agnostos: moved your thread here because I think I remember such a script already exists, see https://board.jdownloader.org/showthread.php?t=70525
__________________
JD-Dev & Server-Admin |
#3
|
|||
|
|||
![]()
So there is a way or not?
Cause i go to the link you mention but i don't understand at all. |
#4
|
||||
|
||||
![]()
@Agnostos: It's not supported out of the box but can be achieved with help of community provided scripts for Eventscripter. That's why I linked the link to the script thread where you should find the script, use search. Or ask @mgpai for further help on this one
__________________
JD-Dev & Server-Admin |
#5
|
|||
|
|||
![]() Code:
/* disable slow link trigger : interval */ var running = getRunningDownloadLinks().filter(function(link) { return link.downloadDuration > 30000; }); if (running.length == 2) { running.sort(function(a, b) { return a.speed > b.speed; })[0].enabled = false; } |
#6
|
|||
|
|||
![]()
How exactly add this to jd2?
And does it work for all links all hosts? I try to add it with copy/paste at settings->event script-> add but doesn't work still download from links with kb/sec and doesn't ignore them to download from faster links mb/sec Last edited by Agnostos; 22.02.2025 at 07:47. |
#7
|
||||
|
||||
![]()
@Agnostos: Maybe you should have been more specific about what you have in mind exactly? mgpai provided a script that stops the slower of two links in package.
or did you mean just stop any link below certain speed?
__________________
JD-Dev & Server-Admin |
#8
|
|||
|
|||
![]() Quote:
|
#9
|
||||
|
||||
![]()
@mgpai: I guess he just wants to stop slow downloads and was just giving example with 2 downloads. We will found out once he has answered
![]()
__________________
JD-Dev & Server-Admin |
#10
|
|||
|
|||
![]()
I believe i describe what exactly want at my 1st post.
I tell a example. I have 2 or more links. 1 of all download with 200kb/sec the other one above 1mb/sec Simply i want the script pause or pass to the next link until it find a link it download for big speed than for example 1mb/sec. I want to filter all slow links below 100kb/sec to pass to the next and if downloades above 500kb/sec it continue download it or else pass to the next one. Can i do that? |
#11
|
|||
|
|||
![]()
NO!. What you have described here is entirely different from your original request.
Code:
/* skip slow downloads trigger : interval note : set interval to 30000 or more */ var speed = 100 // speed in KB/sec getRunningDownloadLinks().forEach(function(link) { link.downloadDuration > 30000 && link.speed < speed * 1000 & link.setSkipped(true); }) |
#12
|
|||
|
|||
![]()
So i copy this.
And if i want i change the var speed with the lower speed i want to link skipped the number 30000 what is for? I make a test but it is slow. it skipped the slow download after 15-20% of download progress. Can i make it skipped it almost instantly until 1-5% I try with 200kb/sec but there is one more issue for the end of quick download link that the speed slow down it skipped that link/file to Please explain to me the above scrip. Last edited by Agnostos; 25.02.2025 at 12:11. |
#13
|
|||
|
|||
![]()
To 'skip' the downloads faster, experiment with reduced interval and/or duration values.
Code:
/* skip slow downloads trigger : interval (milliseconds) IMPORTANT : enable "synchronous execution" in top panel */ var speed = 200 // speed limit KB/sec var duration = 30 // skip only after link has been downloading for at least x seconds var downloaded = 5 // skip download only if less than x % has been downloaded getRunningDownloadLinks().forEach(function(link) { if ( link.downloadDuration > duration * 1000 && link.speed < speed * 1000 && link.bytesLoaded / link.bytesTotal * 100 < downloaded ) { link.setSkipped(true); } }) |
#14
|
|||
|
|||
![]()
A lot of thanks.
|
![]() |
Thread Tools | |
Display Modes | |
|
|