Commit 53101ddd authored by duanruiming's avatar duanruiming

Merge remote-tracking branch 'origin/master'

parents 33ea7d79 799549b7
......@@ -3,3 +3,4 @@ utc.dt.service.url=http://10.102.1.182:39002/utc-dt
utc.hisense.service.url=http://127.0.0.1:39003/utc-hisense
control.url=http://10.102.1.182:32001/web
ehualu.url=http://173.0.0.1:30015
ehualu.url=http://173.0.0.1:30015
utc.service.url=http://localhost:32000/utc
utc.dt.service.url=http://localhost:39002/utc-dt
utc.hisense.service.url=http://localhost:39003/utc-hisense
control.url=http://localhost:32001/web
utc.service.url=http://173.17.0.1:32000/utc
utc.dt.service.url=http://173.17.0.1:39002/utc-dt
utc.hisense.service.url=http://173.17.0.1:39003/utc-hisense
control.url=http://173.17.0.1:32001/web
ehualu.url=http://173.17.0.1:30015
\ No newline at end of file
utc.service.url=http://173.17.0.1:32000/utc
utc.dt.service.url=http://173.17.0.1:39002/utc-dt
utc.hisense.service.url=http://173.17.0.1:39003/utc-hisense
control.url=http://173.17.0.1:32001/web
ehualu.url=http://173.17.0.1:30015
\ No newline at end of file
......@@ -10,6 +10,7 @@ import org.joda.time.Days;
import org.joda.time.Hours;
import org.joda.time.Minutes;
import org.joda.time.Months;
import org.joda.time.format.DateTimeFormat;
import java.io.File;
import java.util.ArrayList;
......@@ -24,17 +25,45 @@ public class EsDateIndexUtil {
public static final String YMDHM_FORMATTER = "yyyyMMddHHmm";
public static final String YMDHMSFORMATTER = "yyyyMMddHHmmss";
public static final String YMD_HM_FORMATTER = "yyyy-MM-dd HH:mm:00";
public static final String YMD_HM_FORMATTER = "yyyy-MM-dd HH:mm:ss";
public static final String YMD_H_FORMATTER = "yyyyMMddHH";
public static final String YMD_FORMATTER = "yyyyMMdd";
public static final String YM_FORMATTER = "yyyyMM";
public static final String HMS_FORMATTER = "HH:mm:ss";
public static final String HMS_SSS_FORMATTER = "HH:mm:ss SSS";
public static final String HM_FORMATTER = "HH:mm";
public static final String H_FORMATTER = "HH";
public static final String H_FORMATTER = "HH:00";
private static final String FORMATSTR = "%s_%s";
/**
* 获取时段范围内不同时间粒度的时间轴
* @param groupType 0:5分钟 1:15分钟 2:30分钟 3:1小时 4:天粒度
* @param startTime 开始时间
* @param endTime 截止时间
* @return
*/
public static Set<String> getTimeGranularityAxis(String groupType,String startTime, String endTime) {
//存放时段
Set<String> sortedSet = new TreeSet<>();
//===========================根据开始、结束时间输出完整时刻点=================================================//
DateTime start = DateTime.parse(startTime, DateTimeFormat.forPattern(EsDateIndexUtil.YMD_HM_FORMATTER));
DateTime end = DateTime.parse(endTime, DateTimeFormat.forPattern(EsDateIndexUtil.YMD_HM_FORMATTER));
if (Objects.equals("0", groupType)) {
sortedSet.addAll(EsDateIndexUtil.getTimeScopeList(start, end, TimeGranularityEnum.FIVE_MINUTE, EsDateIndexUtil.HM_FORMATTER));
} else if (Objects.equals("1", groupType)) {
sortedSet.addAll(EsDateIndexUtil.getTimeScopeList(start, end, TimeGranularityEnum.FIFTEEN_MINUTE, EsDateIndexUtil.HM_FORMATTER));
} else if (Objects.equals("2", groupType)) {
sortedSet.addAll(EsDateIndexUtil.getTimeScopeList(start, end, TimeGranularityEnum.THIRTY_MINUTE, EsDateIndexUtil.HM_FORMATTER));
} else if (Objects.equals("3", groupType)) {
sortedSet.addAll(EsDateIndexUtil.getTimeScopeList(start, end, TimeGranularityEnum.ONE_HOUR, EsDateIndexUtil.H_FORMATTER));
} else if (Objects.equals("4", groupType)) {
sortedSet.addAll(EsDateIndexUtil.getTimeScopeList(start, end, TimeGranularityEnum.ONE_DAY, EsDateIndexUtil.YMD_FORMATTER));
}
return sortedSet;
}
/**
* 根据开始结束时间获取不同时间粒度的时刻点
*
......@@ -59,7 +88,7 @@ public class EsDateIndexUtil {
}else if (Objects.equals(TimeGranularityEnum.ONE_HOUR, timeGranularityEnum)) {
unitTime = 60;
}else if (Objects.equals(TimeGranularityEnum.ONE_DAY, timeGranularityEnum)) {
unitTime = 24*60*60;
unitTime = 24*60;
}
for (int i = 0; i <= diffNum; i=i+unitTime) {
......
......@@ -79,5 +79,34 @@ public interface GreenwaveHistoryMapper extends BaseInterfaceMapper<GreenwaveHis
*/
List<CrossLaneDataHistPoExtend> findGreenWaveCrossLaneIndex(Map<String,Object> params);
/**
* 出口车道信息查询
* @param params
* @return
*/
List<Map<String,Object>> findCrossExitRoadLaneInfo(Map<String,Object> params);
/**
* 出口车道信息查询
* @param params
* @return
*/
List<Map<String,Object>> findCrossExitRoadDirInfo(Map<String,Object> params);
/**
* 出口车道信指标息查询
* @param params
* @return
*/
List<CrossLaneDataHistPoExtend> findCrossExitRoadLaneIndex(Map<String,Object> params);
/**
* 出口道方向指标数据查询
* @param params
* @return
*/
List<CrossLaneDataHistPoExtend> findCrossExitRoadIndex(Map<String,Object> params);
}
......@@ -14,7 +14,9 @@ import java.util.Date;
* @description
*/
@Data
public class CrossLaneDataHistPoExtend extends CrossLaneDataHistPO {
public class CrossLaneDataHistPoExtend {
@ApiModelProperty(name = "路口编号",notes = "")
private String crossId;
//车道ID
@ApiModelProperty(value = "车道ID", notes = "")
private String laneId;
......@@ -37,8 +39,22 @@ public class CrossLaneDataHistPoExtend extends CrossLaneDataHistPO {
@ApiModelProperty(value = "平均排队长度", notes = "")
private Integer avgQueueLength;
@ApiModelProperty(value = "交通流量(辆)",notes = "")
private Integer flow;
@ApiModelProperty(value = "平均速度(km/h)",notes = "")
private Double speed;
@ApiModelProperty(value = "停车次数",notes = "")
private Double stopTimes;
@ApiModelProperty(value = "延误时间",notes = "")
private Integer delayTime;
@ApiModelProperty(value = "饱和度",notes = "")
private Double sturation;
@ApiModelProperty(value = "开始时间:yyyy-MM-dd HH:mm:ss", notes = "")
@JSONField(format = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
public Date startTime;
@ApiModelProperty(value = "时间轴", notes = "")
public String timeAxis;
}
......@@ -5,6 +5,7 @@ import net.wanji.common.framework.dubbointerface.BaseDubboInterface;
import net.wanji.common.framework.exception.DubboProviderException;
import net.wanji.databus.po.CrossDirDataHistPO;
import net.wanji.opt.entity.GreenwaveHist;
import net.wanji.opt.po.base.CrossLaneDataHistPoExtend;
import net.wanji.opt.vo.GreenWaveRunStateVO;
import java.util.List;
......@@ -103,4 +104,28 @@ public interface GreenwaveHistProvider extends BaseDubboInterface<GreenwaveHist>
* @throws DubboProviderException
*/
JSONObject findGreenWaveCrossLaneIndex(String crossId, String startTime, String endTime, String groupType,Integer objectType) throws DubboProviderException;
/**
* 出口车道信指标息查询
* @param crossId
* @param startTime
* @param endTime
* @param groupType
* @return
* @throws DubboProviderException
*/
JSONObject findCrossExitRoadLaneInfo(String crossId, String startTime, String endTime, String groupType) throws DubboProviderException;
/**
* 出口道方向指标数据查询
* @param crossId
* @param startTime
* @param endTime
* @param groupType
* @param objectType 1:出口道方向级指标 2:出口道车道级指标
* @return
* @throws DubboProviderException
*/
JSONObject findCrossExitRoadDirInfo(String crossId, String startTime, String endTime, String groupType,Integer objectType) throws DubboProviderException;
}
spring:
application:
# dubbo启动需要程序名称
name: signal-optimize-service
elasticsearch:
username: elastic
password: Wanji300552
uris: http://10.102.1.182:9200
application:
name: opt
uris: http://37.12.182.31:9200
datasource:
dynamic:
primary: master
datasource:
master:
type: com.alibaba.druid.pool.DruidDataSource
url: jdbc:mysql://10.102.1.182:3306/t_signal_control_jinan?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
#url: jdbc:mysql://37.12.182.29:3306/t_signal_control_jinan?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
url: jdbc:mysql://37.12.182.29:3306/t_signal_control_jinan?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
username: root
password: Wanji300552
driverClassName: com.mysql.cj.jdbc.Driver
slave:
type: com.alibaba.druid.pool.DruidDataSource
url: jdbc:mysql://10.102.1.182:3306/t_signal_control_jinan?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
url: jdbc:mysql://37.12.182.29:3306/t_signal_control_jinan?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
username: root
password: Wanji300552
driverClassName: com.mysql.cj.jdbc.Driver
webService:
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://37.12.182.29:3306/t_signal_control_jinan?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
username: root
password: Wanji300552
type: com.alibaba.druid.pool.DruidDataSource
holo:
type: com.alibaba.druid.pool.DruidDataSource
url: jdbc:mysql://10.102.1.182:3306/holo_roadnet_jn?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
url: jdbc:mysql://37.12.182.29:3306/holo_roadnet?useUnicode=true&characterEncoding=UTF-8&zeroDateTimeBehavior=convertToNull&allowMultiQueries=true&sessionVariables=sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION'&useSSL=false&useCursorFetch=true
username: root
password: Wanji300552
driverClassName: com.mysql.cj.jdbc.Driver
redis:
host: 10.102.1.182
host: 37.12.182.29
port: 6379
password: Wanji300552
jedis:
......@@ -38,17 +46,16 @@ spring:
max-idle: 20
min-idle: 10
timeout: 5000
database: 3
database: 7
kafka:
bootstrap-servers: 10.102.1.182:9092
bootstrap-servers: 37.12.182.29:9092
empty-phase-topic: phase.emptiness.analysis
#消费者配置
consumer:
max-poll-records: 1
broker-id: 1
broker-id: 0
auto-commit-interval: 1S
auto-offset-reset: earliest
auto-offset-reset: latest
enable-auto-commit: false
key-deserializer: org.apache.kafka.common.serialization.StringDeserializer
value-deserializer: org.apache.kafka.common.serialization.StringDeserializer
......@@ -64,6 +71,27 @@ spring:
mvc:
pathmatch:
matching-strategy: ant_path_matcher
#MQ Config
rabbitmq:
host: 172.17.150.46
port: 5672
username: guest
password: Ehl1234
virtual-host: /
#指定上屏消息队列
#queue-name: 27efbf6d-53f0-4c09-9934-38e620916c60
queue-name: vms_control_queue
sending: false
#诱导屏推送模板
freemarker:
template-loader-path: classpath:/templates/
charset: GB2312
content-type: text/html;charset=gb2312
check-template-location: true
settings:
classic_compatible: true
service:
name: signal-optimize-service
......@@ -113,7 +141,7 @@ threadPoolConfig:
allowCoreTimeOut: false
server:
port: 39001
port: 39002
servlet:
display-name: Wanji
context-path: /opt
......@@ -142,8 +170,30 @@ crossOptParam:
minVehheadTime: 2.0
defaultVehheadTime: 2.8
# 信号平台
system:
address:
# UTC服务地址
utc: http://37.12.182.29:32000/utc
# control服务地址
control: http://37.12.182.29:32001/web
# 绿波方向转换
direction-mappings:
mappings:
"13NF80B5QN0": ["东:2","西:6"]
"13NGH0B5RC0": ["西:6"]
synthesis:
strategyUrl: http://37.12.182.50:8082/api/traffic/strategy/info
ftp:
#ftp服务器用户名
username: vms
#ftp服务器密码
password: ehl1234
#ftp服务器的地址
url: 172.24.0.31
#ftp服务器的端口号
port: 21
#rsu上传日志文件父目录
path: /WJ
\ No newline at end of file
......@@ -10,3 +10,6 @@ spring:
password: nacos
main:
allow-circular-references: true
application:
# dubbo启动需要程序名称
name: signal-optimize-service
spring:
cloud:
nacos:
config:
server-addr: 37.12.182.29:8848
file-extension: yaml
group: signal
namespace: signal
username: nacos
password: nacos
application:
# dubbo启动需要程序名称
name: signal-optimize-service
main:
allow-circular-references: true
spring:
profiles:
active: docker
\ No newline at end of file
active: test
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment