{"id":4114,"date":"2021-11-29T11:16:52","date_gmt":"2021-11-29T03:16:52","guid":{"rendered":"http:\/\/123.57.164.21\/?p=4114"},"modified":"2021-11-29T11:16:52","modified_gmt":"2021-11-29T03:16:52","slug":"cloud-native-%e4%b8%8e-spring-cloud_%e5%85%a5%e9%97%a8_5_openshift","status":"publish","type":"post","link":"https:\/\/92it.top\/?p=4114","title":{"rendered":"Cloud native \u4e0e Spring Cloud_\u5165\u95e8_5_OpenShift"},"content":{"rendered":"\n<h5 class=\"wp-block-heading\">\u672c\u5730\u8fde\u63a5OpenShift\u4e0a\u7684DB<\/h5>\n\n\n\n<ul><li>1.\u547d\u4ee4\u884c\u767b\u5f55\u5230 OpenShift\uff0c \u627e\u5230 postgres \u7684 pod \u540d\u79f0\uff0c<\/li><li>2.\u901a\u8fc7 <code>oc port-forward pod_name \u4e3b\u673a\u7aef\u53e3: Container\u7aef\u53e3<\/code> \u505a\u7aef\u53e3\u8f6c\u53d1.<\/li><\/ul>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">oc login --token=sha256~xxxxxxx --server=https:\/\/c100-e.jp-tok.containers.cloud.ibm.com:30954\noc projects | grep jre\noc project xxxcloud-dev\noc get po\noc port-forward postgres-1-r24h2 15432:5432<\/pre>\n\n\n\n<ul><li>3.\u6700\u540e\u901a\u8fc7 DBeaver \u6216 IDEA \u8fde\u63a5<\/li><\/ul>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">host: localhost\nport: 15432\nuser: postgres\npassword: xxxxxxxxx\ndatabase: xxxxcloud<\/pre>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h5 class=\"wp-block-heading\">\u4f7f\u7528IBM Log Analysis<\/h5>\n\n\n\n<ul><li>1. \u4ecb\u7ecd<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/logdna#1-\u4ecb\u7ecd\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>\u5b98\u65b9\u6587\u6863\uff1a <a rel=\"noreferrer noopener\" href=\"https:\/\/cloud.ibm.com\/docs\/log-analysis?topic=log-analysis-getting-started\" target=\"_blank\">https:\/\/cloud.ibm.com\/docs\/log-analysis?topic=log-analysis-getting-started<\/a><\/p>\n\n\n\n<ul><li>2. \u9700\u6c42<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/logdna#2-\u9700\u6c42\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>\u5728 spring boot \u5e94\u7528\u4e2d\uff0c\u4f7f\u7528 <a rel=\"noreferrer noopener\" href=\"https:\/\/projectlombok.org\/\" target=\"_blank\">lombok<\/a> \u7ed3\u5408 <a rel=\"noreferrer noopener\" href=\"http:\/\/www.slf4j.org\/\" target=\"_blank\">slf4j<\/a> \u65e5\u5fd7\u6846\u67b6\u6765\u8f93\u51fa\u65e5\u5fd7\uff0c \u5982\u4e0b\uff1a<\/p>\n\n\n\n<p>ProductController.java<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">@Slf4j\npublic class ProductController {\n    @Autowired\n    private ProductService productService;\n\n    @GetMapping\n    public PageInfo&lt;Product> list(@Valid ProductSearchInput input, HttpServletRequest request) {\n        if (log.isInfoEnabled()) {\n            log.info(\"User from {} tries to retrieve products via {}.\", request.getRemoteHost(), request.getHeader(\"User-Agent\"));\n        }\n\n        PageInfo&lt;Product> data = productService.search(input);\n\n        log.info(\"{} records found.\", data.getTotal());\n\n        return data;\n    }<\/pre>\n\n\n\n<p>product \u793a\u4f8b\u5e94\u7528 \u5728 <code>application.yaml<\/code> \u4e2d\u8bbe\u7f6e\u4e86\u6839\u65e5\u5fd7\u7ea7\u522b\u4e3a <code>info<\/code>, \u540c\u65f6\u4e3a\u4e86\u6253\u5370 SQL\uff0c\u5c06 mapper \u5305\u65e5\u5fd7\u7ea7\u522b\u8bbe\u7f6e\u4e3a <code>debug<\/code><\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">---\nspring.config.activate.on-profile: openshift\nserver.port: 8080\nlogging:\n  level:\n    root: info\n    com.ibm.jrecloud.productapi.mapper: debug<\/pre>\n\n\n\n<ul><li>3. \u53ef\u9009\u65b9\u6848<\/li><\/ul>\n\n\n\n<p><a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/logdna#3-\u53ef\u9009\u65b9\u6848\">\u200b<\/a>\u6709\u4e24\u79cd\u4e3b\u8981\u7684\u65b9\u6848\u53ef\u4ee5\u5b9e\u73b0\u8fd9\u4e00\u9700\u6c42\uff1a<\/p>\n\n\n\n<p>1.<code>\u57fa\u4e8e\u5f00\u6e90\u7684 EFK (Elastic Search\/Fluentd\/Kibana)<\/code> : \u5728 OpenShift \u7684 OperatorHub \u4e2d, \u901a\u8fc7\u5b89\u88c5 OpenShift Elasticsearch Operator \u548c Cluster Logging Operator\uff0c \u4f7f\u7528 Kibana \u63a7\u5236\u53f0\u6765\u76d1\u63a7\u5e94\u7528\u7a0b\u5e8f\u65e5\u5fd7, EFK \u4f1a\u5360\u7528\u96c6\u7fa4\u8f83\u591a\u7684\u8d44\u6e90\uff08CPU \u548c Memory\uff09\uff0c\u4f7f\u7528\u76f8\u5bf9\u590d\u6742\uff0c\u53ef\u4ee5\u505a\u4e3a\u4e00\u79cd\u5907\u9009\u65b9\u6848\u3002<\/p>\n\n\n\n<p>2.<code>\u57fa\u4e8e IBM Log Analysis<\/code>: \u8fd9\u662f IBM Cloud \u63d0\u4f9b\u7684\u57fa\u4e8e <a rel=\"noreferrer noopener\" href=\"https:\/\/www.logdna.com\/\" target=\"_blank\">LogDNA<\/a> \u7684\u65e5\u5fd7\u89e3\u51b3\u65b9\u6848\uff0c\u4f7f\u7528\u975e\u5e38\u7b80\u5355\uff0cLite Plan \u6709 30 \u5929\u7684\u514d\u8d39\u4f7f\u7528\u65f6\u95f4\u3002<\/p>\n\n\n\n<ul><li>4. \u96c6\u6210 IBM Log Analysis<\/li><\/ul>\n\n\n\n<p><a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/logdna#4-\u96c6\u6210-ibm-log-analysis\">\u200b<\/a>\u6253\u5f00 cluster \u9875\u9762<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-56-1024x542.png\" alt=\"\" class=\"wp-image-4117\" width=\"617\" height=\"326\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56-1024x542.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56-300x159.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56-768x407.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56-830x440.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56-230x122.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56-350x185.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56-480x254.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-56.png 1284w\" sizes=\"(max-width: 617px) 100vw, 617px\" \/><\/figure><\/div>\n\n\n\n<p>\u5411\u4e0b\u6eda\u52a8\u627e\u5230 Integrations > Logging\uff0c \u70b9\u51fb Connect<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-57-1024x362.png\" alt=\"\" class=\"wp-image-4118\" width=\"624\" height=\"220\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57-1024x362.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57-300x106.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57-768x271.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57-830x293.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57-230x81.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57-350x124.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57-480x169.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-57.png 1320w\" sizes=\"(max-width: 624px) 100vw, 624px\" \/><\/figure><\/div>\n\n\n\n<p>\u53ef\u4ee5\u9009\u62e9\u4e00\u4e2a\u73b0\u6709\u7684 IBM Log Analysis \u5b9e\u4f8b<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-58-1024x700.png\" alt=\"\" class=\"wp-image-4119\" width=\"576\" height=\"394\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58-1024x700.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58-300x205.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58-768x525.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58-830x567.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58-230x157.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58-350x239.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58-480x328.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-58.png 1256w\" sizes=\"(max-width: 576px) 100vw, 576px\" \/><\/figure><\/div>\n\n\n\n<p>\u5982\u679c\u6ca1\u6709\u5219\u521b\u5efa\u4e00\u4e2a\u65b0\u7684 Instance\uff0c (Lite Plan \u53ef\u4ee5\u514d\u8d39\u4f7f\u7528 1 \u4e2a\u6708)<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-59-1024x808.png\" alt=\"\" class=\"wp-image-4120\" width=\"548\" height=\"432\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59-1024x808.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59-300x237.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59-768x606.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59-830x655.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59-230x182.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59-350x276.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59-480x379.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-59.png 1272w\" sizes=\"(max-width: 548px) 100vw, 548px\" \/><\/figure><\/div>\n\n\n\n<ul><li>5. \u4f7f\u7528 IBM Log Analysis<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/logdna#5-\u4f7f\u7528-ibm-log-analysis\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>Instance \u521b\u5efa\u6210\u529f\u540e\uff0c \u70b9\u51fb Cluster \u9875\u9762 Integrations Logging \u4e0b\u7684 Launch \u6309\u94ae\u6253\u5f00 IBM Log Analysis \u63a7\u5236\u53f0.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-60-1024x222.png\" alt=\"\" class=\"wp-image-4121\" width=\"587\" height=\"127\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60-1024x222.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60-300x65.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60-768x167.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60-830x180.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60-230x50.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60-350x76.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60-480x104.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-60.png 1282w\" sizes=\"(max-width: 587px) 100vw, 587px\" \/><\/figure><\/div>\n\n\n\n<p>\u5728 Apps \u4e0b\u62c9\u83dc\u5355\u4e2d\u53ef\u4ee5\u770b\u5230\u96c6\u7fa4\u5185\u6240\u6709 app\uff0c\u5982\u4e0b\u56fe\u6240\u793a\uff0c\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u8f93\u5165 app \u7684\u540d\u5b57\uff0c\u6bd4\u5982<code>product<\/code>\u5b9a\u4f4d\u5230\u6211\u4eec\u7684\u5fae\u670d\u52a1\uff1a<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-61-1024x400.png\" alt=\"\" class=\"wp-image-4122\" width=\"612\" height=\"239\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61-1024x400.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61-300x117.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61-768x300.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61-830x325.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61-230x90.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61-350x137.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61-480x188.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-61.png 1294w\" sizes=\"(max-width: 612px) 100vw, 612px\" \/><\/figure><\/div>\n\n\n\n<p>\u6b64\u5904\u6211\u4eec\u52fe\u9009 <code>product-composite<\/code>\u548c<code>product<\/code>\u8fd9\u4e24\u4e2a app\uff0c\u70b9\u51fb Apply \u6309\u94ae<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-62-1024x760.png\" alt=\"\" class=\"wp-image-4123\" width=\"613\" height=\"455\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62-1024x760.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62-300x223.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62-768x570.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62-830x616.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62-230x171.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62-350x260.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62-480x356.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-62.png 1280w\" sizes=\"(max-width: 613px) 100vw, 613px\" \/><\/figure><\/div>\n\n\n\n<p>\u6d4f\u89c8\u5668\u65b0\u5f00\u4e00\u4e2a Tab \u9875\uff0c\u8f93\u5165\uff1a<a rel=\"noreferrer noopener\" href=\"https:\/\/gateway-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/product\/api\/v1\/products\" target=\"_blank\">https:\/\/gateway-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/product\/api\/v1\/products<\/a><\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-63-1024x463.png\" alt=\"\" class=\"wp-image-4124\" width=\"542\" height=\"244\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63-1024x463.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63-300x136.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63-768x347.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63-830x375.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63-230x104.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63-350x158.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63-480x217.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-63.png 1306w\" sizes=\"(max-width: 542px) 100vw, 542px\" \/><\/figure><\/div>\n\n\n\n<p>\u7a0d\u7b49\u7247\u523b\uff0c \u5c31\u53ef\u4ee5\u5728 IBM Log Analysis \u63a7\u5236\u53f0\u4e2d\u770b\u5230 Product \u5fae\u670d\u52a1\u8f93\u51fa\u7684\u65e5\u5fd7\uff1a<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-64-1024x478.png\" alt=\"\" class=\"wp-image-4125\" width=\"561\" height=\"262\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64-1024x478.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64-300x140.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64-768x358.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64-830x387.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64-230x107.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64-350x163.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64-480x224.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-64.png 1290w\" sizes=\"(max-width: 561px) 100vw, 561px\" \/><\/figure><\/div>\n\n\n\n<p>\u6211\u4eec\u53ef\u4ee5\u5c06\u5f53\u524d\u7684\u89c6\u56fe\u4fdd\u5b58\u8d77\u6765\uff0c \u5982\u4e0b\u56fe\u6240\u793a\uff0c\u6211\u4fdd\u5b58\u4e86\u4e00\u4e2a\u540d\u4e3a xxxcloud \u7684\u89c6\u56fe\uff0c\u7528\u6765\u67e5\u770b\u4e0e xxxcloud \u76f8\u5173\u7684 app \u65e5\u5fd7\u3002<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-65-1024x501.png\" alt=\"\" class=\"wp-image-4126\" width=\"570\" height=\"278\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65-1024x501.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65-300x147.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65-768x376.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65-830x406.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65-230x113.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65-350x171.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65-480x235.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-65.png 1328w\" sizes=\"(max-width: 570px) 100vw, 570px\" \/><\/figure><\/div>\n\n\n\n<ul><li>6. \u662f\u5426\u6709\u5fc5\u8981\u4f7f\u7528\u65e5\u5fd7\u6587\u4ef6\uff1f<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/logdna#6-\u662f\u5426\u6709\u5fc5\u8981\u4f7f\u7528\u65e5\u5fd7\u6587\u4ef6\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>Kubernetes \u5b98\u65b9\u63d0\u4f9b\u4e86 <a href=\"https:\/\/kubernetes.io\/docs\/concepts\/cluster-administration\/logging\/\" target=\"_blank\" rel=\"noreferrer noopener\">Logging \u67b6\u6784\u6307\u5bfc<\/a><\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><p>The easiest and most adopted logging method for containerized applications is writing to standard output and standard error streams.<\/p><\/blockquote>\n\n\n\n<p>\u8fd9\u6837\u505a\u6709\u4e24\u4e2a\u597d\u5904\uff1a<\/p>\n\n\n\n<ol><li>\u65b9\u4fbf\u4f7f\u7528 kubectl logs \u6216 oc logs \u547d\u4ee4\u67e5\u770b\u65e5\u5fd7<\/li><li>\u907f\u514d\u5197\u4f59\u7684\u65e5\u5fd7\u5b58\u50a8<\/li><\/ol>\n\n\n\n<p>\u5982\u679c\u9700\u8981\u6301\u4e45\u5316\u65e5\u5fd7\uff0c \u53ef\u4ee5\u8d2d\u4e70 IBM Log Analysis \u670d\u52a1\uff0c\u5c06\u65e5\u5fd7\u5f52\u6863\u5230 IBM Cloud Object Storage\uff0c \u4e5f\u53ef\u4ee5\u4f7f\u7528\u5f00\u6e90\u7684 EFK \u6280\u672f\u6808\uff0c \u5c06\u65e5\u5fd7\u901a\u8fc7 Fluentd \u5b58\u50a8\u5230 Elastic Search\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h5 class=\"wp-block-heading\">\u4f7f\u7528Secret<\/h5>\n\n\n\n<p>\u5728 spring boot \u5e94\u7528\u4e2d\uff0c\u901a\u8fc7 <code>application.yaml<\/code> \u914d\u7f6e\u5e94\u7528\u7a0b\u5e8f\u53c2\u6570\uff0c\u5176\u4e2d\u5305\u62ec DB \u7528\u6237\u540d\u548c\u5bc6\u7801\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">spring.config.activate.on-profile: openshift\nserver.port: 8080\nspring:\n  datasource:\n    password: mypassword\n    url: jdbc:postgresql:\/\/postgres:5432\/mydb\n    username: myusername<\/pre>\n\n\n\n<p>\u6211\u4eec\u5e0c\u671b\u5728\u751f\u4ea7\u73af\u5883\u4e0b\uff0c DB \u7684\u7528\u6237\u548c\u5bc6\u7801\u5bf9 Developer \u4e0d\u53ef\u89c1\u3002<\/p>\n\n\n\n<p>\u5728 Cloud \u73af\u5883\u4e0b\uff0c\u53ef\u4ee5\u4f7f\u7528 <a rel=\"noreferrer noopener\" href=\"https:\/\/kubernetes.io\/docs\/concepts\/configuration\/secret\/\" target=\"_blank\">Kubernetes Secret<\/a> \u5b58\u50a8\u7528\u6237\u540d\u548c\u5bc6\u7801\u7b49\u654f\u611f\u4fe1\u606f\u3002<\/p>\n\n\n\n<ul><li>1. \u521b\u5efa Secret<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/secret#1-\u521b\u5efa-secret\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>\u5728 OpenShift \u4e2d\u65b0\u5efa PostgreSQL \u6570\u636e\u5e93\u4ee5\u540e\uff0c \u5b9e\u9645\u4e0a OpenShift \u5df2\u7ecf\u4e3a\u6211\u4eec\u521b\u5efa\u4e86\u4e00\u4e2a\u540c\u540d\u7684 Secret.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-66-1024x638.png\" alt=\"\" class=\"wp-image-4128\" width=\"625\" height=\"389\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66-1024x638.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66-300x187.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66-768x478.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66-830x517.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66-230x143.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66-350x218.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66-480x299.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-66.png 1326w\" sizes=\"(max-width: 625px) 100vw, 625px\" \/><\/figure><\/div>\n\n\n\n<ul><li>2. \u67e5\u770b\u81ea\u52a8\u521b\u5efa\u7684 Secret<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/secret#2-\u67e5\u770b\u81ea\u52a8\u521b\u5efa\u7684-secret\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>\u5728 OpenShift \u4e2d\u521b\u5efa Postgres DB \u65f6\uff0c\u4f1a\u540c\u65f6\u521b\u5efa\u4e00\u4e2a\u540d\u4e3a postgres \u7684 Secret, \u91cc\u9762\u5305\u542b <code>database-name<\/code>, <code>database-password<\/code>, <code>database-user<\/code> 3 \u4e2a\u952e\u503c\u5bf9\u3002<\/p>\n\n\n\n<p>\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7 oc \u547d\u4ee4\u67e5\u770b Secret\uff0c \u627e\u5230\u8fd9 3 \u7ec4\u952e\u503c\u5bf9\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">$ oc get secret\n\nNAME            TYPE            DATA            AGE\npostgres  Opaque        3                   14d\n\n$ oc describe secret postgres\n\noc describe secret postgres\nName:         postgres\nNamespace:    jrecloud-dev\nLabels:  ...\n\nType:  Opaque\n\nData\n====\ndatabase-name:      8 bytes\ndatabase-password:  8 bytes\ndatabase-user:      8 bytes<\/pre>\n\n\n\n<ul><li>3. \u4fee\u6539 app \u914d\u7f6e\u6587\u4ef6<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/secret#3-\u4fee\u6539-app-\u914d\u7f6e\u6587\u4ef6\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>\u4e3a\u907f\u514d\u5c06\u5bc6\u7801\u6cc4\u6f0f\u7ed9 Developer\uff0c\u6211\u4eec\u4fee\u6539 spring boot \u7684 <code>application.yaml<\/code>\uff0c\u4f7f\u7528\u5982\u4e0b\u73af\u5883\u53d8\u91cf\u6765\u4ee3\u66ff\u5b9e\u9645\u7684\u5bc6\u7801\uff0c \u8fd9\u4e9b\u73af\u5883\u53d8\u91cf\u5c06\u4f1a\u5728\u4e0b\u4e00\u8282\u4e2d\u5b9a\u4e49\u3002<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">spring:\n  datasource:\n    driver-class-name: org.postgresql.Driver\n    password: ${POSTGRES_PASSWORD}\n    url: jdbc:postgresql:\/\/postgres:5432\/${POSTGRES_DB}\n    username: ${POSTGRES_USER}<\/pre>\n\n\n\n<p>4. \u901a\u8fc7 Web Console \u4f20\u9012 DB \u53c2\u6570<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/secret#4-\u901a\u8fc7-web-console-\u4f20\u9012-db-\u53c2\u6570\">\u200b<\/a><\/p>\n\n\n\n<p>\u5728 OpenShift web console \u4e2d\u65b0\u5efa App \u65f6\uff0c\u53ef\u4ee5\u4fee\u6539 Deployment \u7684\u914d\u7f6e\uff0c \u5411 Spring boot \u5e94\u7528\u7a0b\u5e8f(Container) \u4f20\u9012\u81ea\u5b9a\u4e49\u7684\u73af\u5883\u53d8\u91cf\u3002<\/p>\n\n\n\n<p>Topology > product \u5e94\u7528 \u56fe\u6807\u4e0a > \u53f3\u952e Edit product<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-67-1024x911.png\" alt=\"\" class=\"wp-image-4129\" width=\"582\" height=\"518\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67-1024x911.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67-300x267.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67-768x683.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67-830x739.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67-230x205.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67-350x311.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67-480x427.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-67.png 1272w\" sizes=\"(max-width: 582px) 100vw, 582px\" \/><\/figure><\/div>\n\n\n\n<p>\u70b9\u51fb Deployment \u5c55\u5f00\u66f4\u591a\u914d\u7f6e\uff0c \u5982\u4e0b\uff1a<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-68-1024x669.png\" alt=\"\" class=\"wp-image-4130\" width=\"587\" height=\"383\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68-1024x669.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68-300x196.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68-768x501.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68-830x542.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68-230x150.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68-350x229.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68-480x313.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-68.png 1308w\" sizes=\"(max-width: 587px) 100vw, 587px\" \/><\/figure><\/div>\n\n\n\n<p>\u7136\u540e\u70b9\u51fb Add from ConfigMap or Secret:<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-69-1024x510.png\" alt=\"\" class=\"wp-image-4131\" width=\"585\" height=\"291\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69-1024x510.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69-300x149.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69-768x382.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69-830x413.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69-230x114.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69-350x174.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69-480x239.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-69.png 1298w\" sizes=\"(max-width: 585px) 100vw, 585px\" \/><\/figure><\/div>\n\n\n\n<p>\u91cd\u590d 3 \u6b21\u521b\u5efa\u5982\u4e0b 3 \u4e2a\u73af\u5883\u53d8\u91cf:<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/123.57.164.21\/wp-content\/uploads\/2021\/11\/image-70-1024x985.png\" alt=\"\" class=\"wp-image-4132\" width=\"537\" height=\"517\" srcset=\"https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70-1024x985.png 1024w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70-300x288.png 300w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70-768x739.png 768w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70-830x798.png 830w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70-230x221.png 230w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70-350x337.png 350w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70-480x462.png 480w, https:\/\/92it.top\/wp-content\/uploads\/2021\/11\/image-70.png 1302w\" sizes=\"(max-width: 537px) 100vw, 537px\" \/><\/figure><\/div>\n\n\n\n<p>\u70b9\u51fb Save \u6309\u94ae\uff0c \u7b49\u5f85 product app \u91cd\u65b0\u90e8\u7f72\u3002<\/p>\n\n\n\n<p>\u81f3\u6b64\uff0c\u6211\u4eec\u5df2\u7ecf\u5c06<code>application.yaml<\/code>\u4e2d\u660e\u6587\u5bc6\u7801\u66ff\u6362\u6210\u4e86\u73af\u5883\u53d8\u91cf\uff0c\u5e76\u4e14\u5728\u521b\u5efa app \u65f6\u901a\u8fc7 Add from Secret \u7684\u65b9\u5f0f\u7ed9\u8fd9\u4e9b\u73af\u5883\u53d8\u91cf\u8bbe\u5b9a\u4e86\u6b63\u786e\u7684\u503c\u3002<\/p>\n\n\n\n<ul><li>5. \u901a\u8fc7 yaml \u6587\u4ef6\u4f20\u9012 DB \u53c2\u6570(\u8865\u5145)<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/secret#5-\u901a\u8fc7-yaml-\u6587\u4ef6\u4f20\u9012-db-\u53c2\u6570\u8865\u5145\">\u200b<\/a><\/li><\/ul>\n\n\n\n<p>\u4e0d\u901a\u8fc7 OpenShift web console\uff0c\u6211\u4eec\u53ef\u4ee5\u76f4\u63a5\u4fee\u6539 deployment.yaml \u6587\u4ef6\uff0c\u5411 spring boot \u5e94\u7528\u4f20\u9012 DB \u53c2\u6570\u3002<\/p>\n\n\n\n<ol><li>\u53d8\u91cf\u540d\u548c spring boot application.yaml \u4e2d\u5c06\u8981\u7528\u5230\u7684\u540d\u5b57\u4e00\u81f4<\/li><li>\u53d8\u91cf\u503c\u5219\u6765\u81ea\u540d\u4e3a postgres \u7684 Secret\u3002<\/li><\/ol>\n\n\n\n<p>\u5982\u4e0b\uff08deployment.yaml\uff09<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">spec:\n  template:\n    spec:\n      containers:\n        - env:\n            - name: POSTGRES_USER\n              valueFrom:\n                secretKeyRef:\n                  name: postgres\n                  key: database-user\n            - name: POSTGRES_PASSWORD\n              valueFrom:\n                secretKeyRef:\n                  name: postgres\n                  key: database-password\n            - name: POSTGRES_DB\n              valueFrom:\n                secretKeyRef:\n                  name: postgres\n                  key: database-name<\/pre>\n\n\n\n<p>\u6700\u540e\uff0c \u6267\u884c <code>oc apply -f deployment.yaml<\/code> \u5e94\u7528\u53d8\u66f4\u3002<\/p>\n\n\n\n<p>6. \u901a\u8fc7\u547d\u4ee4\u884c\u521b\u5efa Secret(\u8865\u5145)<a href=\"https:\/\/doc-jrecloud-dev.roks-iip-48-2029222ed72d9643e3d07091333056f5-0000.jp-tok.containers.appdomain.cloud\/docs\/intermediate\/OpenShift\/secret#6-\u901a\u8fc7\u547d\u4ee4\u884c\u521b\u5efa-secret\u8865\u5145\">\u200b<\/a><\/p>\n\n\n\n<p>\u901a\u8fc7 <code>kubectl create secret<\/code> \u6216 <code>oc create secret<\/code> \u547d\u4ee4\u521b\u5efa Secret\uff0c\u5982\u4e0b\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">$ oc create secret generic postgres \\\n--from-literal=database-db=mydb \\\n--from-literal=database-user=myname \\\n--from-literal=database-password=mysecret<\/pre>\n\n\n\n<p>\u8f93\u5165 <code>oc create secret<\/code> \u67e5\u770b\u4e0e \u521b\u5efa Secret \u76f8\u5173\u7684\u5e2e\u52a9\u4fe1\u606f\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">$ oc create secret\nCreate a secret using specified subcommand.\n\nUsage:\n  oc create secret [flags]\n\nAvailable Commands:\n  docker-registry Create a secret for use with a Docker registry\n  generic         Create a secret from a local file, directory or literal value\n  tls             Create a TLS secret\n\nUse \"oc &lt;command> --help\" for more information about a given command.\nUse \"oc options\" for a list of global command-line options (applies to all commands).<\/pre>\n\n\n\n<p>\u8f93\u5165 <code>oc help secret<\/code> \u67e5\u770b\u4f7f\u7528 Secret \u76f8\u5173\u7684\u5e2e\u52a9\u4fe1\u606f\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">$ oc help secret\nManage secrets in your project\n\n Secrets are used to store confidential information that should not be contained inside of an image. They are commonly\nused to hold things like keys for authentication to other internal systems like container image registries.\n\nAliases:\nsecrets, secret\n\nUsage:\n  oc secrets [flags]\n\nAvailable Commands:\n  link        Link secrets to a service account\n  unlink      Detach secrets from a service account\n\nUse \"oc &lt;command> --help\" for more information about a given command.\nUse \"oc options\" for a list of global command-line options (applies to all commands).<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u672c\u5730\u8fde\u63a5OpenShift\u4e0a\u7684DB 1.\u547d\u4ee4\u884c\u767b\u5f55\u5230 OpenShift\uff0c \u627e\u5230 postgres \u7684 pod [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[25],"tags":[],"_links":{"self":[{"href":"https:\/\/92it.top\/index.php?rest_route=\/wp\/v2\/posts\/4114"}],"collection":[{"href":"https:\/\/92it.top\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/92it.top\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/92it.top\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/92it.top\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4114"}],"version-history":[{"count":4,"href":"https:\/\/92it.top\/index.php?rest_route=\/wp\/v2\/posts\/4114\/revisions"}],"predecessor-version":[{"id":4133,"href":"https:\/\/92it.top\/index.php?rest_route=\/wp\/v2\/posts\/4114\/revisions\/4133"}],"wp:attachment":[{"href":"https:\/\/92it.top\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4114"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/92it.top\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4114"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/92it.top\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4114"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}