Add 2 parameters to Start-ThreadJob: timeout seconds, priority
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 24/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Ferma
- Stack tecnologico
- powershell
- Ambito
- backend
Direzione di ricerca
Start by reading the Start-ThreadJob implementation and its tests to understand how jobs are created and scheduled; the issue names no files or tests. The requested work is adding timeout seconds and priority parameters, with priority 1 running first and a default of 5. Define what happens when a timeout expires, including whether the job is removed, then add coverage for the agreed behavior.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Summary of the new feature / enhancement
Add 2 parameters to Start-ThreadJob: timeout seconds, priority
Proposed technical implementation details (optional)
priority:
A single asynchronous task has no timeout and no priority, It is very original.
The priority range is 1-9, and the default is 5,priority 1 will be executed first.
timeoutseconds:
For that things, I think thread-timeout is a good medicine:
- can not stop Invoke-WebRequest / Invoke-RestMethod by ctrl + c .see:
https://github.com/PowerShell/PowerShell/issues/16145 - “Shit-mountain-code”
- HANG
The regularity of unpredictable execution time - Regular expression for a long time and unpredictable time.
- Code executed remotely.
- memory leaks
- cpu 100%
like:
golang : “context.WithTimeout”
python : timeout* in threading lib
It is better to add a Boolean type of parameter : -AutoRemoveJob
whether to automatically remove threadjob after timeout,
parameter likes “receive-job -AutoRemoveJob”
In this way, users can only consider new thread and put ps1 script code.
both "ForEach-Object -Parallel" and "Start-ThreadJob" without timeout, This has seriously affected my development of "kasini3000" at present.
Powershell community do a "engine",i do a "car". the car is kasini3000 and k4t .
I love powershell. I want to give my opinion to the engine.
I hope the engine factory can transform a better engine.
I think timeoutseconds can make the ps1 script in the thread more robust.
I hope powershell will become stronger and stronger.
- Lingua principale
- PowerShell
- Stelle
- 37
- Fork
- 22
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di PowerShell/ThreadJob
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
PowerShell/ThreadJob#59 · 1 reazione ·
-
enhancement
Difficoltà 3/5 1-2 giorni Idoneità per principianti 56/100
PowerShell/ThreadJob#56 · 1 reazione ·
-
Set alias for ThreadJob command(s)Forse già presa @kilasuit l’ha presa 89 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 20/100
PowerShell/ThreadJob#45 · 1 commento ·
-
Difficoltà 1/5 1-3 ore Idoneità per principianti 48/100
PowerShell/ThreadJob#44 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
PowerShell/ThreadJob#43 ·
Tutte le issue di PowerShell/ThreadJob
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Backend issue lists report in-patch warnings and out-of-patch errors as not publishableForse già presa @RaphaelFakhri l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
mozilla/code-review#3794 ·
I maintainer di solito rispondono entro 1 giorno
-
Upgrade listener stays on a custom server after close when `preClose` is setForse già presa @RaphaelFakhri l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
fastify/fastify-websocket#388 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
DietrichGebert/ponytail#1343 ·
I maintainer di solito rispondono entro 1 giorno