“无法获取时间线数据"在逗号 IDE 中使用时间线可视化时 [英] "Could not get Timeline data" when using Timeline Visualization with Comma IDE

查看:50
本文介绍了“无法获取时间线数据"在逗号 IDE 中使用时间线可视化时的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在实现对

不确定如果使用环境变量定义输出文件是否会发生这种情况,但无论如何,最好是安全的.当您最终将脚本投入生产时,您可以使用输出文件.

After implementing the answer to this question on how to set up a script for time visualization in this project (which uses a small extension to the published Log::Timeline that allows me to set the logging file from the program itself), I still get the same error

12:18   Timeline connection error: Could not get timeline data: java.net.ConnectException: Conexión rehusada

(which means refused connection). I've also checked the created files, and they are empty, they don't receive anything. I'm using this to log:

class Events does Log::Timeline::Event['ConcurrentEA', 'App', 'Log'] { }

(as per the README.md file). It's probably the case that there's no such thing as a default implementation, as shown in the tests, but, in that case, what would be the correct way of making it print to the file and also connect to the timeline visualizer?

解决方案

If you want to use the timeline visualization, leave the defaults for logging, commenting out any modification of the standard logging output. In my case:

#BEGIN {
#    PROCESS::<$LOG-TIMELINE-OUTPUT>
#           = Log::Timeline::Output::JSONLines.new(
#               path => log-file
#            )
#}

Not really sure if this would have happened if an output file is defined using an environment variable, but in any case, better to be on the safe side. You can use the output file when you eventually drop the script into production.

这篇关于“无法获取时间线数据"在逗号 IDE 中使用时间线可视化时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆