zoukankan      html  css  js  c++  java
  • 面试官说“一开始工资不会给你太高,你可以接受吗?” 怎么怼回去??

    面试官:一开始工资不会给你太高,你可以接受吗?

    程序员:我一开始工作表现不会太好,你可以接受吗? 

    面试官:emmmmmm

     


    面试官:“你简历上写着说你心算速度很快,那我问问你,十九乘以十七是多少?”

    程序员脱口而出:“三十六!”

    面试官:“这也差太远了吧。”

    程序员:“但是很快没错吧。”


      

    ----我是分割线,重点看下面---- 


    draft_job应用,测试环境,Jenkins构建完成,QA反映执行job没反应。xshell连接到服务器上查看log,发现有如下错误导致服务未正常启动。

    2019-07-24 22:04:43,309 INFO  [main-SendThread(10.0.2.110:2181)] (ClientCnxn.java:1032) - Opening socket connection to server 10.0.2.110/10.0.2.110:2181. Will not attempt to authenticate using SASL (unknown error)
    2019-07-24 22:04:43,355 INFO  [main-SendThread(10.0.2.110:2181)] (ClientCnxn.java:876) - Socket connection established to 10.0.2.110/10.0.2.110:2181, initiating session
    2019-07-24 22:04:43,364 INFO  [main-SendThread(10.0.2.110:2181)] (ClientCnxn.java:1299) - Session establishment complete on server 10.0.2.110/10.0.2.110:2181, sessionid = 0x16b69ed782c004c, negotiated timeout = 40000
    2019-07-24 22:04:43,367 INFO  [main-EventThread] (ConnectionStateManager.java:228) - State change: CONNECTED
    2019-07-24 22:04:43,428 WARN  [main] (AbstractApplicationContext.java:549) - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'creditLimitAnalyseReportJob': Unsatisfied dependency expressed through field 'creditLimitReportServiceClient': Error creating bean with name 'creditLimitReportServiceClient': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'emaxcardClient' is defined; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'creditLimitReportServiceClient': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'emaxcardClient' is defined
    2019-07-24 22:04:43,930 INFO  [Curator-Framework-0] (CuratorFrameworkImpl.java:821) - backgroundOperationsLoop exiting
    2019-07-24 22:04:43,933 INFO  [main] (ZooKeeper.java:684) - Session: 0x16b69ed782c004c closed
    2019-07-24 22:04:43,934 INFO  [main-EventThread] (ClientCnxn.java:519) - EventThread shut down for session: 0x16b69ed782c004c

    反馈给开发这个creditLimitAnalyseReportJob的唐玮,他经过重新构建Jenkins,解决了。
    当时手头有其他事儿,也就没有在意。

    晚上上线,发现生产环境在启动服务时也有这个错误。而且通过重新构建的方式并无卵用。

    于是,我们3个人开始细查这个问题。
    这个错误log信息很明确:名字是emaxcardClient的bean没有声明,导致context初始化异常。

    可是,整个工程也查不到emaxcardClient。

    各种排查,各种分析,各种怀疑。

    后来我的怀疑被证明是解决问题的关键。这个项目的代码是从我们以前的pay2.0项目copy过来的。上面错误里的creditLimitReportServiceClient派生自BaseClient,BaseClient是在draft_job所依赖的draft_common包里定义的。BaseClient里有对如下@Resource注解,这里是 "draftClient"。然后去翻看之前pay2.0项目与之对应的emax_common代码,那个BaseClient里面是"emaxcardClient"。 因此,我推断,错误log里提到的creditLimitReportServiceClient阴差阳错的继承了emax_common包的BaseClient了??
    我一边是先让运维把构建出来的zip包给我,好看看lib里是否真有emax_common;一边去查看pom文件里定义的依赖了。可是,并没有依赖emax-common啊!

    运维把zip包发给我们之后,果然,lib包里有emax_common。那么,pom里没有直接依赖emax_common,是不是存在间接依赖呢?我把焦点锁定在了一个名叫warning_thrift的包。我们3个人都无法确定,不过唐玮同学说,这个依赖可以拿掉。那就先拿掉试试再说。
    让运维重新构建Jenkins后,果然,job可以正常启动了!!

    package com.emaxcard.rpc.client;
    
    public abstract class BaseClient {
        @Resource(name = "draftClient")
        private ThriftClientProxy clientProxy;
        private static final Logger log = LoggerFactory.getLogger(BaseClient.class);

    draft项目draft_common是从pay2.0项目的emax_common复制过来的,其中,BaseClient类的package未曾修改。当draft_job同时依赖了draft_common和emax_common,那么就出现了上面的情况。所以,为了避免日后再出现类似问题,还是改一下package比较靠谱。

  • 相关阅读:
    POJ 1502 MPI Maelstrom
    BNUOJ4359 无爱编号
    BNUOJ 6727 Bone Collector
    SAP成都研究院郑晓霞:Shift Left Testing和软件质量保证的一些思考
    聊聊C语言和ABAP
    小技巧:不用任何媒体处理软件进行视频压缩
    如何处理Docker错误消息:please add——insecure-registry
    如何处理Docker的错误消息request canceled:Docker代理问题
    推荐一个高大上的网易云音乐命令行播放工具:musicbox
    Windows下使用python库 curses遇到错误消息的解决方案
  • 原文地址:https://www.cnblogs.com/buguge/p/11248827.html
Copyright © 2011-2022 走看看