簡體   English   中英

JAVA線程分配?

[英]JAVA thread allocation?

我的程序在Eclipse中運行,所有過程僅在單個線程中完成。 我將其部署到客戶端計算機時遇到問題(我不確定計算機的配置)。

在此過程中,線程突然從btpool0-1更改為btpool0-1 我確定我沒有在編碼中創建任何線程。

我想知道為什么會有這種原因嗎?

提前致謝!!

=======在這里記錄========================================= ============

2016-01-20 12:03:58.784 [btpool0-1]信息hk.com.xx.sys.service.impl.BargeVoyageServiceImpl-在saveAndSynchronize中結束向nSys的提交請求

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.persistence.TransactionCoordinator-在線程2055564603中提交事務ID 1656368712之前刷新

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.persistence.DefaultEntityManager-為上下文880330942 2016-01-20中的事務2028663310中的會話2055564603中的線程2055564603中的customFramework manager 1801910956的委托481556314運行刷新03:58.877 [btpool0-1]調試customFramework.ro.security.remote.RemotecustomFrameworkManager-為上下文2031793559中會話2099793559中的線程2055564603中的customFramework Manager 146387751的委托1470155242運行刷新操作,上下文1631574962

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.persistence.TransactionCoordinator-在線程2055564603中提交事務ID 1656368712

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.persistence.DefaultcustomFrameworkManager-上下文880330942中的事務2028663310中的會話2055564603中的線程2055564603中的customFramework Manager 1801910956的委托481556314的已提交事務

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.persistence.DefaultcustomFrameworkManager-會話1798587502中線程2055564603中的customFramework Manager 1801910956的封閉委托481556314

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.ro.security.remote.RemotecustomFrameworkManager-上下文2031793559中會話2099793559中線程20555793603中cu​​stomFramework Manager 146387751的委托1470155242的承諾事務在上下文1631574962中的事務

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.ro.security.remote.RemotecustomFrameworkManager-在會話209964559中的線程2055564603中的customFramework Manager 146387751的封閉委托1470155242

2016-01-20 12:03:58.877 [btpool0-1]調試customFramework.persistence.TransactionCoordinator-提交事務結束ID 1656368712在線程2055564603中

2016-01-20 12:03:58.877 [btpool0-1]信息性能-hk.com.xx.sys.service.BargeVoyageService方法saveAndSynchronizeForPeakMode-經過的時間為687毫秒。

2016-01-20 12:03:59.190 [btpool0-1]調試HK.com.xx.ro.security.ThreadSecurityContext-stack.size()= 1; 索引= 0

2016-01-20 12:03:59.252 [btpool0-7]信息customFramework.service.http.HttpServiceHandlerFactory-調用服務hk.com.xx.sys.service.BargeVoyageService方法savePeakBargeVoyageInBatch

2016-01-20 12:03:59.252 [btpool0-7]調試customFramework.service.http.HttpServiceHandlerFactory-服務對象=

2016-01-20 12:03:59.252 [btpool0-7]調試customFramework.service.ServiceInterceptorFactory-調用方法savePeakBargeVoyageInBatch具有事務屬性=必需

2016-01-20 12:03:59.252 [btpool0-7]調試customFramework.persistence.TransactionCoordinator-使用事務屬性=必需執行

2016-01-20 12:03:59.252 [btpool0-7]調試customFramework.persistence.TransactionCoordinator-在線程1377751019中開始事務ID 1656368712

2016-01-20 12:03:59.252 [btpool0-7]調試customFramework.persistence.DefaultcustomFrameworkManager-為上下文中會話80928754中的線程1377751019中的customFramework Manager 1801910956創建了委托1334851109,在上下文812419927中

好吧,您確實使用了一個池btpool0-7讀取為池#0的線程#7。 現在,這並不意味着你已經開始6個線程-它只是意味着你的游泳池大小的至少8個線程大,且對於一些隨機原因線#7選擇開始工作的單位。 這可能是由於多種原因,在這里我將不做列舉,足以說明a)它是良性的,b)您不必關心該數字,只是它在記錄期間保持不變。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM