glassfish3 install,dwr3+struts2 deploy error handling
0. set java_home and path in enviroment to jdk1.6, remove jdk1.5 from path1. install glassfish-installer-v2.1.1-b31g-windows-ml.jar2. java -Xmx256m -jar glassfish-installer-v2.1.1-b31g-windows-ml.jar3. cd glassfish4. ant -f setup.xml0. should working in JDK1.61. add sun-web.xml2. remove --asm-1.5.3.jar--asm-attrs-1.5.3.jar--cglib-2.1_3.jar--xercesImpl-2.6.2.jar--xml-apis-1.0.b2.jar3. add bellow jars--asm-all-3.3.jar--backport-util-concurrent-2.2.jar--cglib-2.2.jarreplace login.jspissue:1. glassf
Glassfish2.1.1 installation and deply tips
在eclipse+tomcat6 + Jdk1.6的环境下开发,然后用ant打包发布在glassfish下,build.xmlhttp://zenzuguo.itpub.net/resource/4639/318740. set java_home and path in enviroment to jdk1.6, remove jdk1.5 from path 1. install glassfish-installer-v2.1.1-b31g-windows-ml.jar 2. java -Xmx256m -jar glassfish-installer-v2.1.1-b31g-windows-ml.jar 3. cd glassfish 4. ant -f setup.xml 0. should working in JDK1.6 1. add sun-web.xml 2. remove --asm-1.5.3.jar --asm-attrs-1.5.3.jar --cglib-2.1_3.jar --xercesImpl-2.6.2.jar
sso与spring security整合 预认证场景 PreAuthenticated
1. 当前项目的有个要求,sso与spring security结合使用2. 使用spring security的“预认证场景” PreAuthenticated参考文档http://www.family168.com/tutorial/springsecurity/html/springsecurity.html3. 下载spring security的源代码。参考3.5. Pre-Authentication例子个例子演示了如何从pre-authentication框架绑定bean,从J2EE容器中获得有用的登录信息。 用户名和角色是由容器设置的。 代码在samples/preauth目录下。主要需要重写的类RequestHeaderAuthenticationFilter(sso认证跳入本应用系统后,首先到这个类进行用户权限加载和验证
Accessing Java Constants from JSTL or OGNL
Accessing Java Constants from JSTLEven there could be many variations to the above code, more creative, funnyer or smarter, this is not my recommended solution. Following the Principle No. 6 from our internal guide, the “DRW concept” (don’t reinvent the wheel :) ), the solution is simple: the unstandard tag library from Apache. Here’s how to use it: and later in you code, an expression like: ${users[Constants.NAME]} and later in you code, an expression like:${users[Constants.NAME]}OGNL - Get
连体衣
http://www.6diy.com/read.php?tid=89032http://item.taobao.com/auction/item_detail-0db2-d846c906642a5e0a46412dd7d6eedc23.jhtml?cm_cat=0http://www.6diy.com/read.php?tid=90036[@more@]pgy
bianzhi
http://www.bianz.com/?action-category-catid-3-page-18http://item.taobao.com/auction/item_detail-0db2-d846c906642a5e0a46412dd7d6eedc23.jhtml?cm_cat=0 http://www.bianz.com/?action-viewnews-itemid-2850http://www.bianz.com/batch.download.php?aid=11276http://www.bianz.com/?action-viewnews-itemid-2370http://www.bianz.com/?action-viewnews-itemid-2360-page-2http://www.bianz.com/?action-viewnews-itemid-1240-page-2不管领子袖子,一般按照54321的顺序来收针效果是最好的。即:第一行收5针,第三行收4针,第五行收3
PL/sql中怎样得到insert,update,delete语句执行后,受影响的纪录行数关键字
PL/sql中怎样得到insert,update,delete语句执行后,受影响的纪录行数关键字: pl/sql中怎样得到insert,update,delete语句执行后,受影响的纪录行数 是 sql%rowcount ,舉個例子 begin delete from xxx ; dbms_output.put_line(sql%rowcount); end; 最後顯示出來得,就是處理得行數,當然,這個sql%rowcount參數,你可以用來做判斷,檢察之類得[@more@]
oracle集群数据库的连接字符串及ORA-12505异常
url="jdbc:oracle:thin:@(DESCRIPTION= (LOAD_BALANCE=on) (FAILOVER=on) (ADDRESS=(PROTOCOL=TCP)(HOST=host1) (PORT=1521)) (ADDRESS=(PROTOCOL=TCP)(HOST=host2)(PORT=1521)) (CONNECT_DATA=(SERVICE_NAME=service_name)))"example: String url="jdbc:oracle:thin:@(DESCRIPTION =(ADDRESS = (PROTOCOL = TCP)(HOST = host1)(PORT = 1521))" + "(ADDRESS = (PROTOCOL = TCP)(HOST = host2)(PORT = 1521)) (LOAD_BALANCE = yes)" + "(CONNECT_DATA =(SERVER = DEDICATED)(SERVICE_NAME = epop3)
Hibernate 3 annotation 和hbm.xml混用
<hibernate-configuration> <session-factory> <mapping class="com.test.common.model.City"/> <mapping resource="com/test/model/User.hbm.xml"/> </session-factory></hibernate-configuration>[@more@]
spring security 问题解决方案
2、http节点的配置<http auto-config="true" lowercase-comparisons="false" path-type="ant" access-denied-page="/accessDenied.jsp" access-decision-manager-ref="accessDecisionManager"> <intercept-url pattern="/index.jsp*" access="ROLE_ANONYMOUS"/> <intercept-url pattern="/logout.jsp*" access="ROLE_ANONYMOUS"/> <intercept-url pattern="/accessDenied.jsp*&quo
mysql import and export
一、备份数据库:(命令在DOS的mysqlbin目录下执行) mysqldump --opt school>school.bbb 注释:将数据库school备份到school.bbb文件,school.bbb是一个文本文件,文件名任取,打开看看你会有新发现。 1.导出整个数据库mysqldump -u 用户名 -p 数据库名 > 导出的文件名 mysqldump -u root -p aikersql> aiker.sql2.导出一个表mysqldump -u 用户名 -p 数据库名 表名> 导出的文件名mysqldump -u aiker -p aikersql users> aiker_users.sql3.导出一个数据库结构mysqldump -u root -p -d --add-drop-table aikersql>d:aiker_
appfuse2.0.2在eclipse下的开发和使用
1.准备工作包括JDK 5+、MySQL 5.x和Maven 2.1.0。Maven的环境变量配置:新建变量名为“M2_HOME”,路经为Maven根目录的环境变量,然后在Path中添加“;%M2_HOME%bin”。如果你不想在线下载工程的依赖包,可以到appfuse-dependencies-2.0.2.zip下载,然后解压,并且将maven目录下conf文件夹下的settings.xml的localRepository变量设置为你刚刚解压的路径如C:Docume~1%username%.m2repository2. 创建工程接下来我们习惯性的想要去寻找AppFuse的工程源码,其实这个完全没有必要,Maven全部为我们代劳了。当然前提条件是你的机器必须能够上网。因
oracle死锁的查看及kill方法
经常在oracle的使用过程中碰到这个问题,所以也总结了一点解决方法:)1)查找死锁的进程:sqlplus "/as sysdba"SELECT s.username,l.OBJECT_ID,l.SESSION_ID,s.SERIAL#,l.ORACLE_USERNAME,l.OS_USER_NAME,l.PROCESS FROM V$LOCKED_OBJECT l,V$SESSION S WHERE l.SESSION_ID=S.SID; 2)kill掉这个死锁的进程:alter system kill session ‘sid,serial#’; (其中sid=l.session_id)3)如果还不能解决,select pro.spid from v$session ses,v$process pro where ses.sid=XX and ses.paddr=pro.addr; 其中sid用死锁的sid替换。exi
查看、修改oracle字符集,查看oracle版本
1、查看数据库字符集 数据库服务器字符集select * from nls_database_parameters,其来源于props$,是表示数据库的字符集。 客户端字符集环境select * from nls_instance_parameters,其来源于v$parameter, 表示客户端的字符集的设置,可能是参数文件,环境变量或者是注册表 会话字符集环境 select * from nls_session_parameters,其来源于v$nls_parameters,表示会话自己的设置,可能是会话的环境变量或者是alter session完成,如果会话没有特殊的设置,将与nls_instance_parameters一致。 客户端的字符集要
怎样Oracle把多条记录的相同字段拼成一个字符串
select 别名 from( select row_number()over(order by lv desc) id,name from ( select level lv,replace(sys_connect_by_path(字段,','),',','') 别名from ( select name,row_number()over(order by 字段) id from 查询结果 ) connect by prior id = id-1 ))where id=1;*************测试log:*************[TEST@ORA1] SQL>select * from test2;NAM ID--- ----------aaa 234bbb 786ccc 879[TEST@ORA1] SQL>select name from( 2 select row_number()over(order by lv desc) id,name f
模式窗口页面不更新的问题
方法一:window.showModalDialog("xxxx.aspx"+"?temp="+Math.round(Math.random()*10000),window,"dialogWidth:400px;dialogHeight:400px;help:no;unadorned:no;resizable:yes;status:no");方法二:一次意外发现第二次打开模式窗口时,不能进入if(!Page.Postback),当时情景是这样的:点击Gatagrid的一行后的update按钮,通过url传两个参数到模式窗口,然后模式窗口在Page_Load 里取参数,读取数据库,初始化页面(在if(!Page.Postback)里)。在模式窗口中修改内容,提交。回到父页面,发现Datagrid的内容已
bad mind today
There are four eltps fired today. The hr didn't discuss with any project team just fire them directly due to they didn't play good in the Hua Wei interview yesterday. The hr said their attitued was very bad in interview because they don't want going to ShenZhen. I'm really sad on it. What's training purpose? Is it provide good resource for Our realy project team, right? So why fire them no discuss? I still really can't understand. We spent so many effort but no discuss with us then fire. To fire
Powerdesigner逆向工程从现有数据库生成PDM
在数据建模过程中,我们建立概念数据模型,通过正向工程生成物理数据模型,生成数据库建库脚本,最后将物理数据模型生成关系数据库,现在反过来,通过逆向工程将关系数据库,生成物理数据模型。 优点: 在丢失数据模型或者数据库模型同现有的数据库不一致,可以通过该方法生成使用中数据库的模型 缺点: 还原回的模型中,可能会没有中文注释,没有表外键对应关系(字段还有,索引关系没了) 前提: 1,确认要生成模型的数据库是最新的,并且可以使用 2,安装Powerdesigner软件 具体操作步骤: 一,建立ODBC数据源 1, 打开系统ODBC数据源,位
Power Designer 12.5下载、破解与汉化
Power Designer 12.5下载、破解与汉化 关键字: power designer 下载地址: http://download.sybase.com/eval/PowerDesigner/powerdesigner125_eval.exe 破解补丁: http://media-001.yo2cdn.com/wp-content/uploads/235/23551/2008/05/e7a0b4e8a7a3.rar 破解方法: 下载 PowerDesigner12.5 后有一个 license.lic 和 pdflm12.dll 两个文件,license.lic 是用于破解序号的,pdflm12.dll 是用于替换原来安装后的文件,破解首先用 pdflm12.dll 替换安装要目录的 pdflm12.dll 文件,然后在PD的菜单中找到 Tools ==>>
全面认识UML类图元素
http://uml.chinaitlab.com/UML/17681.htmlhttp://www.uml.org.cn/oobject/200804101.asp[@more@]