隨筆:15 文章:2 評論:14 引用:0
          BlogJava 首頁 發新隨筆
          發新文章 聯系 聚合管理

          roller4.0 安裝小記
          roller4.0 安裝總體感覺很方便。有安裝向導頁面,自動建立數據庫表。
          但也有一點小問題,install-guide 上沒有寫得太詳細,也可能我看得不夠仔細,呵呵
          。一個是沒有說配置連接池配置文件,另一個是中文有點問題。

          總結如下:
          安裝環境


          JDK 1.5.05
          tomcat-5.5.17
          mysql-5.0.27
          apache-roller-4.0

          安裝使用的是 msyql 數據庫,現建立數據庫和用戶

          mysql> create database rollerdb default charset utf8  collate utf8_general_ci;  
           
          文檔install-guide 上 create database rollerdb ; 建立的數據庫默認是 lat1 字符  
          編碼,中文會有問題所以使用 utf8 編碼  
           
          給用戶授權  
           
          mysql> grant all on rollerdb.* to scott@'%' identified by 'tiger';  
          mysql> grant all on rollerdb.* to scott@localhost identified by 'tiger'; 

          mysql> create database rollerdb default charset utf8  collate utf8_general_ci;

          文檔install-guide 上 create database rollerdb ; 建立的數據庫默認是 lat1 字符
          編碼,中文會有問題所以使用 utf8 編碼

          給用戶授權

          mysql> grant all on rollerdb.* to scott@'%' identified by 'tiger';
          mysql> grant all on rollerdb.* to scott@localhost identified by 'tiger';

           

          為了使用java mail 發送郵件,tomcat 的 common/lib 文件夾中放入 activation.jar,
          javamail.jar


          困了,先睡了回頭再寫...
          各位新年快樂!

          在 conf/server.xml 文件中的connector加入 URIEncoding=”UTF-8”, 為了I18N
          例如:
          <Connector port="8080"
          maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
          enableLookups="false" redirectPort="8443" debug="0"
          acceptCount="100" connectionTimeout="20000"
          disableUploadTimeout="true"
          URIEncoding="UTF-8" />

          將roller 發行包的 roller 文件夾copy 到tomcat 的 webapps 下。

          關于JDBC 驅動 install-guiade 上說
          For MySQL 4.1.x 使用 the J/Connector 3.0.X JDBC
          For MySQL 5.X use the J/Connector 3.1.X JDBC drivers

          拷貝到 tomcat/common/lib 下

          建立一個 roller-custom.properties 文件內容如下:
          installation.type=auto
          database.configurationType=jdbc
          database.jdbc.driverClass=com.mysql.jdbc.Driver
          database.jdbc.connectionURL=jdbc:mysql://localhost:3306/rollerdb?autoReconnect=true&useUnicode=true&characterEncoding=utf-8&mysqlEncoding=utf8
          database.jdbc.username=scott
          database.jdbc.password=tiger
          mail.configurationType=properties
          mail.hostname=smtp-server.example.com
          mail.username=scott
          mail.password=tiger

          roller-custom.properties 放到 tomcat/common/classes 下

          (這里有一個問題我不大明白,在roller-custom.properties
          文件里指定了數據庫連接,但是還需要制定一個數據庫的連接池
          給roller 才能正常工作,而且注意 database.jdbc.connectionURL=jdbc:mysql://localhost:3306/
          rollerdb?autoReconnect=true&useUnicode
          =true&characterEncoding=utf-8&mysqlEncoding=utf8
          屬性,如果按install-guide 的 database.jdbc.connectionURL=jdbc:mysql://localhost:3306/
          rollerdb 中文是會亂碼的)

          在\tomcat-5.5.17\conf\Catalina\localhost放入一個 roller.xml
          文件,內容如下:
          Java代碼
          <Context path="/roller" 
          docBase="roller" debug="0">  
          <Resource name="jdbc/rollerdb" auth="Container" 
          type="javax.sql.DataSource" 
          driverClassName="com.mysql.jdbc.Driver" 
          url="jdbc:mysql://localhost:3306/rollerdb?autoReconnect=true&useUnicode=true&characterEncoding=utf-8&mysqlEncoding=utf8" 
          username="root" 
          password="mysql" 
          maxActive="20" 
          maxIdle="3" 
          removeAbandoned="true" 
          maxWait="3000" />  
          <!-- If you want e-mail features, un-comment the section below -->  
          <!--  
          <Resource name="mail/Session" auth="Container" 
          type="javax.mail.Session" 
          mail.smtp.host="mailhost.example.com" />  
          -->  
          </Context> 

          <Context path="/roller"
          docBase="roller" debug="0">
          <Resource name="jdbc/rollerdb" auth="Container"
          type="javax.sql.DataSource"
          driverClassName="com.mysql.jdbc.Driver"
          url="jdbc:mysql://localhost:3306/rollerdb?autoReconnect=true&useUnicode=true&characterEncoding=utf-8&mysqlEncoding=utf8"
          username="root"
          password="mysql"
          maxActive="20"
          maxIdle="3"
          removeAbandoned="true"
          maxWait="3000" />
          <!-- If you want e-mail features, un-comment the section below -->
          <!--
          <Resource name="mail/Session" auth="Container"
          type="javax.mail.Session"
          mail.smtp.host="mailhost.example.com" />
          -->
          </Context>


          其實就是指定了一個 jdbc/rollerdb 的 jndi datasource,
          如果沒有的話,會發現每次見了用戶,登陸時就登陸不了。提示
          密碼或用戶錯,但是用戶確實在數據庫表中了,我覺得
          roller-custom.properties
          和roller.xml 中的數據源配置都用到了,有點奇怪。
          回頭看看源碼可能就知道是怎么回事了。

          啟動tomcat ,就可以正常安裝roller 了

          posted @ 2008-02-03 15:39 小Q 閱讀(1289) | 評論 (0)編輯 收藏
           
               摘要: Spket Eclipse Plugin & IDE
          The Spket IDE has by far the most superior code assist for Ext 2.0. It uses the Ext .jsb project file and embedded script doc to build code assist that includes options inherited from base classes and full documentation.

          It doesn’t have much for editing other types of files though (e.g. CSS), so my preference is to install it as an Eclipse plugin in Aptana. To install the plugin in Aptana:

            閱讀全文
          posted @ 2008-02-02 16:38 小Q 閱讀(14652) | 評論 (2)編輯 收藏
           
               摘要: 沒有注冊的版本,用的不爽。
          居然沒有混淆,反編譯了下,修改里面的一個Class文件,就ok了。
          com.spket.ui_1.6.6.jar --》\com\spket\ui\internal\License.class  閱讀全文
          posted @ 2008-02-02 16:21 小Q 閱讀(5104) | 評論 (4)編輯 收藏
           
               摘要: 最近在研究Roller源代碼.發現Roller文檔和源代碼中有一些容易讓人混淆和模糊的概念(至少對我來說),在這里記下來.


          Roller: 博客服務器, 能夠同時支持多個用戶(博客)的服務器軟件,同時可以支持組網志(Group Weblog,意思是多個用戶共同編輯的網志)

            閱讀全文
          posted @ 2008-01-21 22:49 小Q 閱讀(2369) | 評論 (0)編輯 收藏
           
               摘要:       最近研究Roller,一直手癢,想搞個Java 的博客玩玩,網上查了下,Roller像是比較出名,所以就選擇他了。      可惜網上中文的文檔不多,官方e文的文檔也不多,連API也沒有提供,所以,我覺得,先把他的三個文檔翻譯下,一來方便我學習,二來,給同時給感興趣的又不敢冒e文同志的一些方便(聲明下,我...  閱讀全文
          posted @ 2008-01-20 22:46 小Q 閱讀(4028) | 評論 (0)編輯 收藏
           
               摘要:     簡單講述下發送和接受郵件的協議: SMTP     簡單郵件傳輸協議(Simple Mail Transfer Protocol,SMTP)由 RFC 821 定義。它定義了發送電子郵件的機制。在 JavaMail API 環境中,您基于 JavaMail 的程序將和您的公司或因特網服務供應商的(Internet Serv...  閱讀全文
          posted @ 2007-12-31 21:19 小Q 閱讀(2853) | 評論 (1)編輯 收藏
           

              本沒有什么追求,吃飽了,穿暖了。發現寫寫,更健康哦。
              扯哪里去了,有什么新的想法就大家看看,人多力量大的。

          posted @ 2007-12-31 18:15 小Q 閱讀(177) | 評論 (0)編輯 收藏
          僅列出標題
          共2頁: 上一頁 1 2 
          CALENDER
          <2025年6月>
          25262728293031
          1234567
          891011121314
          15161718192021
          22232425262728
          293012345

          常用鏈接

          留言簿(4)

          隨筆分類

          隨筆檔案

          文章分類

          新聞分類

          新聞檔案

          搜索

          •  

          最新評論

          閱讀排行榜

          評論排行榜


          Powered By: 博客園
          模板提供滬江博客

          主站蜘蛛池模板: 宁德市| 绥德县| 台南县| 体育| 冀州市| 达拉特旗| 丰台区| 宁安市| 灵山县| 揭东县| 台山市| 天全县| 古丈县| 泽普县| 西充县| 安远县| 扎赉特旗| 田阳县| 隆林| 呼伦贝尔市| 清河县| 商水县| 邻水| 大城县| 手机| 绥芬河市| 寻乌县| 庄河市| 来宾市| 秭归县| 焦作市| 海原县| 辽源市| 砀山县| 北票市| 西盟| 阿鲁科尔沁旗| 通江县| 治多县| 富裕县| 海丰县|