java - Source not found,Edit Look up path and now debug is running into exception after clearing first two issues -
please check issue completely,as there many solutions problem,but none worked out.
but stepping new problems.i messed issue few days,which not clearing.
initially,i got source not found issue fixed using answers in so,after got edit path,even got fixed , attached source rt.jar.which shown in source not found. 1 more thing when fetching request browser working fine,only when getting request ionic app or other client issue rising. without clue code stepping exception. , clueless,any appreciated.
logincontroller
public void contextinitialized(servletcontextevent arg0) { httpserver server; try { server = httpserver.create(new inetsocketaddress(5558), 0); myhandler handler = new myhandler(); server.createcontext("/", handler); server.setexecutor(null); server.start(); system.out.println("server up.!!!"); } catch (ioexception e) { system.out.println("problem starting server.!!!"+e); e.printstacktrace(); } } class myhandler implements httphandler { public void handle(httpexchange t) throws ioexception { system.out.println("request method::" + t.getrequestmethod()); inputstreamreader isr = new inputstreamreader(t.getrequestbody(), "utf-8"); bufferedreader br = new bufferedreader(isr); int b; stringbuilder buf = new stringbuilder(512); while ((b = br.read()) != -1) buf.append((char) b);// returns -1,if response not present string strrequestpacket = java.net.urldecoder.decode(buf.tostring(), "utf-8"); system.out.println("msg: " + strrequestpacket); gson gson = new gson(); analyser analyser = gson.fromjson(strrequestpacket, analyser.class); analyser = loginservice.analyserlogin(analyser);//at step running exception br.close(); isr.close(); string response; if(analyser!=null){ response = "success"; }else{ response = "fail"; } t.sendresponseheaders(200, response.length()); outputstream os = t.getresponsebody(); os.write(response.getbytes()); os.close(); } }
serverimpl.class
catch (exception arg25) { serverimpl.this.logger.log(level.finer, "serverimpl.exchange (2)", arg25); serverimpl.this.closeconnection(this.connection); }
thank in advance.
Comments
Post a Comment