Responsável por retornar o status do threadpool que recebeu a requisição
Sintaxe
getThreadPoolStatus()
Retorno
Nome | Tipo | Descrição |
---|---|---|
nStatus | numérico | Retorna qual é o estado do thread pool 0 - STOPPED , 1 - STARTING, 2 - STARTED, 3 - STOPPING0−STOPPED,1−STARTING,2−STARTED,3−STOPPING |
Observações
- Para visualizar o exemplo, execute seu serviço rest com a URI: /documentation/getThreadPoolStatus
Exemplos
#include "tlpp-core.th" #include "tlpp-rest.th" @Get('/documentation/getThreadPoolStatus') function u_fGetThreadPoolStatus() local aStatus := {"STOPPED","STARTING","STARTED","STOPPING"} local cResponse := "" local nRet := oRest:getThreadPoolStatus() if (valtype(nRet) == 'N') cResponse := '{"getThreadPoolStatus":"O status do threadpool ' + oRest:getThreadPoolName() + " eh: " + cValToChar(nRet) + "(" + aStatus[nRet] + ")" + '"}' else cResponse := '{"getThreadPoolStatus": "metodo getThreadPoolStatus nao foi executado"}' endif return oRest:setResponse(cResponse)
Abrangência
01/2020
Visão Geral
Import HTML Content
Conteúdo das Ferramentas