
裝完 JBoss EAP 6.x ,並利用 Eclipse 開發程式除錯 Debug 時,發現一般使用 System.out.println() & logger.info() 都沒有出現在 Console 中,查了好久才找到正解如下:
1. 在 Eclipse 開發環境:
在 Servers 視窗下的 JBoss EAP Server 點兩下,選擇 Open Launch configuration ,然後在 VM arguments 裡最後加入
-Dorg.jboss.as.logging.per-deployment=false 即可,如下圖:
MIS 發表在 痞客邦 留言(1) 人氣(2,511)
JBoss EAP 6.x 上要建立 MySQL 的 Java Naming and Directory Interface (JNDI) 作法分三個步驟如下:
Step 01: 在 $JBOSS_HOME 目錄 modules 下建立 mysql 相關資訊
$ mkdir -p $JBOSS_HOME/modules/com/mysql/main/
$ touch $JBOSS_HOME/modules/com/mysql/main/module.xml
|
MIS 發表在 痞客邦 留言(0) 人氣(1,456)

Struts 2 仍有多語言的支援,相關的文件可以查看 http://struts.apache.org/release/2.2.x/docs/localization.html ,搜尋的順序是:
ActionClass.properties
Interface.properties (every interface and sub-interface)
BaseClass.properties (all the way to Object.properties)
ModelDriven's model (if implements ModelDriven), for the model object repeat from 1
package.properties (of the directory where class is located and every parent directory all the way to the root directory)
search up the i18n message key hierarchy itself
global resource properties
MIS 發表在 痞客邦 留言(0) 人氣(835)

在 JBoss EAP6.x Standalone Mode Cluster Configuration 驗證了 Standalone Mode 的 Cluster 機制,在 Domain Mode 的設定也很簡單,還記得在 JBoss EAP6 Domain Mode Setup 中 host.xml 對每台 server 作了
port-offset ,而這就是 workers.properties 檔案裡的 node。
MIS 發表在 痞客邦 留言(0) 人氣(118)
JBoss EAP 6.x (Enterprise Application Platform) 提供 Cluster 的機制,但需要 apache 的 mod-jk.conf 配合,現在以 Standalone Mode 作為 HA 來測試看看。
Step 01: apache 的設定
APACHE_HOME/conf/httpd.conf
MIS 發表在 痞客邦 留言(0) 人氣(846)

JBoss EAP(Enterprise Application Platform) 提供 Domain Mode ,可以讓應用系統佈署簡單化,也可以讓應用系統不會因一台主機掛了,而導致使用者就無法登入,至於 Domain Mode 的概念在 JBoss EAP 與 JBoss AS/Community edition 及 WildFly 的差異 有提了一下,現在我們來實作,整個架構如下圖。
MIS 發表在 痞客邦 留言(1) 人氣(1,896)

JBoss 是一套應用程式伺服器,屬於開源的企業級Java中介軟體軟體,用於實作基於SOA架構的web應用和服務。目前有分:付費有支援的版本:JBoss EAP(Enterprise Application Platform) 及 Red Hat 支援社群的 Community edition 免費版本:JBoss AS;與一般社群的 WildFly 版本,軟體下載位置 http://wildfly.org/downloads/ 。
MIS 發表在 痞客邦 留言(0) 人氣(4,809)

主要目的:如何在 eclipse 利用 maven 建立 struts2 並在 eclipse internal runtime Server: Tomcat 作開發環境測試
平台:
eclipse:Version: Kepler Service Release 2
Build id: 20140224-0627
MIS 發表在 痞客邦 留言(0) 人氣(1,598)
概念:
Apache Rewirte 主要的功能就是實現URL的跳轉,它的正則運算式是基於Perl 語言。可基於伺服器級的(HTTPd.conf)和目錄級的 (.htaccess)兩種方式。如果要想用到rewrite模組,必須先安裝或載入rewrite模組。
Apache mod_rewrite 規則重寫的標誌一覽
1) R[=code](force redirect) 強制外部重定向:強制在替代字串加上HTTP://thishost[:thisport]/首碼重定向到外部的URL.如果code不指定,將用缺省的302 HTTP狀態碼。
2) F(force URL to be forbidden)禁用URL,返回403HTTP狀態碼。
3) G(force URL to be gone) 強制URL為GONE,返回410HTTP狀態碼。
4) P(force proxy) 強制使用代理轉發。
5) L(last rule) 表明當前規則是最後一條規則,停止分析以後規則的重寫。
6) N(next round) 重新從第一條規則開始運行重寫過程。
7) C(chained with next rule) 與下一條規則關聯:如果規則匹配則正常處理,該標誌無效,如果不匹配,那麼下面所有關聯的規則都跳過。
8) T=MIME-type(force MIME type) 強制MIME類型
9) NS (used only if no internal sub-request) 只用于不是內部子請求
10) NC(no case) 不區分大小寫
11) QSA(query string append) 追加請求字串
12) NE(no URI escaping of output) 不在輸出轉義特殊字元
MIS 發表在 痞客邦 留言(0) 人氣(7,884)