当前位置:网站首页>Coquette data completes the cloud native transformation through rainbow to realize offline continuous delivery to customers
Coquette data completes the cloud native transformation through rainbow to realize offline continuous delivery to customers
2022-07-07 08:19:00 【Rainbond】
1. About corky data
Nanjing Keji Data Technology Co., Ltd. was established in 2015 year , Provide one-stop construction and operation and maintenance of knowledge map in the whole life cycle 、 Intelligent application services , betake “ Link massive data , Mining wisdom from big data “. Help enterprises use knowledge mapping technology to build the world's leading cognitive work automation intelligent engine .
Currently in pharmaceutical enterprises 、 medical institution 、 Military Academy 、 It has served dozens of major customers in the fields of scientific and technological information and publishing , Accumulated rich experience in the application and development of industry knowledge map . Typical customers are National University of Defense Technology 、 Air China 、 CETC, etc .
2. The cloud native path of kerky data
Hello everyone , I'm liuzhanfeng, the solution architect of Nanjing Keji data , I have benefited a lot from the advantages of cloud native technology in delivery, operation and maintenance . As a project partner ,Rainbond Continue to help the rapid development, delivery and deployment of multiple business systems in kerky . In the use of Rainbond Before , Because the business iteration cycle is short , There are many components involved , Updating the platform version takes time and effort , Service operation and maintenance are difficult . In many projects , The customer's operation and maintenance capacity reserve is insufficient , Based on traditional delivery and management methods , The customer simply cannot take over the business operation and maintenance , As long as the wind blows and the grass moves , We must send engineers to the site to solve . For the problems of delivery operation and maintenance , Various business platforms began to transform cloud Nativity .
At first, we tried to build our own internal development and testing environment , Two small pits encountered in the process .
The first pit is : After the environment is built, the use experience is poor , All operations involving disk read and write appear to be abnormally stuck , In the cluster Etcd Cluster logs constantly report that “read_only” state , What follows is the soaring server load .
We asked for help with suspicion Rainbond The open source community , After various checks , We set our eyes on the disk IO On the performance . After replacing high-performance disks , We reinstalled the entire development and testing environment , The improvement of disk performance has indeed solved Etcd The problem that clusters often don't work .
The second pit is : Services that use shared storage are still in a state of extremely slow reading and writing , This really made all the engineers present start to look big again . After confirming the hardware performance , Start to focus on the operating system configuration parameters , The operating system kernel is constantly reporting errors related to shared storage :
NFS:__nfs4_reclaim_open_state: Lock reclaim failed! Indication nfs client and nfs server There are synchronous differences between , Much worse, it will start to call the police . After constant exploration , The engineers finally locked in with nfs Two system parameters related to performance ,Linux nfs The client is responsible for NFS The number of requests is controlled , If the parameter configuration is small, it will lead to IO Poor performance .
echo "options sunrpc tcp_slot_table_entries=128" >> /etc/modprobe.d/sunrpc.confecho "options sunrpc tcp_max_slot_table_entries=128" >> /etc/modprobe.d/sunrpc.conf
After modifying these two parameters , The performance of shared storage has been significantly improved , The elusive kernel alarm information also disappears . The development and testing environment can finally be used smoothly .
The next challenge is how to successfully migrate our multiple business systems to Rainbond Up , Fortunately Rainbond It's easy to use , The overall learning gradient is not steep , We can easily deploy our business systems in batches Rainbond Up . However Rainbond The cloud native application evaluation organized by engineers pointed out that the business system did not conform to the cloud native characteristics in many places , Put forward some rectification opinions . In the process of rectification , We also have a deeper understanding of cloud primordial .
Elasticsearch And other stateful components need to adjust the component deployment type to stateful single instance or stateful multi instance , It can't be stateless
At first, we didn't know what is there \ Stateless component , So I didn't pay attention to distinguishing the deployment types of components .Rainbond The engineer reminded us ,Elasticsearch stay Rainbond The platform should be deployed with stateful component deployment types .
L1 Primary cloud application features —— Scalability
Cloud native applications focus on the type of resources used to deploy components , Like database type 、 The service component pair of message queue type is Rainbond On the platform , You should use StatefulSet Deploy by resource type . By defining stateful or stateless deployment types for service components , To specify the use StatefulSet or Deployment Resource types to deploy instances .
Support horizontal scaling
Our multiple business systems , Before touching the original transformation of cloud , They are all traditional monomer architectures , The high availability feature is basically not considered when deploying . This makes our business system relatively fragile , There is no fault tolerance , Once the server goes down , The whole business system loses its service capability . In the process of cloud original transformation , We rely on Rainbond Natural microservice capability , It is very easy to split our business system into a more reasonable micro service architecture . What surprises us more is , These split microservice components , Most of them have the ability of horizontal expansion , With the help of Rainbond One key telescopic ability , Rapidly expand into a multi instance cluster , Greatly improve the availability of the system . For some components that cannot be scaled with one click ,Rainbond The engineers also provided reasonable advice , Guide us to modify these special components , Make it happen “ Stateless ”. Now? , After cloud native transformation, the business has “ cockroach ” General tenacious vitality , No longer afraid of server downtime .
L1 Primary cloud application features —— Scalability
By means of program data separation , Realize stateless Application , Let cloud native applications scale multiple instances horizontally at will . On the one hand, the scaling of the number of instances makes cloud native applications highly available , It also directly affects its ability to resist concurrency .Rainbond It also provides automatic scaling function , To cut peak and fill valley .
All configurations support environment variable configuration , Form like
${GATEWAY_PORT:8083}
In the past, we have written the configuration item of the service as a fixed value , This approach makes every new deployment environment , Have to change a lot of configuration files .Rainbond The engineer pointed out that , Cloud native applications should save the configuration to the environment , Declared in the form of environment variables plus default values . And most of the configuration items that need to be modified , Such as the connection address information between different components , You can go through Rainbond Depend on the connection information in the relationship to inject each other , It saves a lot of configuration work .
L1 Primary cloud application features —— Configurability
A best practice advocated by cloud native applications , Is to save the configuration in the environment . In different operating environments , Configure with environment variables , It's a very good experience .Rainbond Support setting environment variables for each service component , You can also configure group functions based on , Batch configure environment variables .
The main port of the component passes through the environment variable ${PORT} Definition
Rainbond The engineer offers a trick , Configure the component listening port , Configure with a fixed environment variable , The value of this variable will follow us in Rainbond The port number manually added on the console is automatically changed , such , We can do this without changing the code and configuration , Change the port number you want to listen to at will , This is very convenient .
L1 Primary cloud application features —— Configurability
As a supplement to environment variables ,Rainbond It provides a series of environment variables that can be generated automatically , These specific environment variables greatly facilitate the use of users .
All components need a unified time zone
It is very necessary to unify the time zone configuration of all components ,Rainbond Engineers provide a skill , Let the time zone setting become a very simple thing . You only need to include
tzdata
software package , We can base onTZ=Asia/shanghai
Configuration of such an environment variable , Complete the configuration of time zone .L1 Primary cloud application features —— Basic observability
Unified time is very important in the field of operation and maintenance , In the cloud native domain , The configuration of time zone can also be based on environment variables .
All businesses need to define health check strategies
Rainbond The engineer asked us to define a health check strategy for all service components , In this way, when the service component encounters problems , Quickly identify the abnormal operation state , According to the prior configuration , Complete the offline or restart operation . about http service , We define a detection interface , Judge the status of the service by the status code returned by the probe request ; For general middleware , Then detect its TCP The listening state of the port .
L1 Primary cloud application features —— High fault tolerance
In terms of improving fault tolerance , Cloud native applications need to be configured with reasonable health inspection strategies . This is conducive to quickly finding abnormal conditions of components , And automatically restart according to the pre configured strategy 、 Offline and other operations .
Components should support graceful failure and retry mechanisms
Rainbond The engineer explained to us that when our service components are shut down , How should you react , To maximize and optimize the end-user experience . Process reception SIGTERM when , Reject new request , Close the port after receiving the request , Withdraw from the process . For the case that the service component suddenly loses the database connection , Reasonable retry mechanism should also be added , After multiple retries, you still cannot reconnect to the database , The process should be ended , Use explicit component abnormal status to remind the operation and maintenance personnel .
L1 Primary cloud application features —— High fault tolerance
Cloud native applications emphasize fault tolerance , It's not just when certain errors are triggered , Whether the application itself and the platform provide automatic processing means , It also includes when the error cannot be handled , Provide better observability , To remind the operation and maintenance personnel to intervene .
front end web Component calls the backend api The component address needs to be nginx agent
For projects with separate front and back ends , Reasonable use of front-end web It is a good experience for the server to forward the interface layer .Rainbond Engineers are helping us complete the front end VUE The source code of the project is built at the same time , It also teaches how to add a configuration file under the code root directory , To realize the forwarding of interface requests to back-end components .
L2 Primary cloud application features —— Front and rear end separation configuration
Rainbond Provides a convenient way to configure VUE And other front-end projects Nginx, After configuration, you only need to rely on the front and rear components , Can be realized API Forwarding . Instead of every deployment , Must be recompiled according to the address change of the back-end service .
Achieve one click delivery
Use Rainbond One of the purposes of , Is hoping to use its ability , Realize the rapid delivery of business system . Through the cooperation with Haoyu technology delivery team , We only need to provide the offline package of application template , Haoyu technology delivery team can help us deliver a complete set of business systems with one click in the final production environment . This greatly reduces our delivery costs .
L2 Primary cloud application features —— A key to install
With the help of Rainbond Application publishing capability provided , We can publish enterprise applications running on the platform as an application template with one click . Our most ardent expectation for application templates , This application template can be operated in the simplest way 、 It can be installed as an application with as little manual debugging as possible .
Realize one click upgrade
In order to meet the needs of end users , We need to constantly iterate our products , And continuously upgrade our business system in the production environment .Rainbond The version based on the application template realizes the ability of one click upgrade , This function is very useful for us , We only need to provide a higher version of the application template offline package , The delivery team of Haoyu technology can help us upgrade the whole business system with one click in the final production environment .
L2 Primary cloud application features —— One click upgrade
Rainbond The app store mechanism of supports the upgrade of installed apps based on the version of the app template . The upgrade mechanism of the platform solves the service component version 、 To configure 、 Version management problems of most attributes such as dependencies . The problem that still needs application developers to pay attention to is the version management of data .
3. Final effect
After application and transformation , adopt Rainbond You can view the topology and dependencies of our products .
In actual projects , Our products flow in three environments :
development environment : We are in the company , Use the open source version of Rainbond Build a development and testing environment on the company's server , Our development team builds through source code , Soon the business system was moved to Rainbond. Through a period of testing and iteration , We took out the first version of the application template , And use the offline export function to export the offline package .
Access test environment : Use media such as CD , Only one engineer needs to import the offline package into the private cloud access test environment provided by the end customer , After import, the product is installed with one click . Comments on customer feedback , We export new offline packages in the development environment , And import the access test environment again , One click upgrade , After many iterations, the customer's access requirements are finally met .
Production environment : The final production environment is completely managed by the customer , We only need to provide the approved application template offline package and necessary documents , Customers can deploy and upgrade our products very quickly .
Compared with the previous delivery methods and processes , Access Rainbond The system brings us these better delivery experiences :
More convenient delivery : The deliverables are only offline packages , There is no need to care about the complex operating environment of customers .
Lower delivery costs : Whether in terms of time or manpower , The delivery cost has been greatly reduced .
Apply operation and maintenance process automation : Cloud native technology has effectively improved the capabilities of business systems , Usability 、 Fault tolerance and dynamic scalability in response to sudden traffic increases .
In the end, it only takes one week , We have completed the cloud native transformation of various business systems , And passed the cloud native application standard certification L2 level . In the previous project delivery process, it was difficult to deliver 、 It's hard to maintain , Is our biggest hidden cost , Customers will only see the final delivery effect , Will not pay for the delivery process .
After the cloud native transformation , The delivery team needs to be stationed before 1 Projects that can only be delivered in a week , Now a basic operation and maintenance engineer will install it ,1 It can be done in hours . And users can use Rainbond The visual interface of is quickly mastered ,95% All operation and maintenance problems can be solved by ourselves , Or guide the customer's operation remotely .
4. What is cloud native application standard specification certification ?
「 Cloud native application standard specification certification 」 For the convenience of software manufacturers in the application delivery process 、 Maintainability after delivery to customers 、 And the need for portability when necessary , Provide reliable technical endorsement . At this stage ,「 Cloud native application standard specification certification 」 It is divided into L1、L2、L3 level , It plays an important role in application delivery and delivery management .
L1 Focus on : One click installation and automatic operation and maintenance after application cross environment delivery . If available 、 Scalability 、 Observability, etc , Improve the maintainability of end customers , Reduce customer learning costs .
L2 stay L1 Pay attention to : One click upgrade after application cross environment delivery . Such as the total amount / Incremental upgrade 、 Version rollback, etc , Meet the continuous iterative delivery needs of customers in small steps .
L3 stay L2 Pay attention to : Apply one click backup migration after cross environment delivery . Such as packaged backup containing complete data 、 Portability, etc , Help customers realize the migration of the overall production environment 、 Disaster preparedness .
5. About Rainbond
Rainbond As an open source cloud native application management platform , yes 「 Cloud native application standard specification 」 The best tool for implementation .
边栏推荐
- Vulnerability recurrence fastjson deserialization
- Network learning (III) -- highly concurrent socket programming (epoll)
- Openvscode cloud ide joins rainbow integrated development system
- Empire CMS collection Empire template program general
- Complete linear regression manually based on pytoch framework
- [go ~ 0 to 1] obtain timestamp, time comparison, time format conversion, sleep and timer on the seventh day
- [quick start of Digital IC Verification] 13. SystemVerilog interface and program learning
- Wang Zijian: is the NFT of Tencent magic core worth buying?
- Blob object introduction
- 利用 Helm 在各类 Kubernetes 中安装 Rainbond
猜你喜欢
The truth of robot education in hands-on practice
JS复制图片到剪切板 读取剪切板
eBPF Cilium实战(2) - 底层网络可观测性
解析机器人科技发展观对社会研究论
eBPF Cilium实战(1) - 基于团队的网络隔离
Splunk查询csv lookup table数据动态查询
Rainbond 5.7.1 支持对接多家公有云和集群异常报警
One click installation of highly available Nacos clusters in rainbow
使用 Nocalhost 开发 Rainbond 上的微服务应用
利用 Helm 在各类 Kubernetes 中安装 Rainbond
随机推荐
The truth of robot education in hands-on practice
Réplication de vulnérabilité - désrialisation fastjson
Understanding of out covariance, in inversion and invariance in kotlin
Network learning (II) -- Introduction to socket
Jmeter 的使用
Open3D ISS关键点
Network learning (I) -- basic model learning
Uniapp mobile terminal forced update function
Easy to understand SSO
JS copy picture to clipboard read clipboard
Blob 对象介绍
The largest 3 same digits in the string of leetcode simple question
Complex network modeling (I)
提高企业产品交付效率系列(1)—— 企业应用一键安装和升级
Register of assembly language by Wang Shuang
opencv学习笔记四——膨胀/腐蚀/开运算/闭运算
Leetcode simple question: find the K beauty value of a number
Fast parsing intranet penetration escorts the document encryption industry
Lua 编程学习笔记
Make LIVELINK's initial pose consistent with that of the mobile capture actor