resin4的初次配置与使用
之前用的resin3,结果发布新项目老师文件冲突,我也找不到是哪里有问题,于是尝试使用resin4.
首先从官网下载最新resin4。
然后放到opt下,tar -zvxf 解压。
然后修改conf/resin.xml。
另外,修改resin默认端口8080为其他:8070:
在conf/resin.property中找到8080并修改:
# Set HTTP and HTTPS ports.
# Use overrides for individual server control, for example: app-0.http : 8081
app.http : 8070
最终修改如下: 1 <!-- 2 - Resin 4.0 configuration file.
-->
<resin xmlns="http://caucho.com/ns/resin"
xmlns:resin="urn:java:com.caucho.resin"> <!-- property-based Resin configuration -->
<resin:properties path="${__DIR__}/resin.properties" optional="true"/> <resin:if test="${properties_import_url}">
<resin:properties path="${properties_import_url}"
optional="true" recover="true"/>
</resin:if> <!-- Logging configuration for the JDK logging API -->
<log-handler name="" level="all" path="stdout:"
timestamp="[%y-%m-%d %H:%M:%S.%s]"
format=" {${thread}} ${log.message}"/> <!--
- Alternative pseudo-TTCC log format
-
- <log-handler name="" level="all" path="stdout:"
- timestamp="%y-%m-%d %H:%M:%S.%s"
- format=" [${thread}] ${log.level} ${log.shortName} - ${log.message}"/>
--> <!--
- level='info' for production
- 'fine' or 'finer' for development and troubleshooting
-->
<logger name="" level="${log_level?:'info'}"/> <logger name="com.caucho.java" level="config"/>
<logger name="com.caucho.loader" level="config"/> <!--
- Default configuration applied to all clusters, including
- HTTP, HTTPS, and /resin-admin configuration.
-->
<resin:import path="${__DIR__}/cluster-default.xml"/> <!--
- Remote management requires at least one enabled admin user.
-->
<resin:AdminAuthenticator>
<user name="${admin_user}" password="${admin_password}"/> <resin:import path="${__DIR__}/admin-users.xml" optional="true"/>
</resin:AdminAuthenticator> <!--
- For clustered systems, create a password in as cluster_system_key
-->
<cluster-system-key>${cluster_system_key}</cluster-system-key> <!--
- For production sites, change dependency-check-interval to something
- like 600s, so it only checks for updates every 10 minutes.
-->
<dependency-check-interval>${dependency_check_interval?:'2s'}</dependency-check-interval> <!-- For resin.properties dynamic cluster joining -->
<home-cluster>${home_cluster}</home-cluster>
<home-server>${home_server}</home-server>
<elastic-server>${elastic_server}</elastic-server>
<elastic-dns>${elastic_dns}</elastic-dns> <!--
- Configures the main application cluster. Load-balancing configurations
- will also have a web cluster.
-->
<cluster id="app">
<!-- define the servers in the cluster 这里配置端口 -->
<server-multi id-prefix="app-" address-list="127.0.0.1" port="6801">
<watchdog-port>6601</watchdog-port>
<http address="*" port="9097"/>
</server-multi> <host-default>
<!-- creates the webapps directory for .war expansion 这里我把webapps修改到webapp,因为我只要发布一个项目,当然理解可能有问题-->
<web-app-deploy path="webapp"
expand-preserve-fileset="WEB-INF/work/**"
multiversion-routing="${webapp_multiversion_routing}"
path-suffix="${elastic_webapp?resin.id:''}"/>
</host-default> <!-- auto virtual host deployment in hosts/foo.example.com/webapps -->
<host-deploy path="hosts">
<host-default>
<resin:import path="host.xml" optional="true"/>
</host-default>
</host-deploy>
<!-- 这里我修改/为我的项目路径,即直接使用项目路由分配,设置项目位置,设置日志按日期输出。-->
<host id="" root-directory=".">
<web-app id="/" root-directory="webapp/prnewsOrder">
<form-parameter-max>100</form-parameter-max>
<stderr-log path='log/stderr.log' timestamp='[%Y-%m-%d %H:%M:%S] ' rollover-period='1D'/>
<stdout-log path='log/stdout.log' timestamp='[%Y-%m-%d %H:%M:%S] ' rollover-period='1D'/>
</web-app>
</host> </cluster> <cluster id="proxycache">
<!-- define the servers in the cluster -->
<server-multi id-prefix="proxycache-" address-list="${proxycache_servers}" port="6830">
<http address="*" port="9078"/>
</server-multi> <host id="" root-directory="proxycache">
<web-app id="">
<resin:HttpProxy regexp=".*">
<!-- backend HTTP servers to proxy to -->
<addresses>${backend_servers}</addresses>
</resin:HttpProxy>
</web-app>
</host>
</cluster> </resin>
resin4的初次配置与使用的更多相关文章
- Sublime Text3安装以及初次配置
Sublime Text3安装以及初次配置 工具:官网下载:Sublime Text3 安装:直接运行安装.http://write.blog.csdn.net/postedit 激活:参考文/晚晴幽 ...
- git使用教程(初次配置+错误提示)
初次使用配置目录:https://blog.csdn.net/Esc_Tab_End/article/details/84144063 error: RPC failed; curl 56 OpenS ...
- Linux Resin4.0 安装配置
Resin,是一个非常流行的application server,对servlet和JSP提供了良好的支持,性能优良,resin自身采用Java语言开发.Resin Pro版本支持缓存和负载均衡,收费 ...
- 转载 | Sublime Text3 安装以及初次配置
本文引自:http://blog.csdn.net/u011272513/article/details/52088800 工具:官网下载:Sublime Text3 安装:直接运行安装.http:/ ...
- 初次配置eclipse, jdk, tomcat, maven, mysql, alt+/
eclipse 官网下载eclipse-inst-win64.exe, 选择安装java ee. jdk 官网下载jdk-8u102-windows-x64.exe, next到底. 接下来配置环境变 ...
- 初次配置git与github出现push不了的问题
ssh: connect to host gmail.com port 22: No route to host fatal: Could not read from remote repositor ...
- eclipse3.7+resin4.0集成配置小结
1.插件不要用improve公司的了,那个太老了.直接用resin官方的,用eclipse的help->install new software功能,地址用:http://www.caucho. ...
- mac 初次配置apache,及mac下安装mysql
先打开apache,在浏览器上输入 localhost 回车后会如果屏幕上显示:It works! 如下图: 这说明你的apache已开启 mac 下apache配置(mac自带apache ...
- nginx反向代理负载均衡初次配置
反向代理,我个人理解是通过一台反向代理服务器,把客户端的把有请求按照一定的规则分发给后台的服务器.nginx作反向代理服务器的虚拟机配置如下: upstream itest { #正常情况下应该作如下 ...
随机推荐
- c语言编译器(linux平台下安装c语言环境)一
gcc : 语言的默认编译器 (ubuntu下输入gcc,可根据终端输出查看是否安装了gcc) g++ : c++的默认编译器 (ubuntu下输入g++,可根据终端输出查看是否安装了g+ ...
- JSON数据查询方法
在进行前端项目开发的时候时长会遇到JSON的数据查找问题,如何方便快速查找?这里推荐一个linqjs组件,项目主页参见http://linqjs.codeplex.com/ 查询对象 var json ...
- WindowsPhone技术和XNA技术
介于公司目前还没有涉及WP(WindowsPhone)项目的开发,而我本身是学习WP开发的,因此在这里稍微入门的介绍一点WP的知识. 一.简介 Windows Phone具有桌面定制.图标拖拽.滑动控 ...
- TCP字节流和UDP数据报区别
两者的区别在于TCP接收的是一堆数据,而每次取多少由主机决定;而UDP发的是数据报,客户发送多少就接收多少. 拥有这些区别的原因是由于TCP和UDP的特性不同而决定的.TCP是面向连接的,也就是说,在 ...
- 5天玩转C#并行和多线程编程 —— 第二天 并行集合和PLinq
5天玩转C#并行和多线程编程系列文章目录 5天玩转C#并行和多线程编程 —— 第一天 认识Parallel 5天玩转C#并行和多线程编程 —— 第二天 并行集合和PLinq 5天玩转C#并行和多线程编 ...
- python sorted排序
python sorted排序 Python不仅提供了list.sort()方法来实现列表的排序,而且提供了内建sorted()函数来实现对复杂列表的排序以及按照字典的key和value进行排序. s ...
- 学习Scala第一篇-从hello World开始
最近开始系统性的学习scala.其实之前使用过scala的,比如我在用Gatling这款性能测试工具的时候就接触到了scala了.Gatling本身就是用Scala写的,而且Gatling的性能测试配 ...
- iOS instruments trace文件解析方案
前言 已很少写文章,不过这次感觉有必要写一下.因为: 1. 这个方案通过debug逆向得来,很有参考意义. 2. iOS这方面资料非常少,做这块时,无论国内外,翻遍了google,baidu都没太多合 ...
- Java中反射的理解
反射 一.什么是反射 Java 反射是Java语言的一个很重要的特征,它使得Java具体了"动态性". 反射用在 Java 身上指的是我们可以于运行时加载.探知.使用编译期间完全未 ...
- 第九回 Microsoft.Practices.Unity.Interception实现基于数据集的缓存(针对六,七,八讲的具体概念和配置的解说)
返回目录 概念 Microsoft.Practices.Unity.Interception是一个拦截器,它隶属于Microsoft.Practices.Unity组成之中,主要完成AOP的功能,而实 ...