| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
Gateway
Logstorage
Event Handler
Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com>
Signed-off-by: S. Hameed <shameed@jp.adit-jv.com>
Signed-off-by: Aditya Paluri <venkataaditya.paluri@in.bosch.com>
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
|
|
|
|
| |
Made TCP socket send reliable by storing the unsent/partial message
in the ring buffer. This will avoid the corrupted messages/Gaps in
Viewer side
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Sometimes socket will be closed even not all of the data is flushed to daemon.
So before closing, following will be handled:
1. Use shutdown() to shut down further transmissions
2. Subsequent read() to resend_buffer
Also socket fd is reset in child fork handler since the socket itself will
not be duplicated in the child process.
Solves JIRA: SWGIII-28702
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
|
|
|
|
| |
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
|
|
|
|
|
|
|
| |
Add more logs to places where any pointer of buffer may get modified,
to get more information when we get unexpected behaviour
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
|
|
|
|
|
|
| |
with ll_ts API
Signed-off-by: Ravi Sankar P <ponnurangamravi.sankar@in.bosch.com>
|
|
|
|
|
|
| |
registration Macro and API which has option to register log level change callback along with it. This will avoid missing of initial log level change callback when daemon sends the log level change control msg during context registration
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
|
|
| |
private data as argument
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
| |
Signed-off-by: Manikandan C <mchockalingam@de.adit-jv.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It is possible to change the default buffer size for log message creation via
environment variable:
export DLT_LOG_MSG_BUF_LEN=<value>
Instead of using a static buffer with size of 1390 bytes, the buffer is
allocated dynamically with the specified value.The max size is restricted to approx 65k.
Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com>
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
| |
Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com>
|
|
|
|
| |
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
|
|
|
|
|
|
|
| |
The poll system call is now used in the daemon to enable DLT use in
POSIX compliant systems. Also added introduced new unregister_app macro
to avoid missing of logs in startup buffer.
Signed-off-by: Frederic Berat <fberat@de.adit-jv.com>
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
Signed-off-by: S. Hameed <shameed@jp.adit-jv.com>
|
|
|
|
|
|
|
|
|
|
|
| |
- dlt-control couldn't receive all the GET_LOG_INFO response message
when many applications and contexts are registered.
Therefore the receiver buffer size was extended to 65K.
Also the receive buffer size macros are reduced to one variable.
- Code cleanup and improvements
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
|
|
|
|
|
|
|
| |
- Context printing in dlt_process_get_log_info function updated
- Parameter in dlt_set_loginfo_parse_service_id function fixed
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
|
|
|
|
| |
Signed-off-by: Christoph Lipka <clipka@jp.adit-jv.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
-Support to send and parse periodic control messages
-add application/contexts to passive ECU list
-Refactor dlt_gateway_send_control_message
-Gateway issues with corrupted data and on demand connection
-Unit Test update
Signed-off-by: Saya Sugiura ssugiura@jp.adit-jv.com
Signed-off-by: Christoph Lipka clipka@jp.adit-jv.com
Signed-off-by: S. Hameed shameed@jp.adit-jv.com
Signed-off-by: ManikandanC Manikandan.Chockalingam@in.bosch.com
|
|
|
|
|
|
|
|
|
|
| |
- improvements and refactor key creation
- Sync strategies added
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
Signed-off-by: S. Hameed <shameed@jp.adit-jv.com>
Signed-off-by: Ravi Sankar P <ponnurangamravi.sankar@in.bosch.com>
Signed-off-by: Christoph Lipka <clipka@jp.adit-jv.com>
|
| |
|
|
|
|
|
|
| |
Prepare daemon to store applications/context information of other ECUs as well. This commit prepares the dlt-daemon to store logs from passive nodes in a logstorage device.
Signed-off-by: Christoph Lipka <clipka@jp.adit-jv.com>
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add dlt-sortbytimestamp utility plus documentation
Add a commandline utility to sort a DLT file by timestamp.
By default a DLT file's messages are in the order they were
received by the logger. This is not ideal for tracing problems on
systems with multi-threaded programmes running on multi-core CPUs
since message reception order will not always (or even often)
correspond to message creation order.
The documentation deals with how to handle the problem case of DLT
files containing messages from multiple boot cycles.
|
|
|
|
|
|
| |
warning: extra tokens at end of #ifdef directive
Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com>
|
|
|
|
|
|
|
|
| |
Package compilation fails with GLIBC 2.28:
stat.h:56:8: error: redefinition of 'struct statx_timestamp'
stat.h:99:8: error: redefinition of 'struct statx'
Signed-off-by: Oleksandr Kravchuk <oleksandr.kravchuk@pelagicore.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dlt-control-common: Fix build with GCC 8: When the "stringop-truncation" warning is treated as an error, the build fails with the following message:
* dlt-control-common.c:213:29: error: ‘strncpy’ output may be truncated copying 255 bytes from a string of length 1023 [-Werror=stringop-truncation] On this file we want to truncate the string due to the destination buffer size, so fix the above by using memcpy() instead.
* dlt-logstorage-common: Fix build with GCC 8: When the "stringop-truncation" warning is treated as an error, the build fails with the following message:
* dlt-logstorage-common.c:313:5: error: ‘strncpy’ specified bound 1024 equals destination size [-Werror=stringop-truncation] In order to avoid truncating and leaving the '\0' byte out, reduce the
bound by 1 byte.
* systemd/3rdparty: Fix sd-daemon build with GCC 8: When the "stringop-truncation" warning is treated as an error, the build fails with the following message:
* sd-daemon.c:453:9: error: ‘strncpy’ specified bound 108 equals destination size. In order to avoid truncating and leaving the '\0' byte out, reduce the bound by 1 byte.
Signed-off-by: Jesus Sanchez-Palencia <jesus.sanchez-palencia@intel.com>
|
| |
|
|
|
|
| |
In dlt_user_log_send_log and dlt_forward_msg API's when writing the data to DLT PIPE is not successful in scenario which returns "DLT_RETURN_PIPE_ERROR"(Non availability of dlt pipe post termination of DLT DAEMON) it ideally starts stores the data in internal buffer, and close the dlt user handle, which is quiet appropriate.
The scenario were dlt application fails in writing data to dlt pipe returns DLT_RETURN_PIPE_ERROR and case were application buffer is full, the return value DLT_RETURN_PIPE_ERROR is over written to "DLT_RETURN_BUFFER_FULL" were dlt user handle will not be reset to -1, it till holds the former data which causes undefined behavior of dlt application(One behavior would be which calls dlt_user_queue_resend and internally allocates memory for segmented data and tries to free it at dlt_user_trace_network_segmented_thread which is not intended behavior, instead return silently when FIFO is not available)
|
|
|
|
|
|
|
| |
When epoll detected error for TCP client connection, no state transition
had been happened. (Only the file descriptor had been closed)
To prevent this, dedicated close function is called according to connection type.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
| |
file parser: Replace hash functions with list
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
Signed-off-by: S. Hameed <shameed@jp.adit-jv.com>
Signed-off-by: Saya Sugiura <ssugiura@jp.adit-jv.com>
|
|
|
|
|
|
|
| |
To avoid busy loop due to error of mq_receive() which is called
in sub thread, 100ms sleep is added for the error case.
Error log message for mq_receive() is also corrected to have errno.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
|
|
|
| |
So far, signal number had been output in signal handler.
However this was not so safety. And when syslog was used as log
output destination of dlt_log(), we could not see any info in the
same Life Cycle.
So dlt_log() is removed from signal handler and signal number is
newly output by DLT message and dlt_log() at exit.
This info will help analysis why dlt-daemon exits.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
|
| |
Error log in case of accept() failure is improved with errno info.
This helps us to analyze dlt-daemon's issue in future.
(e.g.)
Connection request come to wrong socket unexpectedly and this
causes exiting dlt-daemon.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If application tries to send application registration request before
dlt-daemon startup, the request is sent twice as below:
1. Buffered request in user library buffer
2. New request when user app succeeds to attach to dlt-daemon
In previous, dlt-daemon had been output the registration messages
2 times even though these messages were come from same application.
This duplicated output is avoided by this change.
Warning message in case of dlt-runtime-context.cfg exists
is also avoided. This file is created when Control message: "Store Config"
is used. This is not irregular case.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
|
|
|
| |
This patch changes Context un-/registration message not to output DLT
by default for the purpose of reducing trace messages.
Actually dlt-daemon already sends almost same meaning control message
which can show Context un-/registration([get_log_info] and [unregister_context]).
These are duplicate message and should be suppressed in normal case.
Only if "Verbose = 1" is set in dlt.conf, the messages are output as same as before.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
occurs (#61)
In previous, there was possibility that application could not get
notification from dlt-daemon due to wrong error handling.
(e.g.)
1. App1, App2 and App3 register App/Context
2. App2 crashes without unregistering App/Context
3. Change default log level from DLT Viewer
--> App1 can receive new default log level from dlt-daemon but App3 cannot.
This patch makes processing non-stop even if error occurs in below cases:
- While updating log level of all registered apps
- While updating default log level/ default trace status
- While updating connection status between dlt-daemon and dlt-client
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
|
| |
* IPC: Unix socket added
The user can select either FIFO or UNIX socket as IPC between user library and daemon through CMakelist option.
Socket path configurable for both FIFO and Unix Socket now configurable in CMake
Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com>
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dlt-control: Provision to control entire system trace status
1. support for setting trace status using wildcards for both app and context
2. support for setting entire system trace status
*This Logic is as same as for changing log level.
(SHA: a966393ad7003d02870bceffa08df5ddf4bbf864
dlt-control: Provision to control entire system log level)
* dlt-daemon: Fix control entire log level / trace status issue
In previous, dlt-control could send request to set
all log level / trace status with DLT_LOG_DEFAULT / DLT_TRACE_STATUS_DEFAULT(-1).
However, dlt-daemon could not accept these value.
This change fix this issue so that setting log level/trace status of
all registered contexts become possible.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dlt-daemon: Lower log level of several logs not to output unintentional warning
Change log level of several logs from WARNING to INFO.
1. User FIFO cannot be opened because the FIFO does not exist
--> This case can happen if DLT user app is one-shot
2. Runtime configuration file (dlt-runtime-application.cfg / dlt-runtime-context.cfg)
cannot be opened
--> This case can happen in normal use case.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
| |
dlt-daemon entered to infinite loop when set log level request with
wildcards came from dlt-control due to variable size.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
|
|
|
| |
Marker message had been continued to output
if application called dlt_log_marker() due to missing
byte removing processing against marker message.
Therefore the byte removing for marker message processing is added.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
| |
Default trace status could not be set by "-f" option.
Signed-off-by: Yusuke Sato <yusuke-sato@apn.alpine.co.jp>
|
|
|
|
|
| |
Even Forcing log level and trace status of context to not exceed "ContextLogLevel" and "ContextTraceStatus" in dlt.conf file with ForceContextLogLevelAndTraceStatus = 1, the default log level is being overwritten with high value than expected by client(DLT_Viewer when default trace data request is sent ) and by dlt-control application on usage of (dlt-control -d loglevel IP_ADDRESS)
With provided patch/changes in place, when ForceContextLogLevelAndTraceStatus is enabled the requested log level is checked with ContextLogLevel and if it satisfied the daemon default loglevel gets updated.
Added a conditional checks to not to overwrite the individual contextLoglevel and ContextTracesStatus when ForceContextLogLevelAndTraceStatus is enabled in dlt.conf file and taken care of review comments.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Fix -Wpointer-compare of compare with null char
Signed-off-by: Phong Tran <tranmanphong@gmail.com>
* dlt_common: fix -Wformat-truncation of snprintf
Avoid snprintf output truncation by handling return value
Signed-off-by: Phong Tran <tranmanphong@gmail.com>
* dlt_offline_trace: Fix Wformat-truncation of snprintf
Compile with Gcc 7.x has the warning of snprintf buffer length size.
Check return value of snprintf() for avoiding the warning.
Signed-off-by: Phong Tran <tranmanphong@gmail.com>
* dlt_common_test: Fix memleak t_dlt_message_read
some resources were not free after using.
Detected by running
valgrind --leak-check=full ./gtest_dlt_common
Signed-off-by: Phong Tran <tranmanphong@gmail.com>
|
|
|
|
|
|
| |
* improve error reporting in dlt_daemon_socket
* use dlt_vlog
|
|
|
|
|
|
| |
Post enabling and updating “OfflineTraceDirectory” variable default path in dlt.conf file, dlt-daemon resulted in crash with Segmentation fault(SIGSEGV) due to Invalid OfflineTraceDirectory path.
dlt_offline_trace-patch-1 contains an update which verifies “existence of offline trace directory” and its “accessibility issues”. It returns -1 on failure conditions and indicates user with appropriate information instead resulting in APPCRASH.
|
|
|
|
|
|
| |
do not update data_send in case of temporal error
Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com>
|
|
|
| |
Prevention for occasional corrupted messages caused mostly due to system high load.
|
|
|
|
| |
Signed-off-by: Christoph Lipka <clipka@de.adit-jv.com>
|
|
|
|
| |
Signed-off-by: ManikandanC <Manikandan.Chockalingam@in.bosch.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dlt_common: Fix resource leak
Close the file before returning from function.
Signed-off-by: Gordan Markuš <gordan.markus@pelagicore.com>
* dlt-kpi-process: Fix memory leak
Signed-off-by: Gordan Markuš <gordan.markus@pelagicore.com>
* dlt-kpi-options: Clean up resources on malloc fail
Signed-off-by: Gordan Markuš <gordan.markus@pelagicore.com>
|