TSG-14051 tsg-service-chaining-engine增加breakpad_minidump
This commit is contained in:
@@ -43,6 +43,7 @@ yum install -y librulescan-devel
|
||||
yum install -y sapp-devel # Maat_rule require MESA/stream.h
|
||||
yum install -y numactl-libs # required by mrzcpd
|
||||
yum install -y libibverbs # required by mrzcpd
|
||||
yum install -y libbreakpad_mini-devel
|
||||
|
||||
if [ $ASAN_OPTION ]; then
|
||||
source /opt/rh/devtoolset-7/enable
|
||||
|
||||
@@ -4,6 +4,15 @@ enable_cpu_affinity=1
|
||||
cpu_affinity_mask=2,3,4-9
|
||||
firewall_sids=1001
|
||||
|
||||
# Only when (disable_coredump == 1 || (enable_breakpad == 1 && enable_breakpad_upload == 1)) is satisfied, the core will not be generated locally
|
||||
disable_coredump=0
|
||||
enable_breakpad=1
|
||||
enable_breakpad_upload=1
|
||||
breakpad_upload_url=http://sentry.mesalab.cn:9000/api/3/minidump/?sentry_key=e8e446bb3bd8435c97f4c01770ca7025
|
||||
# must be /run/sce/crashreport,due to tmpfile limit
|
||||
breakpad_minidump_dir=/run/sce/crashreport
|
||||
breakpad_upload_tools=/opt/tsg/framework/bin/minidump_upload
|
||||
|
||||
[maat]
|
||||
# 0:json 1:redis 2:iris
|
||||
input_mode=1
|
||||
|
||||
@@ -3,6 +3,7 @@ target_link_libraries(platform PUBLIC common)
|
||||
target_link_libraries(platform PUBLIC pthread)
|
||||
target_link_libraries(platform PUBLIC MESA_prof_load)
|
||||
target_link_libraries(platform PUBLIC MESA_field_stat)
|
||||
target_link_libraries(platform PUBLIC breakpad_mini)
|
||||
target_link_libraries(platform PUBLIC maatframe)
|
||||
target_link_libraries(platform PUBLIC mrzcpd)
|
||||
target_link_libraries(platform PUBLIC cjson)
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#include <signal.h>
|
||||
#include <pthread.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <MESA/breakpad_mini.h>
|
||||
|
||||
#include "sce.h"
|
||||
#include "log.h"
|
||||
@@ -11,6 +12,8 @@
|
||||
#include "health_check.h"
|
||||
#include "global_metrics.h"
|
||||
|
||||
struct breakpad_instance *g_breakpad = NULL;
|
||||
|
||||
#ifdef SCE_GIT_VERSION
|
||||
static __attribute__((__used__)) const char *__sce_version = SCE_GIT_VERSION;
|
||||
#else
|
||||
@@ -132,6 +135,8 @@ int main(int argc, char **argv)
|
||||
return -1;
|
||||
}
|
||||
|
||||
g_breakpad = breakpad_init(profile, "system", g_default_logger, __sce_version);
|
||||
|
||||
health_check_session_init(profile);
|
||||
|
||||
struct sce_ctx *ctx = sce_ctx_create(profile);
|
||||
|
||||
4
vendor/CMakeLists.txt
vendored
4
vendor/CMakeLists.txt
vendored
@@ -62,3 +62,7 @@ set(MRZCPD_INCLUDE_DIR /opt/mrzcpd/include)
|
||||
add_library(mrzcpd SHARED IMPORTED GLOBAL)
|
||||
set_property(TARGET mrzcpd PROPERTY IMPORTED_LOCATION ${MRZCPD_LIB_DIR}/libmarsio.so)
|
||||
set_property(TARGET mrzcpd PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${MRZCPD_INCLUDE_DIR})
|
||||
|
||||
add_library(breakpad_mini SHARED IMPORTED GLOBAL)
|
||||
set_property(TARGET breakpad_mini PROPERTY IMPORTED_LOCATION ${MESA_FRAMEWORK_LIB_DIR}/libbreakpad_mini.so)
|
||||
set_property(TARGET breakpad_mini PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${MESA_FRAMEWORK_INCLUDE_DIR})
|
||||
Reference in New Issue
Block a user