davinci邮件发送不了截图问题
davinci邮件发送不了截图问题
1,截图工具绝对路径到可执行文件本身---此文件需要有可执行权限,超时可长
phantomjs_home: E:\\phantomjs-2.1.1\\bin\\phantomjs
screenshot:
default_browser: PHANTOMJS # PHANTOMJS or CHROME
timeout_second: 18000
phantomjs_path: E:\\phantomjs-2.1.1\\bin\\phantomjs.exe
2,jar报不要冲突要最新兼容
最新的jar包分别是:
commons-logging-1.2.jar、fastjson-1.2.58.jar、guava-23.6-jre.jar
3,端口不可用
设置系统端口范围有时失效,要重新设置,而且要重启------有效
less /proc/sys/net/ipv4/ip_local_port_range
得出结果是1024 65535
sysctl -w net.ipv4.ip_local_port_range="1124 65535"
4,端口配置问题----尤其linux
server:
protocol: http
address: 0.0.0.0----------------字符串端口
port: 8080
servlet:
context-path: /
# Userd for mail and download services, can be empty, careful configuration
# By default, 'server.address' and 'server.port' is used as the string value.
access:
address: 192.168.202.183----------流端口
port: 8080
5,不同的邮件浏览工具
6,sql中有语法异常----中文引号等等---尤其clickhouse
davinci所有有关别名,字段名引起的sql语法问题,进而引起的邮件截图发送不了的问题都是没有配置字段,别名的引号--英文可省中文必须按照配置来
此配置决定了程序拼接引号方式,不同数据库要不同的引号(单引号,双引号)
clickhouse中文别名双引号,mysql有引号即可,程序中构建的也应如此,英文别名可不加引号,要加就按设置的加 mysql‘ clickhouse“
正确配置-
mysql:
name: mysql
desc: mysql
version:
driver: com.mysql.jdbc.Driver
keyword_prefix:
keyword_suffix:
alias_prefix: \'
alias_suffix: \'
clickhouse:
name: clickhouse
desc: clickhouse
version:
driver: ru.yandex.clickhouse.ClickHouseDriver
keyword_prefix:\"
keyword_suffix:\"---------------字段双引号
alias_prefix: \"----------------别名双引号
alias_suffix: \"
SELECT pp, sum("注册量") as "sum(当日注册量)" FROM =====================里面需要加双引号因为是中文-------------这些双引号可以确保用中文别名,中文查询字段
(SELECT T.dept_one AS "pp", COUNT((CASE WHEN (fun_code = '1011010001' AND server_time = toDate('2019-12-15')) THEN fun_code ELSE NULL END)) AS "注册量"
FROM (SELECT m.*, s.event_property_code, s.event_property_value FROM cms.daily_new_clientrpt_master m LEFT JOIN cms.daily_new_clientrpt_slave s ON m.event_id = s.event_id) T
WHERE server_time = toDate('2019-12-15') GROUP BY T.dept_one)
TY WHERE 1 = 1 GROUP BY "pp"
SELECT
T.dept_one as "部门",
COUNT((
CASE
WHEN (fun_code='1011010001' and server_time =toDate($g$)) THEN
fun_code
ELSE
NULL
end
)) as "当日注册量"
FROM
(SELECT m.*, s.event_property_code,s.event_property_value FROM cms.daily_new_clientrpt_master m LEFT JOIN cms.daily_new_clientrpt_slave s on m.event_id= s.event_id ) T where server_time =toDate($g$) GROUP BY T.dept_one ORDER BY "当日注册量" DESC;
下一篇: davinci中报表sql有关写法