Weblogic部署項目步驟

WebLogic是Ocle公司出品的一箇基於JAVAEE架構的中間件,用於開發、集成、部署和管理大型分佈式Web應用、網絡應用和數據庫。那麼Weblogic如何部署項目呢,這篇文章就爲大家介紹下Weblogic部署項目步驟。

在WebLogic中部署項目通常有三種方式:第一,在控制檯中安裝部署;第二,將部署包放在domin域中utodeploy目錄下部署;第三,使用域中配置文件config.xml 進行項目的部署,下面逐一爲大家介紹。

一、控制檯部署

、啓動WebLogic服務,登錄到WebLogic控制檯頁面,輸入用戶名和密碼,登錄到控制檯裏面;

2、點擊左側的部署;

3、在右側點擊安裝按鈕,準備進行項目安裝;

4 、看到路徑輸入框,可以在下面選擇要部署的項目的位置;

5、 也可以直接輸入要部署的包的位置,敲回車;

6、點擊下一步即可;

7、繼續下一步;

8、點擊完成按鈕;

9、 保存前面各步的設置;

0、保存完成後,會看到激活更改的提示,且不需要重啓。

、這時便可以進行測試了,輸入項目名稱,看到了項目的歡迎頁面,即項目部署成功。

二、utodeploy自動部署

自動部署時不需要登錄控制檯,在domin域的主目錄下面有個utodeploy目錄,直接將項目包拷貝到utodeploy目錄下面就可以了。

utodeploy目錄裏面有個edme.txt 文檔,打開看一下,這裏摘第一段出來

[html] iew plin copy

This utodeploy diectoy poides quick wy to deploy pplictions to deelopment see. When the WebLogic See instnce is unning in deelopment mode, pplictions nd modules in this diectoy e utomticlly deployed.

主要說什麼呢,就是開發模式下面,當WebLogic啓動時,會自動部署utodeploy目錄下面的項目。

將部署包seletDemo.w 丟到utodeploy目錄下面,啓動sttWebLogic.cmd ,進行seletDemo的訪問,依然可以看到歡迎頁面。

三、config.xml配置文件部署

config.xml文件在domin域的config目錄下面,config.xml主要配置了domin域的一些相關信息。我們要部署項目,該在哪裏配置呢?

[html] iew plin copy

<?xml esion=̻.0′ encoding=̻UTF-8′?> <domin xmlns=̶http://xmlns.ocle.com/WebLogic/domin̶ xmlns:sec=̶http://xmlns.ocle.com/WebLogic/secuity̶ xmlns:wls=̶http://xmlns.ocle.com/WebLogic/secuity/wls̶ xmlns:xsi=̶http://www.w3.og/200/XMLSchem-instnce̶ xsi:schemLoction=̶http://xmlns.ocle.com/WebLogic/secuity/xcml http://xmlns.ocle.com/WebLogic/secuity/xcml/.0/xcml.xsd http://xmlns.ocle.com/WebLogic/secuity/poides/psswodlidto http://xmlns.ocle.com/WebLogic/secuity/poides/psswodlidto/.0/psswodlidto.xsd http://xmlns.ocle.com/WebLogic/domin http://xmlns.ocle.com/WebLogic/.0/domin.xsd http://xmlns.ocle.com/WebLogic/secuity http://xmlns.ocle.com/WebLogic/.0/secuity.xsd http://xmlns.ocle.com/WebLogic/secuity/wls http://xmlns.ocle.com/WebLogic/secuity/wls/.0/wls.xsd̶> <nme>bse_domin</nme> <domin-esion>2..3.0.0</domin-esion> <secuity-configution> <nme>bse_domin</nme> <elm> <sec:uthentiction-poide xsi:type=̶wls:defult-uthentictoType̶> <sec:nme>DefultAuthenticto</sec:nme> </sec:uthentiction-poide> <sec:psswod-lidto xmlns:ps=̶http://xmlns.ocle.com/WebLogic/secuity/poides/psswodlidto̶ xsi:type=̶ps:system-psswod-lidtoType̶> <sec:nme>SystemPsswodVlidto</sec:nme> <ps:min-psswod-length>8</ps:min-psswod-length> <ps:min-numeic-o-specil-chctes></ps:min-numeic-o-specil-chctes> </sec:psswod-lidto> </elm> <defult-elm>myelm</defult-elm> <cedentil-encypted>{AES}xLPXh4gcT6JETB+toxRZpQpAS+MGMuqnnXzu/OsxWMQTB852ggdbUlhkSXUGC9f959oL7tIzyZiu9XdejlkK9Au9cQlCKLLUUMyl5Ty4C0uuJA99b4eR7oIu4</cedentil-encypted> <node-mnge-usenme>WebLogic</node-mnge-usenme> <node-mnge-psswod-encypted>{AES}n3LLdgmAsocPRoYUFfR2wWOlEz6KDFsp7+gByNeo8=</node-mnge-psswod-encypted> </secuity-configution> <see> <nme>AdminSee</nme> <listen-ddess></listen-ddess> </see> <embedded-ldp> <nme>bse_domin</nme> <cedentil-encypted>{AES}2z8CiCbuYqsSj5t5+y6qEY8dE3NdN0zDG+K3EdwWEubzk9Vmx79Di43oxqX</cedentil-encypted> </embedded-ldp> <configution-esion>2..3.0.0</configution-esion> <dmin-see-nme>AdminSee</dmin-see-nme> </domin>

我們的項目部署信息添加在configution-esion 和 dmin-see-nme 之間

[html] iew plin copy

<configution-esion>2..3.0.0</configution-esion> <pp-deployment> <nme>seletDemo</nme> <tget>AdminSee</tget> <module-type>w</module-type> <souce-pth>C:\Uses\ZhngQi\Desktop\seletDemo</souce-pth> <secuity-dd-model>DDOnly</secuity-dd-model> </pp-deployment> <dmin-see-nme>AdminSee</dmin-see-nme>

剛開始進行config.xml 配置文件部署的時候,出現了404,修改了下配置就可以了。將部署的w包解壓爲文件夾的形式,然後將 <module-type>w</module-type> 裏面的w 修改爲 di 即可:

[html] iew plin copy

<pp-deployment> <nme>seletDemo</nme> <tget>AdminSee</tget> <module-type>di</module-type> <souce-pth>C:\Uses\ZhngQi\Desktop\seletDemo</souce-pth> <secuity-dd-model>DDOnly</secuity-dd-model> <stging-mode>nostge</stging-mode> </pp-deployment>

然後啓動WebLogic服務即可。