[20180317]12c TABLE ACCESS BY INDEX ROWID BATCHED2.txt

来源:https://www.cnblogs.com/lfree/archive/2018/03/19/8599115.html
-Advertisement-
Play Games

[20180317]12c TABLE ACCESS BY INDEX ROWID BATCHED2.txt--//簡單探究12c TABLE ACCESS BY INDEX ROWID BATCHED特性.--//當使用12c時,執行計划出現TABLE ACCESS BY INDEX ROWID ...


[20180317]12c TABLE ACCESS BY INDEX ROWID BATCHED2.txt

--//簡單探究12c TABLE ACCESS BY INDEX ROWID BATCHED特性.
--//當使用12c時,執行計划出現TABLE ACCESS BY INDEX ROWID BATCHED,做一些探究.
--//本文主要探究如何使用提示或者隱含參數控制這種特性.

1.環境:

SCOTT@test01p> @ ver1
PORT_STRING                    VERSION        BANNER                                                                               CON_ID
------------------------------ -------------- -------------------------------------------------------------------------------- ----------
IBMPC/WIN_NT64-9.1.0           12.1.0.1.0     Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production              0

SCOTT@test01p> show array
arraysize 200

SCOTT@test01p> create table t as select * from all_objects order by  DBMS_RANDOM.random;
Table created.

SCOTT@test01p> create index i_t_object_id on t(object_id);
Index created.

--//分析.
execute sys.dbms_stats.gather_table_stats ( OwnName => nvl('',user),TabName => 't',Estimate_Percent => NULL,Method_Opt => 'FOR ALL COLUMNS SIZE 1 ',Cascade => True ,No_Invalidate => false)

SCOTT@test01p> select rowid ,owner from t where object_id  between  1 and 10;
ROWID              OWNER
------------------ --------------------
AAAaKPAAJAAAAY7AAE SYS
AAAaKPAAJAAAAaWAAP SYS
AAAaKPAAJAAAARtAAd SYS
AAAaKPAAJAAAAK5AAw SYS
AAAaKPAAJAAAAbGAAV SYS
AAAaKPAAJAAAAIFAAK SYS
AAAaKPAAJAAAASIAAB SYS
AAAaKPAAJAAAAMIAAQ SYS
AAAaKPAAJAAAAOMAAp SYS
9 rows selected.

SCOTT@test01p> select data_object_id,object_id from dba_objects where owner=user and object_name='T';
DATA_OBJECT_ID  OBJECT_ID
-------------- ----------
        107151     107151

--//看看那些參數可以控制取消TABLE ACCESS BY INDEX ROWID BATCHED特性.

2.測試:
--//通過隱含參數_optimizer_batch_table_access_by_rowid可以改變執行計劃.
SYS@test> @ hide _optimizer_batch_table_access_by_rowid
NAME                                     DESCRIPTION                              DEFAULT_VALUE SESSION_VALUE SYSTEM_VALUE
---------------------------------------- ---------------------------------------- ------------- ------------- ------------
_optimizer_batch_table_access_by_rowid   enable table access by ROWID IO batching TRUE          TRUE          TRUE

SCOTT@test01p> alter session set statistics_level=all;
Session altered.

SCOTT@test01p> select rowid ,owner from t where object_id  between  1 and 10;
ROWID              OWNER
------------------ -----
AAAaKPAAJAAAAY7AAE SYS
AAAaKPAAJAAAAaWAAP SYS
AAAaKPAAJAAAARtAAd SYS
AAAaKPAAJAAAAK5AAw SYS
AAAaKPAAJAAAAbGAAV SYS
AAAaKPAAJAAAAIFAAK SYS
AAAaKPAAJAAAASIAAB SYS
AAAaKPAAJAAAAMIAAQ SYS
AAAaKPAAJAAAAOMAAp SYS
9 rows selected.

SCOTT@test01p> @ dpc '' ''
PLAN_TABLE_OUTPUT
-------------------------------------
SQL_ID  anscphj6zbgpn, child number 0
-------------------------------------
select rowid ,owner from t where object_id  between  1 and 10
Plan hash value: 2683697726
---------------------------------------------------------------------------------------------------------------------------------------
| Id  | Operation                   | Name          | Starts | E-Rows |E-Bytes| Cost (%CPU)| E-Time   | A-Rows |   A-Time   | Buffers |
---------------------------------------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT            |               |      1 |        |       |    10 (100)|          |      9 |00:00:00.01 |      12 |
|   1 |  TABLE ACCESS BY INDEX ROWID| T             |      1 |      8 |   184 |    10   (0)| 00:00:01 |      9 |00:00:00.01 |      12 |
|*  2 |   INDEX RANGE SCAN          | I_T_OBJECT_ID |      1 |      8 |       |     2   (0)| 00:00:01 |      9 |00:00:00.01 |       3 |
---------------------------------------------------------------------------------------------------------------------------------------
Query Block Name / Object Alias (identified by operation id):
-------------------------------------------------------------
   1 - SEL$1 / T@SEL$1
   2 - SEL$1 / T@SEL$1
Predicate Information (identified by operation id):
---------------------------------------------------
   2 - access("OBJECT_ID">=1 AND "OBJECT_ID"<=10)

--//現在執行使用TABLE ACCESS BY INDEX ROWID.順便測試10046事件的跟蹤情況.

SCOTT@test01p> alter system flush buffer_cache ;
System altered.

@ 10046on 12
select rowid ,owner from t where object_id  between  1 and 10;
@ 10046off

--//轉儲文件:
=====================
PARSING IN CURSOR #180365864 len=61 dep=0 uid=109 oct=3 lid=109 tim=1785413706 hv=1307950772 ad='7ff1292e768' sqlid='anscphj6zbgpn'
select rowid ,owner from t where object_id  between  1 and 10
END OF STMT
PARSE #180365864:c=62400,e=231012,p=15,cr=141,cu=0,mis=1,r=0,dep=0,og=1,plh=2683697726,tim=1785413704
EXEC #180365864:c=0,e=45,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=1,plh=2683697726,tim=1785413932
WAIT #180365864: nam='SQL*Net message to client' ela= 7 driver id=1413697536 #bytes=1 p3=0 obj#=665 tim=1785414043
WAIT #180365864: nam='db file sequential read' ela= 14145 file#=9 block#=363 blocks=1 obj#=107152 tim=1785428269
WAIT #180365864: nam='db file sequential read' ela= 315 file#=9 block#=364 blocks=1 obj#=107152 tim=1785428826
WAIT #180365864: nam='db file sequential read' ela= 5921 file#=9 block#=1595 blocks=1 obj#=107151 tim=1785434811
FETCH #180365864:c=0,e=20917,p=3,cr=3,cu=0,mis=0,r=1,dep=0,og=1,plh=2683697726,tim=1785435009
WAIT #180365864: nam='SQL*Net message from client' ela= 594 driver id=1413697536 #bytes=1 p3=0 obj#=107151 tim=1785435681
WAIT #180365864: nam='db file sequential read' ela= 7635 file#=9 block#=1686 blocks=1 obj#=107151 tim=1785443416
WAIT #180365864: nam='SQL*Net message to client' ela= 5 driver id=1413697536 #bytes=1 p3=0 obj#=107151 tim=1785443628
WAIT #180365864: nam='db file sequential read' ela= 17772 file#=9 block#=1133 blocks=1 obj#=107151 tim=1785461472
WAIT #180365864: nam='db file sequential read' ela= 6360 file#=9 block#=697 blocks=1 obj#=107151 tim=1785468019
WAIT #180365864: nam='db file sequential read' ela= 276 file#=9 block#=1734 blocks=1 obj#=107151 tim=1785468533
WAIT #180365864: nam='db file sequential read' ela= 6200 file#=9 block#=517 blocks=1 obj#=107151 tim=1785474873
WAIT #180365864: nam='db file sequential read' ela= 10777 file#=9 block#=1160 blocks=1 obj#=107151 tim=1785485815
WAIT #180365864: nam='db file sequential read' ela= 11727 file#=9 block#=776 blocks=1 obj#=107151 tim=1785497741
WAIT #180365864: nam='db file sequential read' ela= 11447 file#=9 block#=908 blocks=1 obj#=107151 tim=1785509403
FETCH #180365864:c=0,e=73927,p=8,cr=9,cu=0,mis=0,r=8,dep=0,og=1,plh=2683697726,tim=1785509674
STAT #180365864 id=1 cnt=9 pid=0 pos=1 obj=107151 op='TABLE ACCESS BY INDEX ROWID T (cr=12 pr=11 pw=0 time=94758 us cost=10 size=184 card=8)'
STAT #180365864 id=2 cnt=9 pid=1 pos=1 obj=107152 op='INDEX RANGE SCAN I_T_OBJECT_ID (cr=3 pr=2 pw=0 time=14819 us cost=2 size=0 card=8)'

*** 2018-03-17 19:56:06.875
WAIT #180365864: nam='SQL*Net message from client' ela= 3228967 driver id=1413697536 #bytes=1 p3=0 obj#=107151 tim=1788738943
CLOSE #180365864:c=0,e=11,dep=0,type=0,tim=1788739114
=====================

--//可以看到IO的等待事件全是'db file sequential read'.沒有'db file parallel read'.

3.測試二:
--//使用NO_BATCH_TABLE_ACCESS_BY_ROWID提示.
SCOTT@test01p> @ sqlhint BATCH_TABLE_ACCESS_BY_ROWID
NAME                           SQL_FEATURE     CLASS                       INVERSE                        TARGET_LEVEL PROPERTY VERSION  VERSION_OUTLINE CON_ID
------------------------------ --------------- --------------------------- ------------------------------ ------------ -------- -------- --------------- ------
BATCH_TABLE_ACCESS_BY_ROWID    QKSFM_EXECUTION BATCH_TABLE_ACCESS_BY_ROWID NO_BATCH_TABLE_ACCESS_BY_ROWID            4      272 12.1.0.1 12.1.0.1             0
NO_BATCH_TABLE_ACCESS_BY_ROWID QKSFM_EXECUTION BATCH_TABLE_ACCESS_BY_ROWID BATCH_TABLE_ACCESS_BY_ROWID               4      272 12.1.0.1 12.1.0.1             0

---//重新登錄,取消參數隱含參數_optimizer_batch_table_access_by_rowid設置,執行如下:

SCOTT@test01p> select /*+ NO_BATCH_TABLE_ACCESS_BY_ROWID */ rowid ,owner from t where object_id  between  1 and 10;

SCOTT@test01p> @ dpc '' outline
PLAN_TABLE_OUTPUT
-------------------------------------
SQL_ID  9c0n73wph7xax, child number 0
-------------------------------------
select /*+ NO_BATCH_TABLE_ACCESS_BY_ROWID */ rowid ,owner from t where
object_id  between  1 and 10
Plan hash value: 2044526593
-----------------------------------------------------------------------------------------------------------------------------------------------
| Id  | Operation                           | Name          | Starts | E-Rows |E-Bytes| Cost (%CPU)| E-Time   | A-Rows |   A-Time   | Buffers |
-----------------------------------------------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT                    |               |      1 |        |       |    10 (100)|          |      9 |00:00:00.01 |      12 |
|   1 |  TABLE ACCESS BY INDEX ROWID BATCHED| T             |      1 |      8 |   184 |    10   (0)| 00:00:01 |      9 |00:00:00.01 |      12 |
|*  2 |   INDEX RANGE SCAN                  | I_T_OBJECT_ID |      1 |      8 |       |     2   (0)| 00:00:01 |      9 |00:00:00.01 |       3 |
-----------------------------------------------------------------------------------------------------------------------------------------------

Query Block Name / Object Alias (identified by operation id):
-------------------------------------------------------------

   1 - SEL$1 / T@SEL$1
   2 - SEL$1 / T@SEL$1

Outline Data
-------------

  /*+
      BEGIN_OUTLINE_DATA
      IGNORE_OPTIM_EMBEDDED_HINTS
      OPTIMIZER_FEATURES_ENABLE('12.1.0.1')
      DB_VERSION('12.1.0.1')
      ALL_ROWS
      OUTLINE_LEAF(@"SEL$1")
      INDEX_RS_ASC(@"SEL$1" "T"@"SEL$1" ("T"."OBJECT_ID"))
      BATCH_TABLE_ACCESS_BY_ROWID(@"SEL$1" "T"@"SEL$1")
      END_OUTLINE_DATA
  */

Predicate Information (identified by operation id):
---------------------------------------------------

   2 - access("OBJECT_ID">=1 AND "OBJECT_ID"<=10)
--//可以發現這樣使用提示並不生效,實際上還是TABLE ACCESS BY INDEX ROWID BATCHED.不過看Outline Data就知道提示的方法,要寫成如下:

select /*+ NO_BATCH_TABLE_ACCESS_BY_ROWID(@"SEL$1" "T"@"SEL$1") */ rowid ,owner from t where object_id  between  1 and 10;
select /*+ NO_BATCH_TABLE_ACCESS_BY_ROWID(t) */ rowid ,owner from t where object_id  between  1 and 10;

SCOTT@test01p> @ dpc '' ''
PLAN_TABLE_OUTPUT
-------------------------------------
SQL_ID  7y2913wgp3t1b, child number 0
-------------------------------------
select /*+ NO_BATCH_TABLE_ACCESS_BY_ROWID(t) */ rowid ,owner from t
where object_id  between  1 and 10

Plan hash value: 2683697726

---------------------------------------------------------------------------------------------------------------------------------------
| Id  | Operation                   | Name          | Starts | E-Rows |E-Bytes| Cost (%CPU)| E-Time   | A-Rows |   A-Time   | Buffers |
---------------------------------------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT            |               |      1 |        |       |    10 (100)|          |      9 |00:00:00.01 |      12 |
|   1 |  TABLE ACCESS BY INDEX ROWID| T             |      1 |      8 |   184 |    10   (0)| 00:00:01 |      9 |00:00:00.01 |      12 |
|*  2 |   INDEX RANGE SCAN          | I_T_OBJECT_ID |      1 |      8 |       |     2   (0)| 00:00:01 |      9 |00:00:00.01 |       3 |
---------------------------------------------------------------------------------------------------------------------------------------

Query Block Name / Object Alias (identified by operation id):
-------------------------------------------------------------

   1 - SEL$1 / T@SEL$1
   2 - SEL$1 / T@SEL$1

Predicate Information (identified by operation id):
---------------------------------------------------

   2 - access("OBJECT_ID">=1 AND "OBJECT_ID"<=10)

--//執行計劃變為TABLE ACCESS BY INDEX ROWID.

--//順便更正我以前一個錯誤的觀點,一直以為執行計劃選擇TABLE ACCESS BY INDEX ROWID BATCHED邏輯讀會減少,實際上不會變化,
--//因為輸出的結果集順序沒有發生變化.可以看到最後的邏輯讀都是一樣的12.
--//我以前錯誤的理解確定讀取掃描的數據塊,然後輸出滿足條件的結果.實際上還是按照索引的順序讀取鍵值以及rowid,再讀取數據塊.
--//TABLE ACCESS BY INDEX ROWID BATCHED僅僅變成了db file parallel read,而且讀取的數據塊是按照順序讀取,並且是不連續的塊,
--//最大127塊(當然數據塊不在緩存的情況下).

--//在看看如下例子:

SCOTT@test01p> select /*+ index(t)  */ rowid ,owner,object_id from t where object_id  between  1 and 520;
..

PLAN_TABLE_OUTPUT
-------------------------------------
SQL_ID  53r6yurs7jnk8, child number 0
-------------------------------------
select /*+ index(t)  */ rowid ,owner,object_id from t where object_id between  1 and 520
Plan hash value: 2044526593
-----------------------------------------------------------------------------------------------------------------------------------------------
| Id  | Operation                           | Name          | Starts | E-Rows |E-Bytes| Cost (%CPU)| E-Time   | A-Rows |   A-Time   | Buffers |
-----------------------------------------------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT                    |               |      1 |        |       |   437 (100)|          |    474 |00:00:00.01 |     479 |
|   1 |  TABLE ACCESS BY INDEX ROWID BATCHED| T             |      1 |    435 | 10005 |   437   (0)| 00:00:01 |    474 |00:00:00.01 |     479 |
|*  2 |   INDEX RANGE SCAN                  | I_T_OBJECT_ID |      1 |    435 |       |     2   (0)| 00:00:01 |    474 |00:00:00.01 |       5 |
-----------------------------------------------------------------------------------------------------------------------------------------------

SCOTT@test01p> select /*+ index(t) NO_BATCH_TABLE_ACCESS_BY_ROWID(t) */ rowid ,owner,object_id from t where object_id  between  1 and 520;
...
PLAN_TABLE_OUTPUT
-------------------------------------
SQL_ID  3kf824wz4rdk5, child number 0
-------------------------------------
select /*+ index(t) NO_BATCH_TABLE_ACCESS_BY_ROWID(t) */ rowid ,owner,object_id from t where object_id  between  1 and 520
Plan hash value: 2683697726
---------------------------------------------------------------------------------------------------------------------------------------
| Id  | Operation                   | Name          | Starts | E-Rows |E-Bytes| Cost (%CPU)| E-Time   | A-Rows |   A-Time   | Buffers |
---------------------------------------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT            |               |      1 |        |       |   437 (100)|          |    474 |00:00:00.01 |     479 |
|   1 |  TABLE ACCESS BY INDEX ROWID| T             |      1 |    435 | 10005 |   437   (0)| 00:00:01 |    474 |00:00:00.01 |     479 |
|*  2 |   INDEX RANGE SCAN          | I_T_OBJECT_ID |      1 |    435 |       |     2   (0)| 00:00:01 |    474 |00:00:00.01 |       5 |
---------------------------------------------------------------------------------------------------------------------------------------

--//可以發現邏輯讀479.兩種情況都是一樣的.只有參數array以及索引的群集因數才可能改變邏輯讀的數量.這裡的數據太離散,改變array效果不會太大.

SCOTT@test01p> set array 300
SCOTT@test01p> select /*+ index(t)  */ rowid ,owner,object_id from t where object_id  between  1 and 520;
..

Plan hash value: 2044526593
-----------------------------------------------------------------------------------------------------------------------------------------------
| Id  | Operation                           | Name          | Starts | E-Rows |E-Bytes| Cost (%CPU)| E-Time   | A-Rows |   A-Time   | Buffers |
-----------------------------------------------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT                    |               |      1 |        |       |   437 (100)|          |    474 |00:00:00.01 |     478 |
|   1 |  TABLE ACCESS BY INDEX ROWID BATCHED| T             |      1 |    435 | 10005 |   437   (0)| 00:00:01 |    474 |00:00:00.01 |     478 |
|*  2 |   INDEX RANGE SCAN                  | I_T_OBJECT_ID |      1 |    435 |       |     2   (0)| 00:00:01 |    474 |00:00:00.01 |       4 |
-----------------------------------------------------------------------------------------------------------------------------------------------

--//僅僅減少1個.而且在INDEX RANGE SCAN操作,減少到4個.

--//重新建立表按照object_id導入:
SCOTT@test01p> create table tx as select * from t order by object_id;
Table created.

SCOTT@test01p> create index i_tx_object_id on tx(object_id);
Index created.

--//分析略.
SCOTT@test01p> set array 200
SCOTT@test01p> show array
arraysize 200

SCOTT@test01p> select /*+ index(t)  */ rowid ,owner,object_id from tx where object_id  between  1 and 520;

Plan hash value: 475430699
------------------------------------------------------------------------------------------------------------------------------------------------
| Id  | Operation                           | Name           | Starts | E-Rows |E-Bytes| Cost (%CPU)| E-Time   | A-Rows |   A-Time   | Buffers |
------------------------------------------------------------------------------------------------------------------------------------------------
|   0 | SELECT STATEMENT                    |                |      1 |        |       |    10 (100)|          |    474 |00:00:00.01 |      15 |
|   1 |  TABLE ACCESS BY INDEX ROWID BATCHED| TX             |      1 |    435 | 10005 |    10   (0)| 00:00:01 |    474 |00:00:00.01 |      15 |
|*  2 |   INDEX RANGE SCAN                  | I_TX_OBJECT_ID |      1 |    435 |       |     2   (0)| 00:00:01 |    474 |00:00:00.01 |       5 |
------------------------------------------------------------------------------------------------------------------------------------------------


您的分享是我們最大的動力!

-Advertisement-
Play Games
更多相關文章
  • 在Angularjs顯示html文本,如果按照一般處理它。它只能頁中顯示沒經解釋文本。在ASP.NET MVC添加一個控制器: 創建angularjs控制器: pilotApp.controller('ShowHtmlCtrl', ['$scope','$sce', function ($scope ...
  • 對於一個應用來說界面的重要性無言而喻,而Web應用的界面是使用Html+Css以及Javascript實現的,ASP.NET MVC是一個用來構建Web應用的框架,它的界面也是Html實現的,對於一些開發團隊來說,一般Web項目會存在專業的UI前端工程師和後端工程師,前端工程師可能只懂設計和Html ...
  • 最近學習asp.netcore 打算寫出來和大家分享,我計劃先寫Identity部分,會從開始asp.netocre identity的簡單實用開始,然後再去講解主要的類和自定義這些類。 主題:asp.netcore Identity 的簡單實用 創建項目: 使用asp.netcore 項目模版創建 ...
  • 短距離無線通信是物聯網的基礎,隨著物聯網IoT的火熱發展,各種短距離無線通信協議也是層出不窮,這些協議標準各有優缺以及應用場合。各種協議並存的現象將長期存在,沒有人能夠解決無線短距離互聯標準不統一的問題,因為行業發展太快而標準跟不上,短期內還看不到一統江湖的短距離無線標準。今天痞子衡就用一張表為大家... ...
  • linux常用輸入函數scanf和fgets通常都是阻塞式的: 1、如果用戶沒有輸入,則程式會阻塞等待用戶輸入輸入內容後,且需要用戶點回車鍵才能完成讀取鍵盤輸入。 2、用戶輸入的信息,會在屏幕上顯示出來。 以下代碼實現了: 1、用戶沒有輸入,則在設定時間過後,程式會繼續運行下去 2、用戶輸入信息不會 ...
  • CentOS版本7.2,MySql版本5.7 1、安裝MySql,安裝前先跟新軟體源,安裝過程中會提示設置root密碼 sudo apt-get update sudo apt-get install mysql-server 2、配置遠程訪問 編輯配置文件 sudo vi /etc/mysql/m ...
  • Linux的文件訪問許可權分為 讀、寫、執行三種 r:可讀(4) w:可寫(2)對目錄來說則可新建文件 x:可執行(1)對目錄來說則可進入該目錄 可用 ls -l 查看文件 像上圖的-rw-r--rw- 其中的第一個字元表示的是文件類型(- 表示普通文件,d 表示目錄文件,c : 為字元串設備,若路由 ...
  • 一、學Linux網路命令有什麼好處 網路的出現,我們的生活更方便了,處理事情的效率也越來越高,也可以看到全世界文化的差異。同時我們接受新事物的信息越來越來強,新事物的信息也越來越來多。網路對於我們爾等平民百姓來講就是透明的只知道有網線而已,但是對於我們程式猿來講,需要理解網路的相關知識,什麼IP地址 ...
一周排行
    -Advertisement-
    Play Games
  • 移動開發(一):使用.NET MAUI開發第一個安卓APP 對於工作多年的C#程式員來說,近來想嘗試開發一款安卓APP,考慮了很久最終選擇使用.NET MAUI這個微軟官方的框架來嘗試體驗開發安卓APP,畢竟是使用Visual Studio開發工具,使用起來也比較的順手,結合微軟官方的教程進行了安卓 ...
  • 前言 QuestPDF 是一個開源 .NET 庫,用於生成 PDF 文檔。使用了C# Fluent API方式可簡化開發、減少錯誤並提高工作效率。利用它可以輕鬆生成 PDF 報告、發票、導出文件等。 項目介紹 QuestPDF 是一個革命性的開源 .NET 庫,它徹底改變了我們生成 PDF 文檔的方 ...
  • 項目地址 項目後端地址: https://github.com/ZyPLJ/ZYTteeHole 項目前端頁面地址: ZyPLJ/TreeHoleVue (github.com) https://github.com/ZyPLJ/TreeHoleVue 目前項目測試訪問地址: http://tree ...
  • 話不多說,直接開乾 一.下載 1.官方鏈接下載: https://www.microsoft.com/zh-cn/sql-server/sql-server-downloads 2.在下載目錄中找到下麵這個小的安裝包 SQL2022-SSEI-Dev.exe,運行開始下載SQL server; 二. ...
  • 前言 隨著物聯網(IoT)技術的迅猛發展,MQTT(消息隊列遙測傳輸)協議憑藉其輕量級和高效性,已成為眾多物聯網應用的首選通信標準。 MQTTnet 作為一個高性能的 .NET 開源庫,為 .NET 平臺上的 MQTT 客戶端與伺服器開發提供了強大的支持。 本文將全面介紹 MQTTnet 的核心功能 ...
  • Serilog支持多種接收器用於日誌存儲,增強器用於添加屬性,LogContext管理動態屬性,支持多種輸出格式包括純文本、JSON及ExpressionTemplate。還提供了自定義格式化選項,適用於不同需求。 ...
  • 目錄簡介獲取 HTML 文檔解析 HTML 文檔測試參考文章 簡介 動態內容網站使用 JavaScript 腳本動態檢索和渲染數據,爬取信息時需要模擬瀏覽器行為,否則獲取到的源碼基本是空的。 本文使用的爬取步驟如下: 使用 Selenium 獲取渲染後的 HTML 文檔 使用 HtmlAgility ...
  • 1.前言 什麼是熱更新 游戲或者軟體更新時,無需重新下載客戶端進行安裝,而是在應用程式啟動的情況下,在內部進行資源或者代碼更新 Unity目前常用熱更新解決方案 HybridCLR,Xlua,ILRuntime等 Unity目前常用資源管理解決方案 AssetBundles,Addressable, ...
  • 本文章主要是在C# ASP.NET Core Web API框架實現向手機發送驗證碼簡訊功能。這裡我選擇是一個互億無線簡訊驗證碼平臺,其實像阿裡雲,騰訊雲上面也可以。 首先我們先去 互億無線 https://www.ihuyi.com/api/sms.html 去註冊一個賬號 註冊完成賬號後,它會送 ...
  • 通過以下方式可以高效,並保證數據同步的可靠性 1.API設計 使用RESTful設計,確保API端點明確,並使用適當的HTTP方法(如POST用於創建,PUT用於更新)。 設計清晰的請求和響應模型,以確保客戶端能夠理解預期格式。 2.數據驗證 在伺服器端進行嚴格的數據驗證,確保接收到的數據符合預期格 ...