mirror of
https://github.com/falcosecurity/falco.git
synced 2025-08-31 22:28:22 +00:00
update(userspace/falco): major, minor, patch are digits, so use integers
Signed-off-by: Leonardo Di Donato <leodidonato@gmail.com>
This commit is contained in:
committed by
poiana
parent
2a9c9bdc53
commit
5663d4d02b
@@ -19,9 +19,9 @@ limitations under the License.
|
|||||||
#define FALCO_BRANCH "@FALCO_REF@"
|
#define FALCO_BRANCH "@FALCO_REF@"
|
||||||
#define FALCO_HASH "@FALCO_HASH@"
|
#define FALCO_HASH "@FALCO_HASH@"
|
||||||
#define FALCO_VERSION "@FALCO_VERSION@"
|
#define FALCO_VERSION "@FALCO_VERSION@"
|
||||||
#define FALCO_VERSION_MAJOR "@FALCO_VERSION_MAJOR@"
|
#define FALCO_VERSION_MAJOR @FALCO_VERSION_MAJOR@
|
||||||
#define FALCO_VERSION_MINOR "@FALCO_VERSION_MINOR@"
|
#define FALCO_VERSION_MINOR @FALCO_VERSION_MINOR@
|
||||||
#define FALCO_VERSION_PATCH "@FALCO_VERSION_PATCH@"
|
#define FALCO_VERSION_PATCH @FALCO_VERSION_PATCH@
|
||||||
#define FALCO_VERSION_PRERELEASE "@FALCO_VERSION_PRERELEASE@"
|
#define FALCO_VERSION_PRERELEASE "@FALCO_VERSION_PRERELEASE@"
|
||||||
#define FALCO_VERSION_BUILD "@FALCO_VERSION_BUILD@"
|
#define FALCO_VERSION_BUILD "@FALCO_VERSION_BUILD@"
|
||||||
|
|
||||||
|
@@ -32,11 +32,14 @@ void falco::grpc::server_impl::subscribe(const stream_context& ctx, const output
|
|||||||
{
|
{
|
||||||
if(ctx.m_status == stream_context::SUCCESS || ctx.m_status == stream_context::ERROR)
|
if(ctx.m_status == stream_context::SUCCESS || ctx.m_status == stream_context::ERROR)
|
||||||
{
|
{
|
||||||
|
// todo(leodido) > log "status=ctx->m_status, stream=ctx->m_stream"
|
||||||
ctx.m_stream = nullptr;
|
ctx.m_stream = nullptr;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// Streaming
|
// Start or continue streaming
|
||||||
|
// todo(leodido) > check for m_status == stream_context::STREAMING?
|
||||||
|
// todo(leodido) > set m_stream
|
||||||
if(output::queue::get().try_pop(res) && !req.keepalive())
|
if(output::queue::get().try_pop(res) && !req.keepalive())
|
||||||
{
|
{
|
||||||
ctx.m_has_more = true;
|
ctx.m_has_more = true;
|
||||||
@@ -52,12 +55,18 @@ void falco::grpc::server_impl::subscribe(const stream_context& ctx, const output
|
|||||||
|
|
||||||
void falco::grpc::server_impl::version(const context& ctx, const version::request&, version::response& res)
|
void falco::grpc::server_impl::version(const context& ctx, const version::request&, version::response& res)
|
||||||
{
|
{
|
||||||
res.set_version(FALCO_VERSION);
|
auto& build = *res.mutable_build();
|
||||||
res.set_major(std::stoi(FALCO_VERSION_MAJOR));
|
build = FALCO_VERSION_BUILD;
|
||||||
res.set_minor(std::stoi(FALCO_VERSION_MINOR));
|
|
||||||
res.set_patch(std::stoi(FALCO_VERSION_PATCH));
|
auto& prerelease = *res.mutable_prerelease();
|
||||||
res.set_prerelease(FALCO_VERSION_PRERELEASE);
|
prerelease = FALCO_VERSION_PRERELEASE;
|
||||||
res.set_build(FALCO_VERSION_BUILD);
|
|
||||||
|
auto& version = *res.mutable_version();
|
||||||
|
version = FALCO_VERSION;
|
||||||
|
|
||||||
|
res.set_major(FALCO_VERSION_MAJOR);
|
||||||
|
res.set_minor(FALCO_VERSION_MINOR);
|
||||||
|
res.set_patch(FALCO_VERSION_PATCH);
|
||||||
}
|
}
|
||||||
|
|
||||||
void falco::grpc::server_impl::shutdown()
|
void falco::grpc::server_impl::shutdown()
|
||||||
|
Reference in New Issue
Block a user