mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-15 19:02:04 +00:00
30 lines
757 B
C++
30 lines
757 B
C++
#pragma once
|
|
|
|
#include <Interpreters/IInterpreter.h>
|
|
#include <Parsers/IAST_fwd.h>
|
|
|
|
|
|
namespace DB
|
|
{
|
|
|
|
/** Return list of currently executing queries.
|
|
*/
|
|
class InterpreterShowProcesslistQuery : public IInterpreter, WithMutableContext
|
|
{
|
|
public:
|
|
InterpreterShowProcesslistQuery(const ASTPtr & query_ptr_, ContextMutablePtr context_)
|
|
: WithMutableContext(context_), query_ptr(query_ptr_) {}
|
|
|
|
BlockIO execute() override;
|
|
|
|
/// We ignore the quota and limits here because execute() will rewrite a show query as a SELECT query and then
|
|
/// the SELECT query will checks the quota and limits.
|
|
bool ignoreQuota() const override { return true; }
|
|
bool ignoreLimits() const override { return true; }
|
|
|
|
private:
|
|
ASTPtr query_ptr;
|
|
};
|
|
|
|
}
|