zoukankan      html  css  js  c++  java
  • 3月工作问题总结

    1. 上线流程和方法比较赞。 review board提交申请,有同事review并ship it,上线代码打tag,然后用german上线,如果出问题,回滚到上一版本tag。tag上线用 svn sw方法,切换分支。
    2. 做了些日志分析,学习memcache,不算入门,能查找问题而已。
    3. eclise的maven问题:生成class文件时候失败,最后发现 order and export顺序有关系,需要在build path里调整之,把maven dependencies。
    4. tomcat与threadlocal:  A web application created a ThreadLocal with key of type [java.lang.ThreadLocal] (value [java.lang.ThreadLocal@44676e3f]) and a value of type [test.leak.threadlocal.value.MyCounter] (value [test.leak.threadlocal.value.MyCounter@62770d2e]) but failed to remove it when the web application was stopped. To prevent a memory leak, the ThreadLocal has been forcibly removed.

      问题出现在使用redisClient时候,之前用的是threadlocal,跑在jetty容器里,没有问题,到tomcat时就发现可能有内存泄露问题,更改为普通类,static模块中初始化,暂时没发现问题,参考tomcat文档:http://wiki.apache.org/tomcat/MemoryLeakProtection
    5. json ojbect写出到页面时出错:org.codehaus.jackson.map.JsonMappingException: No serializer found for class org.json.JSONObject and no properties discovered to create BeanSerializer (to avoid exception, disable SerializationConfig.Feature.FAIL_ON_EMPTY_BEANS) ) 是使用了org.codehaus.jackson.map.ObjectMapper 去writeValueAsString,直接JSONObject.toString()就可以了
      response.setCharacterEncoding("UTF-8");
      response.getOutputStream().print(js.toString()+ '\n');
      OutputStream写中文到页面出错,改为PrintWriter
  • 相关阅读:
    idea 设置默认的maven
    IDEA中Tomcat部署时war和war exploded区别
    所谓的SaaS服务到底是什么?
    java8 Lambda表达式
    java8 :: 用法 (JDK8 双冒号用法)
    idea 本地调试,修改代码,代码自动生效
    nacos配置中心demo
    Logparser 的用法
    android软键盘的一些控制 转来的,格式有点乱
    TranslateAnimation 使用详解
  • 原文地址:https://www.cnblogs.com/shenguanpu/p/2435683.html
Copyright © 2011-2022 走看看