JBoss AS7:Timeout deploying JBoss applications


問題現象:jboss在開機部署時,由於軟件包的問題,導致部署時間超過jboss默認時間(60秒),jboss重新部署,打斷上一次部署,如此反復,導致網站啟動失敗
 
Code: 
KB-E1037
Issue: 

There is an error message in log file while deploying JBoss application

ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS015052: Did not receive a response to the deployment operation within the allowed timeout period [60 seconds]. Check the server configuration file and the server logs to find more about the status of the deployment.

Resolution: 

In the local Git repository of the application locate file ".openshift/config/stanalone.xml" and open it in an editor.

Look up this section 

<subsystem xmlns="urn:jboss:domain:deployment-scanner:1.0">
     <deployment-scanner scan-interval="5000" relative-to="jboss.server.base.dir" path="deployments"  />
</subsystem>

and add "deployment-timeout" attribute to the "deployment-scanner" tag with big enough number. E.g.

<subsystem xmlns="urn:jboss:domain:deployment-scanner:1.0">
     <deployment-scanner scan-interval="5000" relative-to="jboss.server.base.dir" path="deployments" deployment-timeout="1200" />
</subsystem>
The attributes are
Name Type Description
name STRING The name of the scanner. default is used if not specified
path STRING The actual filesystem path to be scanned. Treated as an absolute path, unless the 'relative-to' attribute is specified, in which case the value is treated as relative to that path.
relative-to STRING Reference to a filesystem path defined in the "paths" section of the server configuration, or one of the system properties specified on startup. In the example above jboss.server.base.dir resolves to {{$JBOSS_HOME/standalone
scan-enabled BOOLEAN If true scanning is enabled
scan-interval INT Periodic interval, in milliseconds, at which the repository should be scanned for changes. A value of less than 1 indicates the repository should only be scanned at initial startup.
auto-deploy-zipped BOOLEAN Controls whether zipped deployment content should be automatically deployed by the scanner without requiring the user to add a .dodeploy marker file.
auto-deploy-exploded BOOLEAN Controls whether zipped deployment content should be automatically deployed by the scanner without requiring the user to add a .dodeploy marker file. Setting this to 'true' is not recommended for anything but basic development scenarios, as there is no way to ensure that deployment will not occur in the middle of changes to the content.
deployment-timeout LONG imeout, in seconds, a deployment is allows to execute before being canceled. The default is 60 seconds.

參考:

https://openshift.redhat.com/community/kb/kb-e1037-timeout-deploying-jboss-applications

https://docs.jboss.org/author/display/AS7/Deployment+Scanner+configuration


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM