tdp100的博客
tdp100 · 共 10 篇文章
JS 变量应先声明,再使用
1、未先声明,就使用变量会抛出异常 if(aaaa === undefined) {} //异常: aaaa is not undefined 2、声明可以在上下文任意位置,但取值是在具体赋值时生效 if(aabc1 === undefined) { console.log("aabc if = ", aabc1) } else { console.log("aab else = ",aabc1); } var aabc1 = 1; //打印出aabc if = undefined
2013-05-28 11:34 · 前端设计 · 评论(0)
Rest Router路径
Router全路径由如下部分构成 1、Restlet-Map中的地址,如下是/rest-map/* 2、Router添加的attach地址,比如是/persion/{persionId} 由全路径应该是: http://host:port/rest-map/persion/1;
2013-05-21 20:01 · servlet · 评论(0)
新架构要解决的问题
面临的问题: 1、多应用之间的身份验证:SSO + filter 解决方案 2、cookie与域的关系 3、安全协议SSL的支持 4、Restlet 之间访问:apache开源的httpclient包(存在的问题:会话管理,ssl等问题,需要验证的问题:会不会走filter) Restlet 需要明白的几个类: 1、Representation 2、ServerResource 3、Variant 4、Router 示例: public class SSOApplication extends Application { public SSOApplication() { super(); …
2013-05-11 01:12 · servlet · 评论(0)
DSL
http://2byte.us/tag/domain-specific-language/ DSL与通用语言相区别,是为特定目的而生的语言,它并不是什么新东西,历史几乎和计算机的历史一样长。 DSL的应用广泛而常见,比如CSS,比如Wiki。DSL通过分析特定问题域提炼动态模型,从而标准化问题处理流程。
2013-04-22 22:37 · 评论(0)
linux 性能分析全局
linux 全局分析工具整理
2013-03-23 15:45 · http://www.slideshare.net/brendangregg/linux-performance-analysis-and-tools · 评论(0)
浏览器内存泄漏专题
http://msdn.microsoft.com/en-us/library/bb250448(v=vs.85).aspx http://www.cnblogs.com/qq78292959/archive/2011/12/14/2287696.html http://com.hemiola.com/2009/11/23/memory-leaks-in-ie8/
2013-03-08 21:49 · 评论(0)
获取浏览器模式和文本模式
从用户代理中获取IE的浏览器模式: window.navigator.userAgent 从domcument.documentMode中获取文本模式 判断方法: function isCompa(version) { return document.documentMode === version; } //注:如果要用这个函数来检测浏览器模式和文本模式是否一致,那么不能设置X-UA-Compatible
2013-03-04 12:09 · 前端设计 · 评论(0)
内存泄漏
./jmap -dump:format=b,file=heap.bin 压缩heap.bin并下载到windows。采用MAT工具分析。 http://www.eclipse.org/downloads/download.php?file=/mat/1.2.1/rcp/MemoryAnalyzer-1.2.1.20121105-win32.win32.x86.zip&mirror_id=1093
2013-02-20 19:08 · java · 评论(0)
Servlet 过滤
地址:http://www.ibm.com/developerworks/cn/java/j-tomcat/ 需要理解filter的原理,它是对request进行过滤 1、过滤器的处理函数doFilter 2、过滤器链FilterChain 场景:通过过滤器在源头对资源的访问进行过滤
2012-07-17 21:45 · servlet · 评论(0)
Rest 应该掌握的协议
Rest 相关论文 http://www.infoq.com/cn/articles/rest-introduction/ http://www.ics.uci.edu/~fielding/pubs/dissertation/fielding_dissertation.pdf Rest 需要掌握的协议 http和uri
2012-07-17 21:07 · 评论(0)