当前位置:网站首页>Starring develops httpjson access point + Database
Starring develops httpjson access point + Database
2022-06-24 19:03:00 【51CTO】
Develop a transaction to create an order , Use Http Protocol access point ,json message , Use mysql The database stores the order information .
System architecture design
JFDesign Perspective , System architecture design , New access point , The name is :pay_input; Described as : Payment system access point . choice HttpJSON Communication protocol
Connect the access point and intermediate services with a connecting line . preservation

Service definition
Add a new service definition , The service name is :orderCrt; Described as : Create payment order

JFDesign New data dictionary

Data model design
JFDesign Perspective -> Intermediate business -> Data model design -> Database table , New database table

The data dictionary corresponding to the table field

Add a service logic input / output data object
JFBuilder Perspective -> Intermediate business -> The first in the initial stage ALA-> Data objects , Add a service logic input / output data object

java Code writing
import java.text.SimpleDateFormat;
import java.util.Date;
import com.adtec.starring.respool.StarringSeq;
import com.adtec.starring.struct.dta.DtaInfo;
public class PubBean {
/**
* Method for obtaining general serial number , Query different numbers according to the incoming parameters
* @param id Serial No
* @return
*/
public int getSeqNo(String id) {
/* Take the value generated by the sequence number generator */
int seq = StarringSeq.getCustomSeq(id);
DtaInfo dtaInfo = DtaInfo.getInstance();
String nodeName = dtaInfo.getNodeName(); // Take the machine node number
int nodeNo = Integer.parseInt(nodeName); // The node number converted to an integer
/* According to the node number 、 The value generated by the sequence number generator generates the final platform serial number */
seq = nodeNo*100000000 + seq;
return seq;
}
/**
* Get machine date
* @return
*/
public String getNowDate(){
Date date= new Date();// Create a time object , Get the current time
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd");
String str = sdf.format(date);// Format the current time to the desired type
return str;
}
}
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
- 17.
- 18.
- 19.
- 20.
- 21.
- 22.
- 23.
- 24.
- 25.
- 26.
- 27.
- 28.
- 29.
- 30.
- 31.
- 32.
- 33.
- 34.
- 35.
- 36.
- 37.
- 38.
newly added Bean object
Processing logic
JFBuilder Perspective -> Intermediate business -> The first in the initial stage ALA-> Processing logic , open orderCrt Service logic , At input and output tab page , Select the input / output data object
Serial number configuration
JFConfig Perspective -> Serial number configuration , Add order serial number , minimum value :1; Maximum :99999999; step :1
function
JFConfig Perspective -> Run menu -> Export all , Check auto upload and upload class, export
Restart the platform
Then I don't know what to do , Ask the boss tomorrow !
边栏推荐
- Vite+web3: referenceerror: process is not defined
- Introduction, download and use of global meteorological data CRU ts from 1901 to 2020
- 「碎语杂记」这事儿不安全
- Mqtt protocol usage of LabVIEW
- ls 常用参数
- 应用程序DDoS攻击原理及防御方法
- Sentry series satellite introduction and download tutorial
- Introduction and tutorial of SAS planet software
- mysql binlog 数据源配置文档麻烦分享一下
- Introduction and download of nine npp\gpp datasets
猜你喜欢
随机推荐
Microsoft planetary computer (MPC) platform introduction, registration and comparison
Volcano成Spark默认batch调度器
Vite+web3: referenceerror: process is not defined
Location object
Building MVC system based on three-tier structure
华为机器学习服务语音识别功能,让应用绘“声”绘色
《Go题库·11》channel的应用场景
How to create a linear model prediction interval in R and visualize it
論文解讀(SR-GNN)《Shift-Robust GNNs: Overcoming the Limitations of Localized Graph Training Data》
API管理之利剑 -- Eolink
解读HarmonyOS 应用与服务生态
The sharp sword of API management -- eolink
制造业项目MDM主数据项目实施心得
FROM_ GLC introduction and data download tutorial
小白请教下各位大佬,cdc抽取mysql binlog是严格顺序的吗
Make track map
Road vector data download tutorial
Graph traversal (BFS and DFS) C language pure handwriting
System design idea of time traceability
Xiaodi class massive data processing business short chain platform










