Commit 25bda25c authored by caotao's avatar caotao

移除无用代码

parent 9f0c79a4
//package com.yeejoin.amos.api.householdapi.Utils;
//
//import com.taosdata.jdbc.SchemalessWriter;
//import com.taosdata.jdbc.enums.SchemalessProtocolType;
//import com.taosdata.jdbc.enums.SchemalessTimestampType;
//import org.springframework.beans.factory.annotation.Value;
//import org.springframework.stereotype.Component;
//
//import java.sql.Connection;
//import java.sql.DriverManager;
//import java.sql.SQLException;
//
//@Component
//public class TdEngineUtils {
// @Value("${tdengine-server.jdbc-url}")
// private String url;
// @Value("${tdengine-server.username}")
// private String user;
// @Value("${tdengine-server.password}")
// private String password;
// public void writeDataIntoTdEngine(String lines){
// try (Connection conn = this.getConnection()) {
// SchemalessWriter writer = new SchemalessWriter(conn);
// writer.write(lines, SchemalessProtocolType.JSON, SchemalessTimestampType.NOT_CONFIGURED);
// } catch (Exception e) {
// e.printStackTrace();
// }
// }
// public Connection getConnection() throws SQLException {
// String jdbcUrl = String.format(url, user, password);
// return DriverManager.getConnection(jdbcUrl);
// }
//
//}
//package com.yeejoin.amos.dockingData;
//
//import com.alibaba.fastjson.JSON;
//import com.alibaba.fastjson.JSONArray;
//import com.alibaba.fastjson.JSONObject;
//import com.sun.scenario.effect.impl.sw.sse.SSEBlend_SRC_OUTPeer;
//import com.yeejoin.amos.api.householdapi.Utils.HouseholdPvUtils;
//import com.yeejoin.amos.api.householdapi.face.orm.entity.HouseholdPvApi;
//import com.yeejoin.amos.api.householdapi.face.orm.entity.HouseholdPvProducerInfo;
//import com.yeejoin.amos.api.householdapi.face.service.impl.HouseholdPvApiServiceImpl;
//import com.yeejoin.amos.api.householdapi.face.service.impl.HouseholdPvProducerInfoServiceImpl;
//import com.yeejoin.amos.component.influxdb.InfluxDbConnection;
//import com.yeejoin.amos.openapi.enums.PVProducerInfoEnum;
//import org.jetbrains.annotations.TestOnly;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.beans.factory.annotation.Value;
//import org.springframework.boot.actuate.influx.InfluxDbHealthIndicator;
//import org.springframework.scheduling.annotation.Scheduled;
//import org.springframework.stereotype.Component;
//
//import javax.annotation.PostConstruct;
//import java.util.*;
//import java.util.zip.Inflater;
//
///**
// * @description:
// * @author: tw
// * @createDate: 2023/6/16
// */
//@Component
//public class DockingData {
// @Autowired
// InfluxDbConnection influxDbConnection;
// @Autowired
// HouseholdPvUtils householdPvUtils;
// @Autowired
// private HouseholdPvProducerInfoServiceImpl householdPvProducerInfoServiceImpl;
// @Autowired
// private HouseholdPvApiServiceImpl householdPvApiServiceImpl;
//
// //初始化执行
// @PostConstruct
// public void init() {
// //锦浪云
// this.getDataGolong();
// //固德威
//// this.getDataGoodWE();
// //首航
//// this.getDataSoFar();
// }
//
// //每二十分钟执行一次
// @Scheduled(cron = "0 0/20 * * * ?")
// public void fixedRateGolong() {
// this.getDataGolong();
// }
//
// @Scheduled(cron = "0 0/20 * * * ?")
//// public void fixedRateGoodWE() {
//// this.getDataGoodWE();
//// }
//
//
// @Scheduled(cron = "0 0/20 * * * ?")
//// public void fixedRateSoFar() {
//// this.getDataSoFar();
//// }
//
// //请求获取数据
// public void getDataGolong() {
// List<HouseholdPvApi> householdPvApiList = householdPvApiServiceImpl.list();
// householdPvApiList.stream().filter(householdPvApi -> householdPvApi.getProducerId().equals(PVProducerInfoEnum.JLY.getCode())).forEach(householdPvApi -> householdPvUtils.gerResponseByAPiID(householdPvApi.getSequenceNbr()));
// }
//
// public void getDataGoodWE() {
// List<HouseholdPvApi> householdPvApiList = householdPvApiServiceImpl.list();
// householdPvApiList.stream().filter(householdPvApi -> householdPvApi.getProducerId().equals(PVProducerInfoEnum.GDW.getCode())).forEach(householdPvApi -> householdPvUtils.gerResponseByAPiID(householdPvApi.getSequenceNbr()));
// }
//
// public void getDataSoFar() {
// List<HouseholdPvApi> householdPvApiList = householdPvApiServiceImpl.list();
// householdPvApiList.stream().filter(householdPvApi -> householdPvApi.getProducerId().equals(PVProducerInfoEnum.SH.getCode())).forEach(householdPvApi -> householdPvUtils.gerResponseByAPiID(householdPvApi.getSequenceNbr()));
// }
//}
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