java_home无法删除修改

在环境变量里面已经删除JAVA_HOME, 并且已经卸载java 想要重新安装,但是在DOS下面用 set JAVA_HOME在,而且还是之前安装的目录,就是我在之后修改的JAVA_HOME环境都没有生效,该如何解决

图片说明

4个回答

你的这个set操作只对当前这个控制台有效,是临时设置的,关掉之后就没有了。环境变量的值还是通过高级设置里面的环境变量设置的值的。

zhihan_tu
簸箕粄 回复qq_28997153: 这个设置会对你重装Java有影响吗?如果没有可以不用管,实在不行,你可以在控制台重新设置一下
4 年多之前 回复
qq_28997153
qq_28997153 关掉了之后,重启也还是在这里,我在环境变量里面已经删除这条了,但是在set里面还是有,这条set应该是我好几天前设置的还是删除不掉
4 年多之前 回复

直接去环境变量里面设置就行了

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
树莓派里面如何正确配置java的环境变量

最近入树莓派,也初学Linux,想在上面搭建一个轻量级的Web服务器 之前用apt-get install 命令搭建了openJDK+Tomcat7+Mysql成功 后来发现openJDK部分功能受限,想安装Oracle官方的JDK 下载后配置环境变量,发现网上的都是各说各话 而且很多都是错误的 我现在的/ect/profile配置文件如下 ``` # /etc/profile: system-wide .profile file for the Bourne shell (sh(1)) # and Bourne compatible shells (bash(1), ksh(1), ash(1), ...). if [ "`id -u`" -eq 0 ]; then PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" else PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games" fi export PATH if [ "$PS1" ]; then if [ "$BASH" ] && [ "$BASH" != "/bin/sh" ]; then # The file bash.bashrc already sets the default PS1. # PS1='\h:\w\$ ' if [ -f /etc/bash.bashrc ]; then . /etc/bash.bashrc fi else if [ "`id -u`" -eq 0 ]; then PS1='# ' else PS1='$ ' fi fi fi # The default umask is now handled by pam_umask. # See pam_umask(8) and /etc/login.defs. if [ -d /etc/profile.d ]; then for i in /etc/profile.d/*.sh; do if [ -r $i ]; then . $i fi done unset i fi JAVA_HOME=/usr/local/jdk1.8.0 CLASSPATH=.:$JAVA_HOME/lib/tools.jar:$JAVA_HOME/lib/dt.jar PATH=$JAVA_HOME/bin:$PATH export JAVA_HOME export PATH export CLASSPATH ``` 命令行输入java -version提示找不到java 请大家帮帮忙

Dreamweaver5提示正在为Android仿制种子应用程序,一直这样

Dreamweaver5在生成Android仿制种子应用程序时,一直提示 正在为 Android 仿制种子应用程序 也不报错,真不知道是什么问题,不知道有没有大神遇到过这样的问题,请求解决方案。 环境变量如下: JAVA_HOME C:\Java\jdk1.7.0_67 PATH %JAVA_HOME%\bin;%ANDROID_SDK_HOME%\tools;%ANDROID_SDK_HOME%\platform-tools; CLASSPATH .;%JAVA_HOME%\lib\dt.jar;%JAVA_HOME%\lib\tools.jar; ANDROID_SDK_HOME D:\Android\Android_SDK 编译日志 正在为 Android 仿制种子应用程序 <DW> ____________________ set ANT_HOME=D:\PROGRA~1\Adobe\ADOBED~2.5\CONFIG~1\NATIVE~1\APACHE~1 set ANDROID_HOME=D:\Android\sdk set JAVA_HOME=D:\PROGRA~1\Adobe\ADOBED~2.5\JDK set PATH=%JAVA_HOME%\bin;%PATH% cd E:\WEBAPP~1\COMCOM~1.WUY C:\Windows\system32\cmd.exe /u /c D:\PROGRA~1\Adobe\ADOBED~2.5\CONFIG~1\NATIVE~1\DWPHON~1\android\scripts\droidGap.bat "D:\Program Files\Adobe\Adobe Dreamweaver CS5.5\Configuration\NativeAppFramework\DWPhoneGap\android\PhoneGapApp" "wuyou" com.company.wuyou 1.0 "D:\Android\sdk" 19 ____________________ </DW> E ERROR: Clone failed 我测试过了,可能是dw的问题,当第一个apk生成之后 我把bin文件删除掉了,后来就无法生成,可能第一次编译出来的bin文件不删除,要么就是第一次的代码有问题,系统有缓存,所以导致无能这么修改代码,或是创建新的项目都生成不出apk

java环境变量配置的是才拷过来的1.6,为什么cmd java-version还是以前的1.7?

java环境变量配置的是才拷过来的1.6,为什么cmd java-version还是以前的1.7? 而且把1.7的删除了 cmd java就不能用了。怎么回事啊?

tomcat环境变量配置正确,但启动不了

tomcat不能用 在这我加了一句话urlencoding='utf-8' 从myeclipse运行tomcat tomcat一开始运行就出错了 下面是错误信息: 严重: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/firstweb]] at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649) at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247) at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask.run(FutureTask.java:262) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:744) Caused by: java.lang.IllegalArgumentException: Invalid <url-pattern> changeuserdetails in servlet mapping at org.apache.catalina.core.StandardContext.addServletMapping(StandardContext.java:3298) at org.apache.catalina.core.StandardContext.addServletMapping(StandardContext.java:3273) at org.apache.catalina.deploy.WebXml.configureContext(WebXml.java:1438) at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1344) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:876) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:374) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5378) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 10 more 把添加的urlencoding=’utf-8‘删了还是这样, 一开tomcat 就出上面的这个错误, 我把原来的tomat删除 重新解压一个 在myeclipse里重新配置都不行 我myeclipse是10.7,tomcat7.0.55 , jdk1.7。 tomcat虽然出错但tomcat可以运行 但是一打开项目就出404的错误 在这之前项目是没有问题的 直到改了上面的urlencoding=’utf-8‘才出的这种错误 求各路大神帮帮忙!!万分感谢!! 上面那句话是在 tomcat/conf/server.xml里改的,我是想解决两个jsp之间传值乱码的问题,没想到弄巧成拙了。我也是近来才学的java和jsp,再次拜谢各路大神了!

java 关于hadoop 以及intellij 路径设置问题

1. 最近在学习hadoop,尝试在电脑上安装Pig。 安装的时候发现要在.bash中修改java_path。 Pig的要装要求是要求安装在hadoop以及java同一个地方,于是我重新安装了java JDK,与hadoop,pig一起安装在/usr/local/Cellar下。最后将.bashrc文件按要求修改。电脑上可以正常运行Pig。但是当我打开Intellij, 发现原来可与run的mapreduce program build 不了,错误提示说‘can not resolve symble apache’如下图所示。![图片说明](https://img-ask.csdn.net/upload/201902/26/1551164467_310912.png) 于是我网上搜索解决方法,有人说是因为maven项目需要重启,但是我启动不了maven,原因是JDK导入发生了错误。目前的project ructure信息如图:![图片说明](https://img-ask.csdn.net/upload/201902/26/1551164582_461929.png) 于是我向重新导入JDK,但是我发现我在/usr/local/Cellar目录下没有办法安装JDK。因为我在Oracle网站下载的JDK压缩包是dmg的形式,不能在命令行打开并安装。我尝试了hdiutil attach jdk-8u201-macosx-x64.dmg,也没有成功。 请问大家这个问题要如何解决呢?是将Pig和Hadoop文件重新移动到Library目录下吗? 目前我的bash如下图所示: ![图片说明](https://img-ask.csdn.net/upload/201902/26/1551164801_716331.png) 谢谢大家!任何提议都感激不尽!

通讯录中TXT文件读取问题

``` package in; import java.awt.Container; import java.awt.GridLayout; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.io.IOException; import javax.swing.JButton; import javax.swing.JFrame; import javax.swing.JPanel; import javax.swing.WindowConstants; public class Demo extends JFrame { /* * 界面设计 * */ public Demo(){ Container c = getContentPane(); //定义一个顶级容器c setAlwaysOnTop(true); //窗体置顶 JPanel jp = new JPanel(); //新建JPanel面板--jp JButton button1 = new JButton("新建联系人"); JButton button2 = new JButton("删除联系人"); JButton button3 = new JButton("编辑联系人"); JButton button4 = new JButton("查找联系人"); JButton button5 = new JButton("显示所有联系人"); JButton button6 = new JButton("保存联系人到本地"); JButton button7 = new JButton("读取本地联系人"); jp.setLayout(new GridLayout(3,4,5,5));//新建网格布局管理器(行数,列数,组件间的水平垂直间距) jp.add(button1); jp.add(button2); jp.add(button3); jp.add(button4); jp.add(button5); jp.add(button6); jp.add(button7); c.add(jp);//将JPanel面板jp添加到顶级容器c中 setSize(600,150); setTitle("*通 讯 录 管 理 系 统*"); setVisible(true); setResizable(false);//窗体大小由程序员决定,用户不能自由改变大小 setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); /* *按键响应 * * */ button1.addActionListener(new ActionListener(){//添加功能实现 public void actionPerformed(ActionEvent arg0){ Infro.addFunction(); } }); button2.addActionListener(new ActionListener(){//删除功能实现 public void actionPerformed(ActionEvent arg0){ Infro.deleteFunction(); } }); button3.addActionListener(new ActionListener(){//修改功能实现 public void actionPerformed(ActionEvent arg0){ Infro.reditFunction(); } }); button4.addActionListener(new ActionListener(){//查询功能实现 public void actionPerformed(ActionEvent arg0){ try { Infro.searchFunction(); } catch (Exception e) { // TODO Auto-generated catch block e.printStackTrace(); } } }); button5.addActionListener(new ActionListener(){//显示功能实现 public void actionPerformed(ActionEvent arg0){ Infro.showFunction(); } }); button6.addActionListener(new ActionListener(){//保存功能实现 public void actionPerformed(ActionEvent arg0){ try { Infro.writeFunction(); } catch (IOException e) { e.printStackTrace(); } } }); button7.addActionListener(new ActionListener(){//读取功能实现 public void actionPerformed(ActionEvent arg0){ try { Infro.readFunction(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } }); } public static void main(String[] args) { // TODO Auto-generated method stub new Demo(); Infro a = new Infro("", "", "", "", "", ""); } } package in; import java.applet.Applet; import java.awt.Graphics; import java.io.BufferedReader; import java.io.FileReader; import java.io.FileWriter; import java.io.IOException; import java.io.StringWriter; import java.util.ArrayList; import java.util.Arrays; import java.util.Scanner; import javax.swing.JPanel; class Infro { public String Name; public String Sex; public String Unit; public String Homephone; public String Telephone; public String E_mail; static int index = 0; static ArrayList<Infro> list = new ArrayList(); static int len = list.size(); //构造函数 public Infro(String Name,String Sex,String Unit,String Homephone,String Telephone,String E_mail){ this.Name = Name; this.Sex = Sex; this.Unit = Unit; this.Homephone = Homephone; this.Telephone = Telephone; this.E_mail = E_mail; } public String toString(){ return "姓名:"+Name+"\t性别:"+Sex+"\t单位:"+Unit+"\t住宅电话:"+Homephone +"\t移动电话:"+Telephone+"\tE_mail:"+E_mail; } /* * 添加功能 * */ public static void addFunction(){//添加功能 Infro infro = new Infro("","","","","",""); System.out.println("请输入添加的数据:"); Scanner in = new Scanner(System.in); System.out.println("输入姓名:"); infro.Name = in.next(); System.out.println("输入性别:"); infro.Sex = in.next(); System.out.println("输入单位:"); infro.Unit = in.next(); System.out.println("输入住宅电话:"); infro.Homephone = in.next(); System. out.println("输入移动电话:"); infro.Telephone = in.next(); System.out.println("输入E_mail:"); infro.E_mail = in.next(); list.add(index,infro); index++; if(list.isEmpty()){ System.out.println("数据添加失败啦"); }else{ System.out.println("数据添加成功啦"); len++;//list集合长度加一 // System.out.println(list.get(0).toString()); } System.out.println("是否继续添加?1.是 2.否"); Scanner e=new Scanner(System.in); int e1=e.nextInt(); if(e1==1){ Infro.addFunction(); }else{ return; } } /* * 删除功能 * */ public static void deleteFunction(){ System.out.println("输入要删除的联系人的姓名"); Scanner in_2 = new Scanner(System.in); String d1 = in_2.nextLine(); java.util.Iterator<Infro> it = list.iterator(); while (it.hasNext()){ Infro infro = it.next(); if (infro.Name.equals(d1)){ it.remove(); --index;//一定要加这个,否则当做了删除操作再做添加操作的时候会出现异常(类似于指针,栈) System.out.println("删除完毕"+"此时通讯录记录条数为:" + --len); } } System.out.println("是否继续删除?1.是 2.否"); Scanner e=new Scanner(System.in); int e1=e.nextInt(); if(e1==1){ Infro.deleteFunction(); }else{ return; } } /* * 修改功能 * */ public static void reditFunction(){ System.out.println("输入要修改的通讯录的姓名"); Scanner in_r = new Scanner(System.in); String r1 = in_r.nextLine(); for(int a = 0; a < len;a++){ if(r1.equals(list.get(a).Name)){ System.out.println("输入修改后的性别:"); String Sex_1 = in_r.next(); list.get(a).Sex = Sex_1; System.out.println("输入修改后的单位:"); String Unit_1 = in_r.next(); list.get(a).Unit = Unit_1; System.out.println("输入修改后的住宅电话:"); String Homephone_1 = in_r.next(); list.get(a).Homephone = Homephone_1; System.out.println("输入修改后的移动电话:"); String Telephone_1 = in_r.next(); list.get(a).Telephone = Telephone_1; System.out.println("输入修改后的E_mail:"); String E_mail_1 = in_r.next(); list.get(a).E_mail = E_mail_1; System.out.println("数据修改完毕"); } } System.out.println("是否继续修改?1.是 2.否"); Scanner e=new Scanner(System.in); int e1=e.nextInt(); if(e1==1){ Infro.reditFunction(); }else{ return; } } /* * 查询功能 * */ public static void searchFunction() throws Exception{//查询功能 System.out.println("请选择查询方式: "); System.out.println("1.姓名 2.性别 3.单位 4.住宅电话 5.移动电话 6.E_mail "); Scanner in_0=new Scanner(System.in); int s0=in_0.nextInt(); if(s0==1){ System.out.println("请输入要查询的姓名:"); Scanner in_1 = new Scanner(System.in); String s1=in_1.nextLine(); for(int a= 0; a<len;a++){//切记,,这里不能用a<=list.size(),否则会数组越界异常 if(s1.equals(list.get(a).Name)){ System.out.println(list.get(a).toString()); } } } else if(s0==2){ System.out.println("请输入要查询的性别:"); Scanner in_2 = new Scanner(System.in); String s2=in_2.nextLine(); for(int a= 0; a<len;a++){//切记,,这里不能用a<=list.size(),否则会数组越界异常 if(s2.equals(list.get(a).Sex)){ System.out.println(list.get(a).toString()); } } } else if(s0==3){ System.out.println("请输入要查询的单位:"); Scanner in_3 = new Scanner(System.in); String s3=in_3.nextLine(); for(int a= 0; a<len;a++){//切记,,这里不能用a<=list.size(),否则会数组越界异常 if(s3.equals(list.get(a).Unit)){ System.out.println(list.get(a).toString()); } } } if(s0==4){ System.out.println("请输入要查询的住宅电话:"); Scanner in_4 = new Scanner(System.in); String s4=in_4.nextLine(); for(int a= 0; a<len;a++){//切记,,这里不能用a<=list.size(),否则会数组越界异常 if(s4.equals(list.get(a).Homephone)){ System.out.println(list.get(a).toString()); } } } else if(s0==5){ System.out.println("请输入要查询的移动电话:"); Scanner in_5 = new Scanner(System.in); String s5=in_5.nextLine(); for(int a= 0; a<len;a++){//切记,,这里不能用a<=list.size(),否则会数组越界异常 if(s5.equals(list.get(a).Telephone)){ System.out.println(list.get(a).toString()); } } } else if(s0==6){ System.out.println("请输入要查询的E_mail:"); Scanner in_6 = new Scanner(System.in); String s6=in_6.nextLine(); for(int a= 0; a<len;a++){//切记,,这里不能用a<=list.size(),否则会数组越界异常 if(s6.equals(list.get(a).E_mail)){ System.out.println(list.get(a).toString()); } } } } /* * 显示功能 * */ public static void showFunction(){ for(int i = 0 ;i<len;i++){ System.out.println(list.get(i).toString()); } } /* * 保存功能 * */ public static void writeFunction() throws IOException{ FileWriter writer = new FileWriter("通讯录管理.txt"); for(int i = 0 ;i<len;i++){ String []strwriter = new String[len]; strwriter[i]=list.get(i).toString(); writer.write(strwriter[i]); writer.write("\r\n"); System.out.println("成功写入一行数据到 通讯录管理.txt 中"); } writer.close();//关闭写入流,释放资源 } /* * 读取功能 * */ public static void readFunction() throws IOException{ FileReader reader = new FileReader("通讯录管理.txt"); BufferedReader br = new BufferedReader(reader); String str; while((str = br.readLine()) != null){//每次读取一行文本,判断是否到达文件尾 System.out.println(str); } br.close(); } } ``` 课程设计中遇到了问题… 在运行时输入,可以查询,编辑等操作。可是保存到本地后退出运行,第二次再运行时读取本地联系人,就没办法执行查询操作了。我改了好久还是不行,请各位哥哥姐姐帮忙看一下,拜托~因为还没有学数据库,只能用文件了。 超过20个分屏显示就不要了,因为貌似java没有分屏显示……其他的功能,按姓名排序也希望你们能给些思路,谢谢谢谢 这是题目: 3. 以本班同学的具体数据为背景,设计一个本班同学通讯录(3人) 通讯录要求存储姓名、性别、单位、住宅电话、移动电话、E-mail地址等内容。系统功能要求如下: (1)通讯录记录按姓名排序存放,显示时每屏不超过20个记录,超过时分屏显示。 (2)增加某人的通讯录。 (3)修改某人的通讯录。 (4)删除某人的通讯录。 (5)按多种方式查询符合条件的信息。

在mysql5.7中实现级联删除,即删除主表中信息的同时删除参照表中对应记录,求大神指导

参照表中设置了级联删除和级联更新但是没有实现。。 上网搜索后用触发器如下 ``` CREATE TRIGGER deleUser_trigger BEFORE DELETE ON users FOR EACH ROW BEGIN DELETE FROM stuinfo WHERE stu_id=old.id; END; ``` 然后。。。报错 ``` You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 4 ``` mysql版本5.7 不知道该怎么解决,新手求指导 (另外这一过程也可以在java中实现,但觉得在数据库中实现更好些,所以想在问一下,这两种实现方式有哪些区别吗,是减少java中代码量吗)

logback日志数量修改问题

现在需要将logback的最大日志数量提高到40个,由于logback内部最大只支持20个,设置超过20后也只输出20个文件。 重写FixedWindowRollingPolicy类如下: package com.logback.test; import ch.qos.logback.core.rolling.FixedWindowRollingPolicy; public class CustomFixedWindowRollingPolicy extends FixedWindowRollingPolicy { private static int MAX_WINDOW_SIZE = 500; @Override protected int getMaxWindowSize() { return MAX_WINDOW_SIZE; } } logback.xml配置如下: <appender name="realMasterAppender" class="ch.qos.logback.core.rolling.RollingFileAppender"> <File>${log.home}/real.log</File> <rollingPolicy class="com.logback.test.CustomFixedWindowRollingPolicy"> <fileNamePattern>${log.home}/real.log.%i</fileNamePattern> <minIndex>1</minIndex> <maxIndex>100</maxIndex> </rollingPolicy> <triggeringPolicy class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy"> <maxFileSize>40MB</maxFileSize> </triggeringPolicy> <encoder> <pattern>%date %level [%file : %line] %msg%n</pattern> </encoder> <filter class="ch.qos.logback.classic.filter.ThresholdFilter"> <level>DEBUG</level> </filter> </appender> 运行后后台报错如下: 17:32:44,585 |-INFO in ch.qos.logback.core.joran.action.NestedComplexPropertyIA - Assuming default type [ch.qos.logback.classic.encoder.PatternLayoutEncoder] for [encoder] property 17:32:44,632 |-INFO in ch.qos.logback.core.joran.action.AppenderAction - About to instantiate appender of type [ch.qos.logback.core.rolling.RollingFileAppender] 17:32:44,632 |-INFO in ch.qos.logback.core.joran.action.AppenderAction - Naming appender as [infoAppender] 17:32:44,632 |-ERROR in ch.qos.logback.core.joran.action.NestedComplexPropertyIA - Could not create component [rollingPolicy] of type [com.logback.test.CustomFixedWindowRollingPolicy] java.lang.ClassNotFoundException: com.logback.test.CustomFixedWindowRollingPolicy at java.lang.ClassNotFoundException: com.logback.test.CustomFixedWindowRollingPolicy at at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:494) at at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:410) at at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:398) at at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:105) at at java.lang.ClassLoader.loadClass(Unknown Source) at at ch.qos.logback.core.util.Loader.loadClass(Loader.java:124) at at ch.qos.logback.core.joran.action.NestedComplexPropertyIA.begin(NestedComplexPropertyIA.java:100) at at ch.qos.logback.core.joran.spi.Interpreter.callBeginAction(Interpreter.java:275) at at ch.qos.logback.core.joran.spi.Interpreter.startElement(Interpreter.java:147) at at ch.qos.logback.core.joran.spi.Interpreter.startElement(Interpreter.java:129) at at ch.qos.logback.core.joran.spi.EventPlayer.play(EventPlayer.java:50) 求解啊!

linux执行source /etc/profile时出现如下情况

declare -x CLASSPATH=".:/usr/local/java/jdk1.8.0_191//lib/dt.jar:/usr/local/java/jdk1.8.0_191//lib/tools.jar:/usr/local/java/jdk1.8.0_191/jre//lib:.:/usr/local/java/jdk1.8.0_191//lib/dt.jar:/usr/local/java/jdk1.8.0_191//lib/tools.jar:/usr/local/java/jdk1.8.0_191/jre//lib:" declare -x DISPLAY="localhost:10.0" declare -x HADOOP_HOME="/usr/local/hadoop/hadoop-2.8.5/" declare -x HISTCONTROL="ignoredups" declare -x HISTSIZE="1000" declare -x HIVE_HOME="/usr/local/hive" declare -x HOME="/root" declare -x HOSTNAME="hadoop01" declare -x JAVA_HOME="/usr/local/java/jdk1.8.0_191/" declare -x JRE_HOME="/usr/local/java/jdk1.8.0_191/jre/" declare -x LANG="zh_CN.UTF-8" declare -x LESSOPEN="||/usr/bin/lesspipe.sh %s" declare -x LOGNAME="root" declare -x LS_COLORS="rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=01;05;37;41:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.axv=01;35:*.anx=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=01;36:*.au=01;36:*.flac=01;36:*.mid=01;36:*.midi=01;36:*.mka=01;36:*.mp3=01;36:*.mpc=01;36:*.ogg=01;36:*.ra=01;36:*.wav=01;36:*.axa=01;36:*.oga=01;36:*.spx=01;36:*.xspf=01;36:" declare -x MAIL="/var/spool/mail/root" declare -x OLDPWD="/root" declare -x PATH="/usr/local/hive/bin:/usr/local/hive/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/usr/local/java/jdk1.8.0_191//bin:/usr/local/hadoop/hadoop-2.8.5//bin:/usr/local/hadoop/hadoop-2.8.5//sbin::/root/bin:/usr/local/java/jdk1.8.0_191//bin:/usr/local/java/jdk1.8.0_191/jre//bin:/usr/local/hadoop/hadoop-2.8.5//bin:/usr/local/hadoop/hadoop-2.8.5//sbin:" declare -x PWD="/usr/local/hadoop/hadoop-2.8.5" declare -x SELINUX_LEVEL_REQUESTED="" declare -x SELINUX_ROLE_REQUESTED="" declare -x SELINUX_USE_CURRENT_RANGE="" declare -x SHELL="/bin/bash" declare -x SHLVL="1" declare -x SSH_CLIENT="192.168.240.1 52834 22" declare -x SSH_CONNECTION="192.168.240.1 52834 192.168.240.131 22" declare -x SSH_TTY="/dev/pts/0" declare -x TERM="xterm" declare -x USER="root" declare -x XDG_DATA_DIRS="/root/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share:/usr/share" declare -x XDG_RUNTIME_DIR="/run/user/0" declare -x XDG_SESSION_ID="1"

只能添加,不能更新,删除,查询数据,怎么改?

MainActivity.java ``` package com.example.sqlite; import java.util.ArrayList; import java.util.List; import android.app.Activity; import android.database.Cursor; import android.database.sqlite.SQLiteDatabase; import android.os.Bundle; import android.view.Menu; import android.view.MenuItem; import android.view.View; import android.view.View.OnClickListener; import android.widget.ArrayAdapter; import android.widget.Button; import android.widget.EditText; import android.widget.ListAdapter; import android.widget.ListView; import android.widget.TextView; import android.widget.Toast; public class MainActivity extends Activity implements OnClickListener{ private static final String TAG="Add"; private static final ListAdapter ListAdapter = null; private EditText ecode,ename,ebirth; private Button badd,bdel,bupdate,bsele; private SQLiteDatabase db=null; private TextView tedatashow; private ListView datashow; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); ecode=(EditText)findViewById(R.id.ecode); ename=(EditText)findViewById(R.id.ename); ebirth=(EditText)findViewById(R.id.ebirth); badd=(Button)findViewById(R.id.badd); bdel=(Button)findViewById(R.id.bdel); bupdate=(Button)findViewById(R.id.bupdate); bsele=(Button)findViewById(R.id.bsele); tedatashow=(TextView)findViewById(R.id.tedatashow); datashow=(ListView)findViewById(R.id.datashow); badd.setOnClickListener((android.view.View.OnClickListener) this); bdel.setOnClickListener((android.view.View.OnClickListener) this); bsele.setOnClickListener((android.view.View.OnClickListener) this); bupdate.setOnClickListener((android.view.View.OnClickListener) this); } public void onClick(View v) { // TODO Auto-generated method stub MyDBHelper helper=new MyDBHelper(this); db=helper.getWritableDatabase(); if(v==badd) { if(ecode.getText().toString().trim().length()!=0 && ename.getText().toString().trim().length()!=0 && ebirth.getText().toString().trim().length()!=0) { try { String sql="INSERT INTO user(ecode,ename,ebirth)" +"VALUES('"+ecode.getText()+"','" +ename.getText()+"','" +ebirth.getText()+"')"; db.execSQL(sql); Toast.makeText(this, "添加成功!", Toast.LENGTH_LONG).show(); ecode.setText(""); ename.setText(""); ebirth.setText(""); } catch(Exception e) { Toast.makeText(this, "出错了!"+ e.getMessage(),Toast.LENGTH_LONG).show(); } } else Toast.makeText(this, "学号和姓名出生日期不能为空!", Toast.LENGTH_LONG).show(); } if(v==bdel) { if(ecode.getText().toString().trim().length()!=0) { try { String sql="delete from user where ecode='"+ecode.getText()+"'"; db.execSQL(sql); Toast.makeText(this, "成功删除!", Toast.LENGTH_LONG).show(); ecode.setText(""); } catch(Exception e) { Toast.makeText(this, "出错了!", Toast.LENGTH_LONG).show(); } } } if(v==bupdate) { if(ecode.getText().toString().trim().length()!=0 && ename.getText().toString().trim().length()!=0 && ebirth.getText().toString().trim().length()!=0) { try { String sql="update user set ecode='"+ecode.getText() +"',ename='"+ename.getText()+"',birthday='" +ebirth.getText()+"'where code='" +ecode.getText()+"''"; db.execSQL(sql); Toast.makeText(this, "成功更新!", Toast.LENGTH_LONG).show(); ecode.setText(""); ename.setText(""); ebirth.setText(""); } catch(Exception e) { Toast.makeText(this, "出错了!"+e.getMessage(),Toast.LENGTH_LONG).show(); } } else Toast.makeText(this, "学号姓名出生日期不能为空!", Toast.LENGTH_LONG).show(); } if(v==bsele) { if(ecode.getText().toString().trim().length()!=0) { try { List all=new ArrayList(); String sql="select * from user where ecode =? or ename =? or ebirth =? "; Cursor result=this.db.rawQuery(sql, null); for(result.moveToFirst();!result.isAfterLast();result.moveToNext()) { all.add("["+result.getString(0)+"]"+""+result.getString(1)+","+result.getString(2)); } datashow.setAdapter(ListAdapter); new ArrayAdapter(this, android.R.layout.simple_expandable_list_item_1,all); } catch(Exception f) { Toast.makeText(this, "显示不了", Toast.LENGTH_LONG).show(); } } } db.close(); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.main, menu); return true; } @Override public boolean onOptionsItemSelected(MenuItem item) { // Handle action bar item clicks here. The action bar will // automatically handle clicks on the Home/Up button, so long // as you specify a parent activity in AndroidManifest.xml. int id = item.getItemId(); if (id == R.id.action_settings) { return true; } return super.onOptionsItemSelected(item); } } ``` MyDBHelper.java ``` package com.example.sqlite; import android.content.Context; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper; public class MyDBHelper extends SQLiteOpenHelper{ public MyDBHelper(Context context) { super(context,"mvdb.db",null,1); } public void onCreate(SQLiteDatabase db) { String sql="create table user(ecode text,ename text,ebirth text);"; db.execSQL(sql); } public void onUpgrade(SQLiteDatabase db,int arg1,int arg2) { String sql="create table user(ecode text,ename text,ebirth text);"; db.execSQL(sql); this.onCreate(db); } } ```

log4j2设置了定时输出日志,但是日志没有变动的话不会自动生成日志,求大神解答

我设置每分钟生成一个日志文件 ![图片说明](https://img-ask.csdn.net/upload/202002/17/1581947786_276404.png) 这样配置是可以按每分钟生成日志,但不是实时的,比如我01分有了记录,但是后面几分钟都没有日志,就不会再02分生成01分的日志,直到有了新的日志记录才会生成之前01分那个日志,依次类推,我想每分钟都操作一下前一分钟的日志,就没法得到文件,求帮助,可以解决么?

在JSP中的<c:forEach items="${list}" var="publish" varStatus="status">想更换数据表publish为book,更换后无法显示,请问各位大神怎么解决该问题?

一开始在我的JSP项目中,正常运行显示,后来发现页面显示时,数据库中的数据表显示错误,我在页面当中显示的是数据库library中publish表中的数据信息,但实际上我需要的是数据库library中book表中的信息,替换数据表后,用<c:forEach>标签遍历查询,却显示空白,连表格框架都消失了,请问我该如何修改,才能将表publish成功替换成表book?恳求各位大佬指点,感激不尽! 如下,为publish表成功显示的图片 ![图片说明](https://img-ask.csdn.net/upload/202003/12/1583977874_80197.png) 如下,为book表显示失败的图片 ![图片说明](https://img-ask.csdn.net/upload/202003/12/1583978028_493291.png) ``` <!--以下为publish表显示成功的代码--> <c:forEach items="${list}" var="publish" varStatus="status"> <c:choose> <c:when test="${status.index%2 == '0'}"> <tr class="odd"> <td>${status.index+ 1}</td> <td>${publish.name}</td> <td>${publish.addr}</td> <td>${publish.tel}</td> <td>${book.price}</td> <td> <a href="<%=basePath%>publish/form?id=${book.id}">修改</a> <a href="<%=basePath%>publish/del?id=${book.id}" onclick="return confirm('你确认要删除吗?');"">删除</a> </td> </tr> </c:when> <c:otherwise> <tr class="even"> <td>${status.index+ 1}</td> <td>${publish.name}</td> <td>${publish.addr}</td> <td>${publish.tel}</td> <td>${book.price}</td> <td> <a href="<%=basePath%>publish/form?id=${book.id}">修改</a> <a href="<%=basePath%>publish/del?id=${book.id}" onclick="return confirm('你确认要删除吗?');"">删除</a> </td> </tr> </c:otherwise> </c:choose> </c:forEach> <!--以下为更改后book表显示失败的代码--> <!--以下为更改后book表显示失败的代码--> <!--以下为更改后book表显示失败的代码--> <!--以下为更改后book表显示失败的代码--> <c:forEach items="${list}" var="book" varStatus="status"> <c:choose> <c:when test="${status.index%2 == '0'}"> <tr class="odd"> <td>${status.index+ 1}</td> <td>${book.name}</td> <td>${book.code}</td> <td>${book.auther}</td> <td>${book.price}</td> <td> <a href="<%=basePath%>book/form?id=${book.id}">修改</a> <a href="<%=basePath%>book/del?id=${book.id}" onclick="return confirm('你确认要删除吗?');"">删除</a> </td> </tr> </c:when> <c:otherwise> <tr class="even"> <td>${status.index+ 1}</td> <td>${book.name}</td> <td>${book.code}</td> <td>${book.author}</td> <td>${book.price}</td> <td> <a href="<%=basePath%>book/form?id=${book.id}">修改</a> <a href="<%=basePath%>book/del?id=${book.id}" onclick="return confirm('你确认要删除吗?');"">删除</a> </td> </tr> </c:otherwise> </c:choose> </c:forEach> ``` 当运行publish表那张图显示的项目时,无报错 2020-3-12 10:12:16 org.apache.catalina.core.AprLifecycleListener init 信息: Loaded APR based Apache Tomcat Native library 1.1.29 using APR version 1.4.8. 2020-3-12 10:12:16 org.apache.catalina.core.AprLifecycleListener init 信息: APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true]. 2020-3-12 10:12:17 org.apache.catalina.core.AprLifecycleListener initializeSSL 信息: OpenSSL successfully initialized (OpenSSL 1.0.1e 11 Feb 2013) 2020-3-12 10:12:17 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["http-apr-8080"] 2020-3-12 10:12:17 org.apache.coyote.AbstractProtocol init 信息: Initializing ProtocolHandler ["ajp-apr-8009"] 2020-3-12 10:12:17 org.apache.catalina.startup.Catalina load 信息: Initialization processed in 849 ms 2020-3-12 10:12:17 org.apache.catalina.core.StandardService startInternal 信息: Starting service Catalina 2020-3-12 10:12:17 org.apache.catalina.core.StandardEngine startInternal 信息: Starting Servlet Engine: Apache Tomcat/7.0.52 2020-3-12 10:12:17 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\Code 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/core_rt is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/core is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/core is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/fmt_rt is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/fmt is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/fmt is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/functions is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/permittedTaglibs is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/scriptfree is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/sql_rt is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/sql is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/sql is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/xml_rt is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/xml is already defined 2020-3-12 10:12:28 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/xml is already defined 2020-3-12 10:12:28 org.apache.tomcat.websocket.server.WsSci onStartup 信息: JSR 356 WebSocket (Java WebSocket 1.0) support is not available when running on Java 6. To suppress this message, run Tomcat on Java 7, remove the WebSocket JARs from $CATALINA_HOME/lib or add the WebSocketJARs to the tomcat.util.scan.DefaultJarScanner.jarsToSkip property in $CATALINA_BASE/conf/catalina.properties. Note that the deprecated Tomcat 7 WebSocket API will be available. 2020-3-12 10:12:28 org.apache.catalina.core.ApplicationContext log 信息: No Spring WebApplicationInitializer types detected on classpath 2020-3-12 10:12:29 org.apache.catalina.core.ApplicationContext log 信息: Initializing Spring root WebApplicationContext 2020-3-12 10:12:41 org.apache.catalina.core.ApplicationContext log 信息: Initializing Spring FrameworkServlet 'springServlet' ========= Enabled refresh mybatis mapper ========= 2020-3-12 10:13:00 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\docs 2020-3-12 10:13:00 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\examples 2020-3-12 10:13:00 org.apache.catalina.core.ApplicationContext log 信息: ContextListener: contextInitialized() 2020-3-12 10:13:00 org.apache.catalina.core.ApplicationContext log 信息: SessionListener: contextInitialized() 2020-3-12 10:13:00 org.apache.catalina.core.ApplicationContext log 信息: ContextListener: attributeAdded('org.apache.jasper.compiler.TldLocationsCache', 'org.apache.jasper.compiler.TldLocationsCache@fa4b23') 2020-3-12 10:13:00 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\host-manager 2020-3-12 10:13:00 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\igeek 2020-3-12 10:13:00 org.apache.catalina.loader.WebappClassLoader validateJarFile 信息: validateJarFile(D:\MyEclipse\Tomcat7.0\webapps\igeek\WEB-INF\lib\servlet-api.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class 2020-3-12 10:13:01 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\library 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://www.springframework.org/tags/form is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://www.springframework.org/tags is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/core_rt is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/core is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/core is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/fmt_rt is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/fmt is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/fmt is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/functions is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/permittedTaglibs is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/scriptfree is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/sql_rt is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/sql is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/sql is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/xml_rt is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/xml is already defined 2020-3-12 10:13:04 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/xml is already defined 2020-3-12 10:13:04 org.apache.catalina.core.ApplicationContext log 信息: No Spring WebApplicationInitializer types detected on classpath 2020-3-12 10:13:04 org.apache.catalina.core.ApplicationContext log 信息: Initializing Spring root WebApplicationContext log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader). log4j:WARN Please initialize the log4j system properly. log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info. 2020-3-12 10:13:14 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\manager 2020-3-12 10:13:14 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\ROOT 2020-3-12 10:13:14 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\springmvc03fAjax 2020-3-12 10:13:14 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\springmvc03LYF 2020-3-12 10:13:16 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://www.springframework.org/tags/form is already defined 2020-3-12 10:13:16 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://www.springframework.org/tags is already defined 2020-3-12 10:13:16 org.apache.catalina.core.ApplicationContext log 信息: No Spring WebApplicationInitializer types detected on classpath 2020-3-12 10:13:16 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\MyEclipse\Tomcat7.0\webapps\SSH 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/core_rt is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/core is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/core is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/fmt_rt is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/fmt is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/fmt is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/functions is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/permittedTaglibs is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://jakarta.apache.org/taglibs/standard/scriptfree is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/sql_rt is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/sql is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/sql is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/xml_rt is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jstl/xml is already defined 2020-3-12 10:13:27 org.apache.catalina.startup.TaglibUriRule body 信息: TLD skipped. URI: http://java.sun.com/jsp/jstl/xml is already defined 2020-3-12 10:13:27 org.apache.catalina.core.ApplicationContext log 信息: No Spring WebApplicationInitializer types detected on classpath ====================================================================== 欢迎使用 JeeSite 快速开发平台 - Powered By http://jeesite.com ====================================================================== 2020-3-12 10:13:28 org.apache.catalina.core.ApplicationContext log 信息: Initializing Spring root WebApplicationContext 2020-03-12 10:13:32,591 WARN [net.sf.ehcache.DiskStorePathManager] - diskStorePath '..\temp\jeesite\ehcache' is already used by an existing CacheManager either in the same VM or in a different process. The diskStore path for this CacheManager will be set to ..\temp\jeesite\ehcache\ehcache_auto_created4673197487363253977diskstore. To avoid this warning consider using the CacheManager factory methods to create a singleton CacheManager or specifying a separate ehcache configuration (ehcache.xml) for each CacheManager instance. 2020-03-12 10:13:32,657 WARN [sf.ehcache.store.disk.DiskStorageFactory] - Data in persistent disk stores is ignored for stores from automatically created directories. Remove diskPersistent or resolve the conflicting disk paths in cache configuration. Deleting data file D:\MyEclipse\Tomcat7.0\bin\..\temp\jeesite\ehcache\ehcache_auto_created4673197487363253977diskstore\active%0053essions%0043ache.data 2020-3-12 10:13:41 org.apache.catalina.core.ApplicationContext log 信息: Initializing Spring FrameworkServlet 'springServlet' ========= Enabled refresh mybatis mapper ========= 2020-3-12 10:13:50 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["http-apr-8080"] 2020-3-12 10:13:50 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["ajp-apr-8009"] 2020-3-12 10:13:50 org.apache.catalina.startup.Catalina start 信息: Server startup in 92843 ms 当运行book表那张图显示的项目时,出现报错 报错信息: 2020-3-12 10:14:33 org.apache.catalina.core.ApplicationContext log 信息: Initializing Spring FrameworkServlet 'springmvc' 2020-3-12 10:14:36 org.apache.jasper.compiler.TldLocationsCache tldScanJar 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 2020-3-12 10:14:38 org.apache.catalina.core.ApplicationDispatcher invoke 严重: Servlet.service() for servlet jsp threw exception javax.el.PropertyNotFoundException: Property 'code' not found on type com.library.entity.Publish at javax.el.BeanELResolver$BeanProperties.get(BeanELResolver.java:229) at javax.el.BeanELResolver$BeanProperties.access$400(BeanELResolver.java:206) at javax.el.BeanELResolver.property(BeanELResolver.java:317) at javax.el.BeanELResolver.getValue(BeanELResolver.java:85) at org.apache.jasper.el.JasperELResolver.getValue(JasperELResolver.java:104) at org.apache.el.parser.AstValue.getValue(AstValue.java:182) at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:184) at org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(PageContextImpl.java:967) at org.apache.jsp.WEB_002dINF.jsp.publishList_jsp._jspService(publishList_jsp.java:708) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:748) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:486) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:411) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:338) at org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:238) at org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:262) at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1180) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:950) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:852) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:882) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:778) at javax.servlet.http.HttpServlet.service(HttpServlet.java:620) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:119) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1040) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:607) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2441) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2430) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:619) 2020-3-12 10:14:38 org.apache.catalina.core.StandardWrapperValve invoke 严重: Servlet.service() for servlet [springmvc] in context with path [/library] threw exception [An exception occurred processing JSP page /WEB-INF/jsp/publishList.jsp at line 123 120: <tr class="odd"> 121: <td>${status.index+ 1}</td> 122: <td>${book.name}</td> 123: <td>${book.code}</td> 124: <td>${book.auther}</td> 125: <td>${book.price}</td> 126: <td> Stacktrace:] with root cause javax.el.PropertyNotFoundException: Property 'code' not found on type com.library.entity.Publish at javax.el.BeanELResolver$BeanProperties.get(BeanELResolver.java:229) at javax.el.BeanELResolver$BeanProperties.access$400(BeanELResolver.java:206) at javax.el.BeanELResolver.property(BeanELResolver.java:317) at javax.el.BeanELResolver.getValue(BeanELResolver.java:85) at org.apache.jasper.el.JasperELResolver.getValue(JasperELResolver.java:104) at org.apache.el.parser.AstValue.getValue(AstValue.java:182) at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:184) at org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(PageContextImpl.java:967) at org.apache.jsp.WEB_002dINF.jsp.publishList_jsp._jspService(publishList_jsp.java:708) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:748) at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:486) at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:411) at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:338) at org.springframework.web.servlet.view.InternalResourceView.renderMergedOutputModel(InternalResourceView.java:238) at org.springframework.web.servlet.view.AbstractView.render(AbstractView.java:262) at org.springframework.web.servlet.DispatcherServlet.render(DispatcherServlet.java:1180) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:950) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:852) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:882) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:778) at javax.servlet.http.HttpServlet.service(HttpServlet.java:620) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.springframework.orm.hibernate4.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:119) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122) at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:501) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98) at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408) at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1040) at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:607) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2441) at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2430) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:619)

使用HbaseTemplate对hbase数据库进行增删改查速度缓慢,效率不高

hbase我的是单机版的,不上集群,版本是1.2.6 使用Java代码对HBASE数据库进行查询期间没有报错,但就是不管为查询多少条数据都是花了20s 在 hbase-env.sh文件里面加了下面配置: export JAVA_HOME=/usr/local/jdk1.8 export HBASE_MANAGES_ZK=true 在hbase-site.xml文件加了下面配置: <property> <name>hbase.rootdir</name> <value>file:///usr/local/app/hbase-1.2/data</value> </property> 下面是HBASE的一些log日志 2018-07-16 20:09:19,899 INFO [ProcessThread(sid:0 cport:-1):] server.PrepRequestProcessor: Got user-level KeeperException when processing sessionid:0x164a2feb4680001 type:create cxid:0x7 zxid:0xa7 txntype:-1 reqpath:n/a Error Path:/hbase/flush-table-proc/acquired Error:KeeperErrorCode = NodeExists for /hbase/flush-table-proc/acquired 2018-07-16 20:09:19,909 INFO [ProcessThread(sid:0 cport:-1):] server.PrepRequestProcessor: Got user-level KeeperException when processing sessionid:0x164a2feb4680001 type:create cxid:0xa zxid:0xa8 txntype:-1 reqpath:n/a Error Path:/hbase/online-snapshot/acquired Error:KeeperErrorCode = NodeExists for /hbase/online-snapshot/acquired 2018-07-16 20:09:19,910 INFO [ProcessThread(sid:0 cport:-1):] server.PrepRequestProcessor: Got user-level KeeperException when processing sessionid:0x164a2feb4680000 type:create cxid:0x2a zxid:0xa9 txntype:-1 reqpath:n/a Error Path:/hbase/flush-table-proc/acquired Error:KeeperErrorCode = NodeExists for /hbase/flush-table-proc/acquired 2018-07-16 20:09:19,911 INFO [master:37346.activeMasterManager] procedure.ZKProcedureUtil: Clearing all procedure znodes: /hbase/flush-table-proc/acquired /hbase/flush-table-proc/reached /hbase/flush-table-proc/abort 2018-07-16 20:09:19,915 INFO [RS:0;master:51571] regionserver.MemStoreFlusher: globalMemStoreLimit=97.5 M, globalMemStoreLimitLowMark=92.6 M, maxHeap=243.7 M 2018-07-16 20:09:19,919 INFO [ProcessThread(sid:0 cport:-1):] server.PrepRequestProcessor: Got user-level KeeperException when processing sessionid:0x164a2feb4680000 type:create cxid:0x30 zxid:0xaa txntype:-1 reqpath:n/a Error Path:/hbase/online-snapshot/acquired Error:KeeperErrorCode = NodeExists for /hbase/online-snapshot/acquired 2018-07-16 20:09:19,919 INFO [RS:0;master:51571] regionserver.HRegionServer: CompactionChecker runs every 10sec 2018-07-16 20:09:19,925 INFO [master:37346.activeMasterManager] procedure.ZKProcedureUtil: Clearing all procedure znodes: /hbase/online-snapshot/acquired /hbase/online-snapshot/reached /hbase/online-snapshot/abort 2018-07-16 20:09:19,938 INFO [RS:0;master:51571] regionserver.RegionServerCoprocessorHost: System coprocessor loading is enabled 2018-07-16 20:09:19,938 INFO [RS:0;master:51571] regionserver.RegionServerCoprocessorHost: Table coprocessor loading is enabled 2018-07-16 20:09:19,940 INFO [RS:0;master:51571] regionserver.HRegionServer: reportForDuty to master=master,37346,1531742959208 with port=51571, startcode=1531742959688 2018-07-16 20:09:19,951 INFO [master:37346.activeMasterManager] master.MasterCoprocessorHost: System coprocessor loading is enabled 2018-07-16 20:09:19,964 INFO [master:37346.activeMasterManager] procedure2.ProcedureExecutor: Starting procedure executor threads=5 2018-07-16 20:09:19,964 INFO [master:37346.activeMasterManager] wal.WALProcedureStore: Starting WAL Procedure Store lease recovery 2018-07-16 20:09:19,990 INFO [master:37346.activeMasterManager] wal.WALProcedureStore: Lease acquired for flushLogId: 105 2018-07-16 20:09:19,999 INFO [master:37346.activeMasterManager] zookeeper.RecoverableZooKeeper: Process identifier=replicationLogCleaner connecting to ZooKeeper ensemble=localhost:2181 2018-07-16 20:09:19,999 INFO [master:37346.activeMasterManager] zookeeper.ZooKeeper: Initiating client connection, connectString=localhost:2181 sessionTimeout=10000 watcher=replicationLogCleaner0x0, quorum=localhost:2181, baseZNode=/hbase 2018-07-16 20:09:20,000 INFO [master:37346.activeMasterManager-SendThread(localhost:2181)] zookeeper.ClientCnxn: Opening socket connection to server localhost/0:0:0:0:0:0:0:1:2181. Will not attempt to authenticate using SASL (unknown error) 2018-07-16 20:09:20,001 INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181] server.NIOServerCnxnFactory: Accepted socket connection from /0:0:0:0:0:0:0:1:52389 2018-07-16 20:09:20,001 INFO [master:37346.activeMasterManager-SendThread(localhost:2181)] zookeeper.ClientCnxn: Socket connection established to localhost/0:0:0:0:0:0:0:1:2181, initiating session 2018-07-16 20:09:20,001 INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181] server.ZooKeeperServer: Client attempting to establish new session at /0:0:0:0:0:0:0:1:52389 2018-07-16 20:09:20,002 INFO [SyncThread:0] server.ZooKeeperServer: Established session 0x164a2feb4680005 with negotiated timeout 10000 for client /0:0:0:0:0:0:0:1:52389 2018-07-16 20:09:20,003 INFO [master:37346.activeMasterManager-SendThread(localhost:2181)] zookeeper.ClientCnxn: Session establishment complete on server localhost/0:0:0:0:0:0:0:1:2181, sessionid = 0x164a2feb4680005, negotiated timeout = 10000 2018-07-16 20:09:20,007 INFO [ProcessThread(sid:0 cport:-1):] server.PrepRequestProcessor: Got user-level KeeperException when processing sessionid:0x164a2feb4680005 type:create cxid:0x1 zxid:0xad txntype:-1 reqpath:n/a Error Path:/hbase/replication/rs Error:KeeperErrorCode = NodeExists for /hbase/replication/rs 2018-07-16 20:09:20,018 INFO [master:37346.activeMasterManager] master.ServerManager: Waiting for region servers count to settle; currently checked in 0, slept for 0 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms. 2018-07-16 20:09:20,078 INFO [B.defaultRpcServer.handler=5,queue=2,port=37346] master.ServerManager: Registering server=master,51571,1531742959688 2018-07-16 20:09:20,088 INFO [RS:0;master:51571] hfile.CacheConfig: Allocating LruBlockCache size=97.47 MB, blockSize=64 KB 2018-07-16 20:09:20,097 INFO [RS:0;master:51571] hfile.CacheConfig: Created cacheConfig: blockCache=LruBlockCache{blockCount=0, currentSize=60888, freeSize=102149056, maxSize=102209944, heapSize=60888, minSize=97099448, minFactor=0.95, multiSize=48549724, multiFactor=0.5, singleSize=24274862, singleFactor=0.25}, cacheDataOnRead=true, cacheDataOnWrite=false, cacheIndexesOnWrite=false, cacheBloomsOnWrite=false, cacheEvictOnClose=false, cacheDataCompressed=false, prefetchOnOpen=false 2018-07-16 20:09:20,123 INFO [RS:0;master:51571] wal.WALFactory: Instantiating WALProvider of type class org.apache.hadoop.hbase.wal.DefaultWALProvider 2018-07-16 20:09:20,123 INFO [master:37346.activeMasterManager] master.ServerManager: Waiting for region servers count to settle; currently checked in 1, slept for 105 ms, expecting minimum of 1, maximum of 2147483647, timeout of 4500 ms, interval of 1500 ms. 2018-07-16 20:09:20,139 INFO [RS:0;master:51571] wal.FSHLog: WAL configuration: blocksize=32 MB, rollsize=30.40 MB, prefix=master%2C51571%2C1531742959688.default, suffix=, logDir=file:/usr/local/app/hbase-1.2/data/WALs/master,51571,1531742959688, archiveDir=file:/usr/local/app/hbase-1.2/data/oldWALs 2018-07-16 20:09:24,981 INFO [master:37346.activeMasterManager] master.RegionStates: Transition {d196d9d271d0ab1b388757dd95e061c9 state=OPEN, ts=1531742964981, server=master,40181,1531740756070} to {d196d9d271d0ab1b388757dd95e061c9 state=OFFLINE, ts=1531742964981, server=master,40181,1531740756070} regionserver.HRegionServer: master,51571,1531742959688-MemstoreFlusherChore requesting flush of hbase:meta,,1.1588230740 because info has an old edit so flush to free WALs after random delay 30410ms ree WALs after random delay 42302ms 2018-07-16 20:18:15,580 INFO [MemStoreFlusher.0] regionserver.HRegion: Flushing 1/1 column families, memstore=3.89 KB 2018-07-16 20:18:15,612 INFO [MemStoreFlusher.0] regionserver.DefaultStoreFlusher: Flushed, sequenceid=207, memsize=3.9 K, hasBloomFilter=false, into tmp file file:/usr/local/app/hbase-1.2/data/data/hbase/meta/1588230740/.tmp/e4ad28e038974eed91b4ce9b9b3ddb0a 2018-07-16 20:29:20,097 INFO [LruBlockCacheStatsExecutor] hfile.LruBlockCache: totalSize=1.30 MB, freeSize=96.18 MB, max=97.47 MB, blockCount=27, accesses=58, hits=31, hitRatio=53.45%, , cachingAccesses=58, cachingHits=31, cachingHitsRatio=53.45%, evictions=119, evicted=0, evictedPerRun=0.0 2018-07-16 20:29:57,015 INFO [SyncThread:0] server.ZooKeeperServer: Established session 0x164a2feb4680007 with negotiated timeout 40000 for client /192.168.204.1:53452 2018-07-16 20:30:06,968 INFO [ProcessThread(sid:0 cport:-1):] server.PrepRequestProcessor: Processed session termination for sessionid: 0x164a2feb4680007 e018-07-16 20:30:06,970 INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181] server.NIOServerCnxn: Closed socket connection for client /192.168.204.1:53452 which had sessionid 0x164a2feb4680007

JSP页面显示是空白的,没有报错,是代码有问题吗?还是环境

<%@page import="com.atoz.survey.po.Login"%> <%@page import="com.atoz.survey.po.Paper"%> <%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%> <% String path = request.getContextPath(); String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"; %> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <base href="<%=basePath%>"> <title>iWen-个人中心</title> <meta http-equiv="pragma" content="no-cache"> <meta http-equiv="cache-control" content="no-cache"> <meta http-equiv="expires" content="0"> <meta http-equiv="keywords" content="keyword1,keyword2,keyword3"> <meta http-equiv="description" content="This is my page"> <link rel="stylesheet" href="css/bootstrap.min.css"> <link rel="stylesheet" href="css/bootstrap-responsive.min.css"> <style type="text/css"> body { padding-top: 20px; padding-bottom: 40px; } .container1{ width:960px; margin:auto; } /*内容部分*/ .maincontent{ margin-top:40px; height:auto; } .right-button{ border-width:3px; border-color:red; margin:0; padding:30px 0px 0px 3px; } .buttonspace{ margin-top:15px; padding:20px 0px 0px 3px; } /*热门推荐等格式*/ .marketing p + h4 { margin-top: 28px; } .nav-pills > li > a { padding-top: 2px; } .fabu a { color: #FFFFFF; text-decoration: none; } </style> <!--[if lt IE 9]> <script src="js/html5shiv.js"></script> <![endif]--> <script src="js/jquery.js"></script> <script src="js/bootstrap.min.js"></script> </head> <% int showPage = 1; String showPageInt = request.getParameter("showPage"); if (showPageInt != null) { showPage = Integer.parseInt(showPageInt); } List<Paper> papers = (List<Paper>) session.getAttribute("papers"); Login login = (Login) session.getAttribute("loginInfo"); int showcurrentPage = 0; int remainCount = 0; int endLineCount = 0; int pageSize = 10; if (papers != null || login != null) { int pageAllCount = 0; //total counts if (showPage == 0) { showPage = 1; } pageAllCount = papers.size(); showcurrentPage = (showPage - 1) * pageSize; //起始处下标 remainCount = pageAllCount - showcurrentPage; //剩余的条数 if (remainCount > 10) { endLineCount = showcurrentPage + 10; //截止下标 } else { endLineCount = pageAllCount; } %> <div class="container1"> <div class="masthead"> <ul class="nav nav-pills pull-right"> <li>当前登录:<%=login.getUserName() %></li> <% if(login.isAdmin()){ %> <li>&nbsp;</li> <li><a href="admin.jsp">后台管理</a></li> <% } %> </ul> <h1><a href="index.jsp">iWen</a></h1> </div> <hr> <div class="maincontent"> <div class="row-fluid"> <div class="span10"> <table class="table table-striped table-hover"> <thead> <tr> <th>问卷标题</th> <th>发布日期</th> <th>回答次数</th> <th>查看结果</th> </tr> </thead> <tbody> <% for(int i = showcurrentPage; i < endLineCount; i++){ Paper paper = papers.get(i); %> <tr> <td><a href="surveyPage?paperId=<%=paper.getPaperId() %>" ><%=paper.getPaperTitle() %></a></td> <td><%=paper.getPaperStartDate() %></td> <td><%=paper.getPaperCount() %></td> <td><a href="showresult.jsp?paperId=<%=paper.getPaperId() %>" class="btn btn-small">查看结果</a></td> <td><a href="deletePage?paperId=<%=paper.getPaperId() %>" class="btn btn-small btn-danger">删除</a></td> </tr> <% } %> </tbody> </table> </div> <div class="span2"> <div class="right-button"> <div class="row"> <div class="span2"></div> <div class="span8 fabu"><a href="addpaper.jsp" class="btn btn-success">发布问卷</a></div> <div class="span2"></div> </div> </div> </div> </div> <div class="row"> <div class="span10"> <ul class="pager"> <% if(showPage != 1){ %> <li><a href="home.jsp?showPage=<%=(showPage-1) %>">前一页</a></li> <% }else{ %> <li class="disabled"><a href="home.jsp?showPage=<%=(showPage-1) %>">前一页</a></li> <% } %> <li><a href="home.jsp?showPage=<%=(showPage+1) %>">后一页</a></li> </ul> </div> </div> </div> </div> <% } %> </html> ``` ```

为什么tomcat的catalina.log日志中,没有把控制台所有的信息都记录下来

如题,控制台报错,打印出了异常信息,但是到logs目录下打开catalina.log文件查看却没有记录,这是什么原因 而且以前我见过日志里出现过异常信息,是同一个tomcat,也是同样的环境,没有修改过配置

登陆界面的用户名id怎么传到后面让其他页面可以用?我改的不起作用

login.jsp <%@page import="org.apache.tomcat.util.descriptor.web.LoginConfig"%> <%@page import="com.sun.java.swing.plaf.windows.resources.windows"%> <%@page import="javax.servlet.jsp.tagext.TryCatchFinally"%> <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="java.sql.*" %> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>用户登录</title> </head> <body> <!-- 统一编码 --> <% request.setCharacterEncoding("UTF-8"); response.setCharacterEncoding("UTF-8"); %> <!-- 连接数据库 --> <%! String driver="com.mysql.jdbc.Driver"; int i=0;//测试数据库是否存在该用户 Connection conn =null; PreparedStatement ps=null; ResultSet rs=null; String url="jdbc:mysql://127.0.0.1:3306/Hit_DB"; String user="root"; String password="12345678"; String sql="select user_name,user_password from user_table"; %> <!-- 按六步法完成业务处理 --> <% try{ String user_name1=request.getParameter("username"); String user_password1=request.getParameter("password11"); /* session.setAttribute("uname",user_name1); */ String user_name2=null; String user_password2=null; Class.forName(driver); conn=DriverManager.getConnection(url, user, password); ps=(PreparedStatement)conn.prepareStatement(sql); rs=ps.executeQuery(); while(rs.next()){ user_name2=rs.getString(1); user_password2=rs.getString(2); if(user_name1.equals(user_name2)&&user_password1.equals(user_password2)){ request.getRequestDispatcher("index.html").forward(request,response); i=1; } } if(i==0){ out.println("<script>alert('请重新登录!');window.history.back(-1);</script>"); } i=0; String username = request.getParameter("user_name1"); }catch(SQLException e){ out.print("数据库异常!"); }finally{ } %> <%-- <% String name=request.getParameter("user_name1"); session.setAttribute("uname", name); %> --%> <!-- 关闭对象 --> <% if(rs!=null){ rs.close(); } if(ps!=null){ ps.close(); } if(conn!=null){ conn.close(); } %> </body> </html> person.jsp <%@page import="com.sun.xml.internal.txw2.Document"%> <%@page import="javax.websocket.Session"%> <%@page import="org.apache.catalina.connector.Request"%> <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@page import="java.sql.*" %> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <meta http-equiv="X-UA-Compatible" content="ie=edge" /> <link rel="stylesheet" type="text/css" href="css/bootstrap.min.css" /> <link rel="stylesheet" type="text/css" href="css/person.css" /> <title>个人页面</title> </head> <body> <%! //定义全局变量 String driver="com.mysql.jdbc.Driver"; String url="jdbc:mysql://127.0.0.1:3306/Hit_DB"; String user="root"; String password="12345678"; /* String username=null; */ String sql="select * from user_table where user_name=?"; Connection conn=null; PreparedStatement ps=null; ResultSet rs=null; %> <% //设置编码,防止乱码现象 request.setCharacterEncoding("UTF-8"); response.setCharacterEncoding("UTF-8"); %> <% try{ /* String uname=(String)session.getAttribute("uname"); */ String uname = request.getParameter("username"); /* String name=new String(session.getAttribute("name").toString().getBytes("ISO-8859-1"),"UTF-8"); */ Class.forName(driver); conn=DriverManager.getConnection(url,user,password); ps=conn.prepareStatement(sql); ps.setString(1,uname); rs=ps.executeQuery(); /* String users=request.getParameter("username"); */ }catch(SQLException e){ out.print("无法查询!"); } %> <!--导航栏--> <nav class="navbar navbar-inverse navbar-fixed-top"> <div class="container"> <div class="navbar-header"> <a href="index.html" class="navbar-brand logo"><img src="images/logo1.png" /></a> <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar-collapse"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> </div> <div class="collapse navbar-collapse" id="navbar-collapse"> <ul class="nav navbar-nav navbar-right"> <li class="nav-li"> <a href="index.html" class="active"><span class="glyphicon glyphicon-home"></span> 首页</a> </li> <li class="nav-li"> <a href="information.html"><span class="glyphicon glyphicon-list"></span> 资讯</a> </li> <li class="nav-li"> <a href="case.html"><span class="glyphicon glyphicon-fire"></span>打卡小明星</a> </li> <li class="nav-li"> <a href="about.html"><span class="glyphicon glyphicon-question-sign"></span> 关于</a> </li> <li> <div class="dropdown hidden-xs"> <img src="images/avatar.jpg" class="dropdown-toggle avatar" data-toggle="dropdown"> <ul class="dropdown-menu"> <li><a href="person.html">个人中心</a></li> <li><a href="CircleOfFriends.html">朋友圈</a></li> <li><a href="massage.html">消息</a></li> <li><a href="published-topics.html">发表</a></li> <li><a href="#">设置</a></li> <li class="divider"></li> <li><a href="xxx">退出</a></li> </ul> </div> </li> </ul> </div> </div> </nav> <!----> <div class="head"> <div class="container"> <div class="row"> <div class="col-md-2 hidden-xs"> <img src="images/avatar.jpg" class="img-circle head-portrait" /> </div> <div class="col-md-10 head-num"> <div class="info"> <strong class="username"> <% sql="select user_nickname,user_sex,user_email from user_table where user_name=?"; conn=null; ps=null; rs=null; %> <% try{ String uname = request.getParameter("username"); conn=DriverManager.getConnection(url,user,password); ps=conn.prepareStatement(sql); ps.setString(1,uname); rs=ps.executeQuery(); while(rs.next()){ String nick=rs.getString("user_nickname"); out.print(nick); } /* String users=request.getParameter("username"); */ }catch(SQLException e){ out.print("无法查询!"); } %> </strong> </div> login.jsp是跳转到index.html这个主界面的,然后从主界面跳转到person.jsp个人界面,个人界面从数据库传数据要用到登陆界面的用户名。。。。

oracle10G 提示找不到SID

# tnsnames.ora Network Configuration File: F:\soft\oracle\network\admin\tnsnames.ora # Generated by Oracle configuration tools. TEST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = test.com.cn) ) ) EXTPROC_CONNECTION_DATA = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) ) (CONNECT_DATA = (SID = PLSExtProc) (PRESENTATION = RO) ) ) 上面是文件里的内容 下面是我的代码,我是才开始学习ORACLE看视频和网上搜。身边没有能直接请教的人。所以请知道的朋友一定告知一下。 listener ,serviceTEST 这两个都已启动。 package com.test.jdbc; import java.sql.Connection; import java.sql.DriverManager; public class Jdbc { Connection conn=null; public Connection conn(){ try { try { Class.forName("oracle.jdbc.driver.OracleDriver").newInstance(); } catch (Exception e) { // TODO: handle exception e.printStackTrace(); } conn=DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:test", "system", "y"); System.out.println("fasd"); } catch (Exception e) { // TODO: handle exception e.printStackTrace(); } return conn; } public static void main(String[] args) { Jdbc j=new Jdbc(); j.conn(); } } 报错: java.sql.SQLException: Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor The Connection descriptor used by the client was: localhost:1521:test at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:124) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:279) at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:318) at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:343) at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:147) at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:31) at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:545) at java.sql.DriverManager.getConnection(Unknown Source) at java.sql.DriverManager.getConnection(Unknown Source) at com.test.jdbc.Jdbc.conn(Jdbc.java:16) at com.test.jdbc.Jdbc.main(Jdbc.java:26) 另外。在安装的过程中:CSSERVICE 是失败的。现在CS 也没有启动。 也出现过OCR无法初始化 我是XP系统。不愿换。 我只有:30分。 全放上来。 [b]问题补充:[/b] 把localhost改成本地IP,再看看test.com.cn对不对。 因为我的安装不熟练。 至此只能用system登陆。 然后。test.com.cn test 我都换过了。没效果。提示都是一样的。 [b]问题补充:[/b] 系统能登陆, SQL 语句都能使用。 这几天在学PROCEDURE TRRIGER 都用得蛮好。 只是现在不知为啥 突然一下子,SQLPLUS在运行窗口又用不成了。 提示找不到文件。 但是从程序里运行SQLPLUS可以。只是那样没有缓存区。有些要重复写的东西很是麻烦。 [b]问题补充:[/b] 你的 SERVICE_NAME应该写为test,这个才是数据库的服务名称 前面的TEST 只是在pl/sql连接时,本地显示的名称而已,不一定是数据库的SID的 这个是我当初时。学着视频里写的。。。。写的名称就是test.com.cn 然后。当时安装界面上就显示 SID是test 可是在JDBC里搞不定— [b]问题补充:[/b] 把localhost改成本地IP,再看看test.com.cn对不对。 本地IP不知道怎么设———— 不过。我上百度搜一哈。 先试试看 [b]问题补充:[/b] tnsnames.ora listener.ora 这两块儿。 基本上和帖图的那个朋友是一样。 应该没什么问题。 到是有关test.com.cn这样设名字。好不好确实值得研究。 可那视频就是这么教的。 我现在都不知道该怎么改。 有点不敢重装。 因为重装要删除的东西还蛮多的……………………………… [b]问题补充:[/b] Io 异常: The Network Adapter could not establish the connection 因为我的CMD命令用不了。 所以没法用IPCONFIG这些方式看IP。 用 改成HOST=您的IP(比如192.168.1.102) 另外WINDOWS/system32\drivers\etc\下的hosts文件可以参考一下.. 这里显示的是 127.0.0.1 localhost 但是里面又说:# for example: # # 102.54.94.97 rhino.acme.com # source server # 38.25.63.10 x.acme.com # x client host # 以下都是在2006-2007年恶意修改IE属性,或者传播病毒或者木马的网站 127.0.0.1 localhost 127.0.0.1 858656.com 127.0.0.1 my123.com 127.0.0.1 8749.com 127.0.0.1 4199.com 127.0.0.1 7379.com 127.0.0.1 7255.com 127.0.0.1 3448.com 127.0.0.1 7939.com 127.0.0.1 8009.com 127.0.0.1 piaoxue.com 127.0.0.1 kzdh.com 127.0.0.1 about.blank.la 127.0.0.1 6781.com 127.0.0.1 7322.com 127.0.0.1 9991.com 所以———好像用:hosts文件里的内容没用啊。 我填了127.0.0.1 替代localhost 就提示io异常。 另外。我的oracle已经重做了。 数据库全名是 # tnsnames.ora Network Configuration File: C:\oracle\product\10.1.0\Db_1\network\admin\tnsnames.ora # Generated by Oracle configuration tools. TEST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 0.1.0.5)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = test) ) ) EXTPROC_CONNECTION_DATA = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) ) (CONNECT_DATA = (SID = PLSExtProc) (PRESENTATION = RO) ) ) # listener.ora Network Configuration File: C:\oracle\product\10.1.0\Db_1\network\admin\listener.ora # Generated by Oracle configuration tools. SID_LIST_LISTENER = (SID_LIST = (SID_DESC = (SID_NAME = PLSExtProc) (ORACLE_HOME = C:\oracle\product\10.1.0\Db_1) (PROGRAM = extproc) ) ) LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) ) (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = 0.1.0.5)(PORT = 1521)) ) ) ) [b]问题补充:[/b] 以前我的服务里有LISTEN 的。 刚才我开SERVICES。MSC里面居然没有了。 难道是我删除了path,里面两条关于jre1.4的信息引起的? 我有备份可以还原。打算还原试试看。 [b]问题补充:[/b] 我痛下决心:已将系统完全重装, 在重装的过程中。先装ORACLE 10G, 再装JDK, 再装tomcat+eclipse +myeclipse 再装iis 再装sql server2005 再装瑞星并升级。 这次oracle任何错误也不报了。浏览器模式也能用了。 格老子的。所有的启动都正常了。 可是tomcat报靠说8080被占用。 于是改了connctor 为8010 然后发现 eclipse执行不了main命令。 又是新的轮回啊——————从七点开始,晚饭都没吃。靠— [b]问题补充:[/b] eclipse 是因为被oracle的jre1.4误导了。 其实我在path已经删除了他。 可是他还是在eclipse干扰到我了。 不管怎么样。eclipse现在正常。 十分钟时间 如果oracle ,sql server2005,mysql5.1 连接jdbc正常的话。 我就算大功告成了(虽然又出现了新BUG,oracle 在sqlplus里正常登陆,在网页登陆去说我用户名和密错误……) 肚子好饿— [b]问题补充:[/b] 这个— 反正至此。 所以连接全部OK。 曾经不能使用的debug也能正常使用了。 JDBC连接三个数据库也都正常了。 数据库自已运行速度也非常了得! 只是开机40个线程看着有点儿头疼。不过,不怕我3G内存 1.8双核顶得住。 非常感谢这几天关注本案的朋友。 特别是最后一直有关第的ROWEN 只是这分不知道该派给谁好。 分拿出来总得花吧。不花对不起大家———— ROWEN您就受累接着吧。 再次感谢关注和帮助我的朋友。感谢!

struts2 装入包含检查是否登录的拦截器锥后,.jsp_Service()出现异常

我设置检查用户是否登录的包后,所有需要加载数据的页面出现是空白页面 2014-6-8 1:07:53 org.apache.catalina.core.StandardWrapperValve invoke 严重: Servlet.service() for servlet jsp threw exception java.lang.NullPointerException at org.apache.jsp.user.deleteuser_jsp._jspService(deleteuser_jsp.java:185) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at crm.filter.EncodingFilter.doFilter(EncodingFilter.java:17) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:88) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) at java.lang.Thread.run(Thread.java:619) struts.xml <?xml version="1.0" encoding="GBK"?> <!DOCTYPE struts PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 2.3//EN" "http://struts.apache.org/dtds/struts-2.3.dtd"> <struts> <!--指定Spring框架的自动装配模式 --> <constant name="struts.objectFactory.spring.autoWrite " value="name"></constant> <constant name="struts.i18.encoding" value="GBK"></constant> <package name="common" namespace="/" extends="struts-default"> <action name="login" class="crm.web.struts.action.LoginAction"> <result name="success">/index.jsp</result> <result name="fail">/error.jsp</result> <result name="input">/user/login.jsp</result> </action> </package> <package name="struts" namespace="/" extends="struts-default"> <!-- 设置该包的默认拦截器 --> <interceptors> <interceptor name="loginInterceptor" class="crm.web.interceptor.LoginInterceptor"/> <interceptor name="authorityInterceptor" class="crm.web.interceptor.AuthorityInterceptor"/> <interceptor-stack name="myDefaultInterceptorStack"> <interceptor-ref name="loginInterceptor"/> <interceptor-ref name="defaultStack"/> </interceptor-stack> </interceptors> <default-interceptor-ref name="myDefaultInterceptorStack"/> <global-results> <result name="login" type="redirect">/user/login.jsp</result> </global-results> <action name="cancellation" class="crm.web.struts.action.CancellationAction"> <result name="success" type="redirect">/user/login.jsp</result> <result name="error" type="redirect">/error.jsp</result> </action> <action name="charge" class="crm.web.struts.action.ChargeAction"> <result name="success">/index.jsp</result> <result name="input" type="redirect">/pay/charge.jsp</result> <result name="error">/error.jsp</result> </action> <action name="payAction" class="crm.web.struts.action.PayAction"> <result name="success">/index.jsp</result> <result name="input" type="redirect">/pay/pay.jsp</result> <result name="error">/error.jsp</result> </action> deleteuserjsp页面 </head> <body > <s:action name="loadMemberList!pageOfDelete" namespace="/" ></s:action> <%ArrayList list=(ArrayList)request.getAttribute("list"); Iterator it=list.iterator(); int i=0; Member m[]=new Member[5]; while(it.hasNext()){ m[i++]=(Member)it.next(); if(i==5){break;} } %> <s:url id="toLastPage" action="memberList!pageOfDelete" namespace="/" > <s:param name="pageType" value="-1"></s:param> </s:url> <s:url id="toNextPage" action="memberList!pageOfDelete" namespace="/" > <s:param name="pageType" value="1"></s:param> </s:url> <div class="twelve columns header_nav"> <div class="leftdiv" style="color:#FF4500;font-size:15px"><span>尊敬的<%=((User)session.getAttribute("currentUser")).getUserName()%>你好,</span><a href="<%=path%>/cancellation">退出</a></div> <div class="row"> <ul id="menu-header" class="nav-bar horizontal"> <li class="active"><a href="../index.jsp">Home</a></li> <li class="has-flyout"> <a href="#">会员信息管理</a><a href="#" class="flyout-toggle"></a> <ul class="flyout"><!-- Flyout Menu --> <li class="has-flyout"><a href="./adduser.jsp">会员信息增加</a></li> <li class="has-flyout"><a href="./deleteuser.jsp">会员信息删除</a></li> <li class="has-flyout"><a href="./alteruser.jsp">会员信息修改</a></li> </ul> </li><!-- END Flyout Menu --> <li class="has-flyout"> <a href="#">消息推送</a><a href="#" class="flyout-toggle"></a> <ul class="flyout"><!-- Flyout Menu --> <li class="has-flyout"><a href="../send/addsend.jsp">创建推送</a></li> <li class="has-flyout"><a href="../send/deletesend.jsp">删除推送</a></li> </ul> </li> <li class="has-flyout"> <a href="#">权限管理</a><a href="#" class="flyout-toggle"></a> <ul class="flyout"><!-- Flyout Menu --> <li class="has-flyout"><a href="../worker/addworker.jsp">增加收用户</a></li> <li class="has-flyout"><a href="../worker/deleteworker.jsp">删除用户</a></li> </ul> </li> <li class="has-flyout"> <a href="#">充值缴费</a><a href="#" class="flyout-toggle"></a> <ul class="flyout"><!-- Flyout Menu --> <li class="has-flyout"><a href="../pay/charge.jsp">充值</a></li> <li class="has-flyout"><a href="../pay/pay.jsp">缴费</a></li> </ul> </li> </ul> <script type="text/javascript"> //<![CDATA[ $('ul#menu-header').nav-bar(); //]]> </script> </div> </div> <section class="section_light"> <div class="row"><form method="post" action=""> <table class="table table-striped" > <thead> <tr> <th> 编号 </th> <th> 会员名 </th> <th> 卡号 </th> <th> 余额 </th> </tr> </thead> <tbody> <tbody> <tr> <td> 1 </td> <td> <%if(m[0]!=null){out.print(m[0].getName());}%> </td> <td> <%if(m[0]!=null){out.print(m[0].getId());}%> </td> <td> <%if(m[0]!=null){out.print(m[0].getOverage());}%> </td> </tr> <tr class="success"> <td> 2 </td> <td> <%if(m[1]!=null){out.print(m[1].getName());}%> </td> <td> <%if(m[1]!=null){out.print(m[1].getId());}%> </td> <td> <%if(m[1]!=null){out.print(m[1].getOverage());}%> </td> </tr> <tr class="error"> <td> 3 </td> <td> <%if(m[2]!=null){out.print(m[2].getName());}%> </td> <td> <%if(m[2]!=null){out.print(m[2].getId());}%> </td> <td> <%if(m[2]!=null){out.print(m[2].getOverage());}%> </td> </tr> <tr class="warning"> <td> 4 </td> <td> <%if(m[3]!=null){out.print(m[3].getName());}%> </td> <td> <%if(m[3]!=null){out.print(m[3].getId());}%> </td> <td> <%if(m[3]!=null){out.print(m[3].getOverage());}%> </td> </tr> <tr class="info"> <td> 5 </td> <td> <%if(m[4]!=null){out.print(m[4].getName());}%> </td> <td> <%if(m[4]!=null){out.print(m[4].getId());}%> </td> <td> <%if(m[4]!=null){out.print(m[4].getOverage());}%> </td> </tr> </tbody> </table></form> </div><div class="row"> <div style="float:left ;position:relative; left:30%;"><a href="<%=path%>/memberList!pageOfDelete?page_Type=-1"><img src="../images/last.jpg" width="81" height="26" /></a></div> <div style="float:left ; position:relative; left:50%;"><a href="<%=path%>/memberList!pageOfDelete?page_Type=1"><img src="../images/next.jpg" width="81" height="26" /></a></div> </div></br></br></br><div class="row"> <table ><form method="post" action="<%=path%>/deleteMember"> <tr> <td ><span>会员名</span> </td> <td ><div> <input name="name" type="text" id="huiyuanming" style="height:28px;width:267px;outline:none; vertical-align:middle;" /> </div></td> <td ><span>卡号</span> </td> <td ><div> <input name="id" type="text" id="kahao" style="height:28px;width:267px;outline:none; vertical-align:middle;" /> </div> </td> <td> <td colspan="2"><div align="center"><input name="deleteuse" type="submit" value="" style="border:none;background:url('../images/delete.jpg') left top no-repeat;width:81px; height:26px;" /></div></td> </td></tr></form> </table> </div></div> </section>

自定义ContentProvider,书上这个代码怎么改?

DataBaseHelpe.java ``` package com.example.definecontentprovider; import android.content.Context; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper; import android.util.Log; public class DataBaseHelpe extends SQLiteOpenHelper{ public static final String DB_NAME="userdb.db"; public static final String TABLENAME="userinfo"; public static final int DB_VERSION=1; public static final String CREATETABLE="create table"+TABLENAME+"(_id integer primary key,username text,userpassword text);"; public DataBaseHelpe(Context context) { super(context,DB_NAME,null,DB_VERSION); } public void onCreate(SQLiteDatabase db) { db.execSQL(CREATETABLE); } public void onUpgrade(SQLiteDatabase db,int oldVersion,int newVersion) { Log.i("Database update......","Update database from"+oldVersion+"to"+newVersion); db.execSQL("drop table if it exists"+TABLENAME); onCreate(db); } } ``` MainActivity.java ``` package com.example.definecontentprovider; import android.app.Activity; import android.content.ContentResolver; import android.content.ContentUris; import android.content.ContentValues; import android.database.Cursor; import android.net.Uri; import android.os.Bundle; import android.util.Log; import android.view.Menu; import android.view.MenuItem; public class MainActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); ContentResolver cr=getContentResolver(); //增加记录 ContentValues values=new ContentValues(); values.put("username","admin"); values.put("userpassword","123456"); cr.insert(UserProvider.CONTENT_URI, values); values.clear(); values.put("username","zhangsan"); values.put("userpassword","666666"); cr.insert(UserProvider.CONTENT_URI, values); //查询所有记录 Cursor cursor=cr.query(UserProvider.CONTENT_URI, null, null, null, null); Log.i("after inserted","-------------------------"); while(cursor.moveToNext()){ Log.i("after inserted","id:"+cursor.getString(0)+"username:"+cursor.getString(1)+"userpassword:"+cursor.getString(2)); } cursor.close(); //修改记录 values.clear(); values.put("username","lisi"); //构建的Uri为:"content://com.chapt6.userprovider/userinfo/2" Uri uri=ContentUris.withAppendedId(UserProvider.CONTENT_URI,2); //修改id为2的记录 cr.update(uri, values, null, null); //查询id为2的记录 cursor=cr.query(uri, null, null, null, null); Log.i("after updated","-------------------------"); while(cursor.moveToNext()){ Log.i("after updated","id:"+cursor.getString(0)+"username:"+cursor.getString(1)+"userpassword:"+cursor.getString(2)); } cursor.close(); //删除id为2的记录 cr.delete(uri, null, null); //查询记录 cursor=cr.query(UserProvider.CONTENT_URI, null, null, null, null); Log.i("after deleted","-------------------------"); while(cursor.moveToNext()){ Log.i("after deleted","id:"+cursor.getString(0)+"username:"+cursor.getString(1)+"userpassword:"+cursor.getString(2)); } cursor.close(); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.main, menu); return true; } @Override public boolean onOptionsItemSelected(MenuItem item) { // Handle action bar item clicks here. The action bar will // automatically handle clicks on the Home/Up button, so long // as you specify a parent activity in AndroidManifest.xml. int id = item.getItemId(); if (id == R.id.action_settings) { return true; } return super.onOptionsItemSelected(item); } } ``` UserProvider.java ``` package com.example.definecontentprovider; import android.content.ContentProvider; import android.content.ContentUris; import android.content.ContentValues; import android.content.UriMatcher; import android.database.Cursor; import android.database.sqlite.SQLiteDatabase; import android.net.Uri; public class UserProvider extends ContentProvider{ private DataBaseHelper dbh=null; //发布Content Provider的Uri地址 private static final String AUTHORITY="com.chapt6.userprovider"; public static final Uri CONTENT_URI=Uri.parse("content://com.chapt6.userprovider/userinfo"); //注册需要匹配的Uri private static UriMatcher uriMatcher=new UriMatcher(UriMatcher.NO_MATCH); static { uriMatcher.addURI(AUTHORITY, "userinfo",1); uriMatcher.addURI(AUTHORITY, "userinfo/#",2); } //该方法在ContentProvider创建后就会被调用,在其他应用第一次访问它时才会被创建 public boolean onCreate(){ dbh=new DataBaseHelper(getContext()); return false; } //该方法用于返回当前Uri所代表数据的MIME类型 public String getType(Uri uri){ switch (uriMatcher.match(uri)){ case 1: return "vnd.android.cursor.dir/userinfo"; case 2: return "vnd.android.cursor.item/userinfo"; } return null; } //该方法用于供外部应用从ContentProvider删除数据 public int delete(Uri uri,String selection,String[] selectionArgs){ SQLiteDatabase db=dbh.getWritableDatabase(); int num=0; switch(uriMatcher.match(uri)){ case 1: num=db.delete("userinfo",selection,selectionArgs); break; case 2: long id=ContentUris.parseId(uri); if(selection==null){ selection="_id="+id; } else{ selection="_id="+id+" and ("+selection+")"; } num=db.delete("userinfo",selection,selectionArgs); break; default: break; } getContext().getContentResolver().notifyChange(uri, null); return num; } //该方法用于供外部应用往ContentProvider添加数据 public Uri insert(Uri uri,ContentValues values){ SQLiteDatabase db=dbh.getWritableDatabase(); long id=db.insert("userinfo", null, values); if(id>-1)//插入数据成功 {//构建新插入行的Uri Uri insertUri=ContentUris.withAppendedId(CONTENT_URI, id); //通知所有的观察者,数据集已经改变 getContext().getContentResolver().notifyChange(insertUri, null); return insertUri; } return null; } //该方法用于供外部应用从ContentProvider中获取数据 public Cursor query(Uri uri,String[] projection,String selection,String[] selectionArgs,String sortOrder){ SQLiteDatabase db=dbh.getReadableDatabase(); Cursor cursor=null; switch(uriMatcher.match(uri)){ case 1: cursor=db.query("userinfo",//表名 null,//列的数组,null代表所有列 selection,//where条件 selectionArgs,//where条件的参数值的数组 null,//分组 null,//having sortOrder);//排序规则 break; case 2: long id=ContentUris.parseId(uri); if(selection==null){ selection="_id="+id; } else{ selection="_id="+id+" and ("+selection+")"; } cursor=db.query("userinfo", null, selection, selectionArgs, null, null, sortOrder); break; default: break; } return cursor; } //该方法用于供外部应用更新ContentProvider中的数据 public int update(Uri uri,ContentValues values,String selection,String[] selectionArgs){ SQLiteDatabase db=dbh.getWritableDatabase(); int num=0; switch(uriMatcher.match(uri)){ case 1: num=db.update("userinfo",values,selection,selectionArgs); break; case 2: long id=ContentUris.parseId(uri); //在selection上增加条件_id=id if(selection==null){ selection="_id="+id; } else{ selection="_id="+id+" and ("+selection+")"; } num=db.update("userinfo",values,selection,selectionArgs); break; default: break; } getContext().getContentResolver().notifyChange(uri, null); return num; } } ``` AndroidManifest.xml ``` <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.definecontentprovider" android:versionCode="1" android:versionName="1.0" > <uses-sdk android:minSdkVersion="8" android:targetSdkVersion="21" /> <application android:allowBackup="true" android:icon="@drawable/ic_launcher" android:label="@string/app_name" android:theme="@style/AppTheme" > <activity android:name=".MainActivity" android:label="@string/app_name" > <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> <provider android:name=".UserProvider" android:authorities=".userprovider" android:exported="true"> </provider> </application> </manifest> ``` ![图片说明](https://img-ask.csdn.net/upload/201611/30/1480465682_288883.jpg) ![图片说明](https://img-ask.csdn.net/upload/201611/30/1480465698_552314.jpg) ![图片说明](https://img-ask.csdn.net/upload/201611/30/1480465719_835043.jpg)

在中国程序员是青春饭吗?

今年,我也32了 ,为了不给大家误导,咨询了猎头、圈内好友,以及年过35岁的几位老程序员……舍了老脸去揭人家伤疤……希望能给大家以帮助,记得帮我点赞哦。 目录: 你以为的人生 一次又一次的伤害 猎头界的真相 如何应对互联网行业的「中年危机」 一、你以为的人生 刚入行时,拿着傲人的工资,想着好好干,以为我们的人生是这样的: 等真到了那一天,你会发现,你的人生很可能是这样的: ...

程序员请照顾好自己,周末病魔差点一套带走我。

程序员在一个周末的时间,得了重病,差点当场去世,还好及时挽救回来了。

C++(数据结构与算法)78:---分而治之

一、分而治之的思想 分而治之方法与软件设计的模块化方法非常相似 分而治之通常不用于解决问题的小实例,而要解决一个问题的大实例。一般步骤为: ①把一个大实例分为两个或多个更小的实例 ②分别解决每个小实例 ③把这些小实例的解组合成原始大实例的解 二、实际应用之找出假币 问题描述 一个袋子有16个硬币,其中只有一个是假币,这个假币比其他的真币重量轻(其他所有真币的重量都是相同的)...

springboot+jwt实现token登陆权限认证

一 前言 此篇文章的内容也是学习不久,终于到周末有时间码一篇文章分享知识追寻者的粉丝们,学完本篇文章,读者将对token类的登陆认证流程有个全面的了解,可以动态搭建自己的登陆认证过程;对小项目而已是个轻量级的认证机制,符合开发需求;更多精彩原创内容关注公主号知识追寻者,读者的肯定,就是对作者的创作的最大支持; 二 jwt实现登陆认证流程 用户使用账号和面发出post请求 服务器接受到请求后使用私...

技术大佬:我去,你写的 switch 语句也太老土了吧

昨天早上通过远程的方式 review 了两名新来同事的代码,大部分代码都写得很漂亮,严谨的同时注释也很到位,这令我非常满意。但当我看到他们当中有一个人写的 switch 语句时,还是忍不住破口大骂:“我擦,小王,你丫写的 switch 语句也太老土了吧!” 来看看小王写的代码吧,看完不要骂我装逼啊。 private static String createPlayer(PlayerTypes p...

win10暴力查看wifi密码

刚才邻居打了个电话说:喂小灰,你家wifi的密码是多少,我怎么连不上了。 我。。。 我也忘了哎,就找到了一个好办法,分享给大家: 第一种情况:已经连接上的wifi,怎么知道密码? 打开:控制面板\网络和 Internet\网络连接 然后右击wifi连接的无线网卡,选择状态 然后像下图一样: 第二种情况:前提是我不知道啊,但是我以前知道密码。 此时可以利用dos命令了 1、利用netsh wlan...

女程序员,为什么比男程序员少???

昨天看到一档综艺节目,讨论了两个话题:(1)中国学生的数学成绩,平均下来看,会比国外好?为什么?(2)男生的数学成绩,平均下来看,会比女生好?为什么?同时,我又联想到了一个技术圈经常讨...

副业收入是我做程序媛的3倍,工作外的B面人生是怎样的?

提到“程序员”,多数人脑海里首先想到的大约是:为人木讷、薪水超高、工作枯燥…… 然而,当离开工作岗位,撕去层层标签,脱下“程序员”这身外套,有的人生动又有趣,马上展现出了完全不同的A/B面人生! 不论是简单的爱好,还是正经的副业,他们都干得同样出色。偶尔,还能和程序员的特质结合,产生奇妙的“化学反应”。 @Charlotte:平日素颜示人,周末美妆博主 大家都以为程序媛也个个不修边幅,但我们也许...

MySQL数据库面试题(2020最新版)

文章目录数据库基础知识为什么要使用数据库什么是SQL?什么是MySQL?数据库三大范式是什么mysql有关权限的表都有哪几个MySQL的binlog有有几种录入格式?分别有什么区别?数据类型mysql有哪些数据类型引擎MySQL存储引擎MyISAM与InnoDB区别MyISAM索引与InnoDB索引的区别?InnoDB引擎的4大特性存储引擎选择索引什么是索引?索引有哪些优缺点?索引使用场景(重点)...

如果你是老板,你会不会踢了这样的员工?

有个好朋友ZS,是技术总监,昨天问我:“有一个老下属,跟了我很多年,做事勤勤恳恳,主动性也很好。但随着公司的发展,他的进步速度,跟不上团队的步伐了,有点...

我入职阿里后,才知道原来简历这么写

私下里,有不少读者问我:“二哥,如何才能写出一份专业的技术简历呢?我总感觉自己写的简历太烂了,所以投了无数份,都石沉大海了。”说实话,我自己好多年没有写过简历了,但我认识的一个同行,他在阿里,给我说了一些他当年写简历的方法论,我感觉太牛逼了,实在是忍不住,就分享了出来,希望能够帮助到你。 01、简历的本质 作为简历的撰写者,你必须要搞清楚一点,简历的本质是什么,它就是为了来销售你的价值主张的。往深...

程序员写出这样的代码,能不挨骂吗?

当你换槽填坑时,面对一个新的环境。能够快速熟练,上手实现业务需求是关键。但是,哪些因素会影响你快速上手呢?是原有代码写的不够好?还是注释写的不够好?昨夜...

带了6个月的徒弟当了面试官,而身为高级工程师的我天天修Bug......

即将毕业的应届毕业生一枚,现在只拿到了两家offer,但最近听到一些消息,其中一个offer,我这个组据说客户很少,很有可能整组被裁掉。 想问大家: 如果我刚入职这个组就被裁了怎么办呢? 大家都是什么时候知道自己要被裁了的? 面试软技能指导: BQ/Project/Resume 试听内容: 除了刷题,还有哪些技能是拿到offer不可或缺的要素 如何提升面试软实力:简历, 行为面试,沟通能...

优雅的替换if-else语句

场景 日常开发,if-else语句写的不少吧??当逻辑分支非常多的时候,if-else套了一层又一层,虽然业务功能倒是实现了,但是看起来是真的很不优雅,尤其是对于我这种有强迫症的程序"猿",看到这么多if-else,脑袋瓜子就嗡嗡的,总想着解锁新姿势:干掉过多的if-else!!!本文将介绍三板斧手段: 优先判断条件,条件不满足的,逻辑及时中断返回; 采用策略模式+工厂模式; 结合注解,锦...

!大部分程序员只会写3年代码

如果世界上都是这种不思进取的软件公司,那别说大部分程序员只会写 3 年代码,恐怕就没有程序员这种职业。

离职半年了,老东家又发 offer,回不回?

有小伙伴问松哥这个问题,他在上海某公司,在离职了几个月后,前公司的领导联系到他,希望他能够返聘回去,他很纠结要不要回去? 俗话说好马不吃回头草,但是这个小伙伴既然感到纠结了,我觉得至少说明了两个问题:1.曾经的公司还不错;2.现在的日子也不是很如意。否则应该就不会纠结了。 老实说,松哥之前也有过类似的经历,今天就来和小伙伴们聊聊回头草到底吃不吃。 首先一个基本观点,就是离职了也没必要和老东家弄的苦...

2020阿里全球数学大赛:3万名高手、4道题、2天2夜未交卷

阿里巴巴全球数学竞赛( Alibaba Global Mathematics Competition)由马云发起,由中国科学技术协会、阿里巴巴基金会、阿里巴巴达摩院共同举办。大赛不设报名门槛,全世界爱好数学的人都可参与,不论是否出身数学专业、是否投身数学研究。 2020年阿里巴巴达摩院邀请北京大学、剑桥大学、浙江大学等高校的顶尖数学教师组建了出题组。中科院院士、美国艺术与科学院院士、北京国际数学...

为什么你不想学习?只想玩?人是如何一步一步废掉的

不知道是不是只有我这样子,还是你们也有过类似的经历。 上学的时候总有很多光辉历史,学年名列前茅,或者单科目大佬,但是虽然慢慢地长大了,你开始懈怠了,开始废掉了。。。 什么?你说不知道具体的情况是怎么样的? 我来告诉你: 你常常潜意识里或者心理觉得,自己真正的生活或者奋斗还没有开始。总是幻想着自己还拥有大把时间,还有无限的可能,自己还能逆风翻盘,只不是自己还没开始罢了,自己以后肯定会变得特别厉害...

男生更看重女生的身材脸蛋,还是思想?

往往,我们看不进去大段大段的逻辑。深刻的哲理,往往短而精悍,一阵见血。问:产品经理挺漂亮的,有点心动,但不知道合不合得来。男生更看重女生的身材脸蛋,还是...

为什么程序员做外包会被瞧不起?

二哥,有个事想询问下您的意见,您觉得应届生值得去外包吗?公司虽然挺大的,中xx,但待遇感觉挺低,马上要报到,挺纠结的。

当HR压你价,说你只值7K,你该怎么回答?

当HR压你价,说你只值7K时,你可以流畅地回答,记住,是流畅,不能犹豫。 礼貌地说:“7K是吗?了解了。嗯~其实我对贵司的面试官印象很好。只不过,现在我的手头上已经有一份11K的offer。来面试,主要也是自己对贵司挺有兴趣的,所以过来看看……”(未完) 这段话主要是陪HR互诈的同时,从公司兴趣,公司职员印象上,都给予对方正面的肯定,既能提升HR的好感度,又能让谈判气氛融洽,为后面的发挥留足空间。...

面试:第十六章:Java中级开发

HashMap底层实现原理,红黑树,B+树,B树的结构原理 Spring的AOP和IOC是什么?它们常见的使用场景有哪些?Spring事务,事务的属性,传播行为,数据库隔离级别 Spring和SpringMVC,MyBatis以及SpringBoot的注解分别有哪些?SpringMVC的工作原理,SpringBoot框架的优点,MyBatis框架的优点 SpringCould组件有哪些,他们...

早上躺尸,晚上干活:硅谷科技公司这么流行迟到?

硅谷科技公司上班时间OPEN早已不是什么新鲜事,早九晚五是常态,但有很多企业由于不打卡,员工们10点、11点才“姗姗来迟”的情况也屡见不鲜。 这种灵活的考勤制度为人羡慕,甚至近年来,国内某些互联网企业也纷纷效仿。不过,硅谷普遍弹性的上班制度是怎么由来的呢?这种“流行性迟到”真的有那么轻松、悠哉吗? 《动态规划专题班》 课程试听内容: 动态规划的解题要领 动态规划三大类 求最值/计数/可行性 常...

面试阿里p7,被按在地上摩擦,鬼知道我经历了什么?

面试阿里p7被问到的问题(当时我只知道第一个):@Conditional是做什么的?@Conditional多个条件是什么逻辑关系?条件判断在什么时候执...

Python爬虫,高清美图我全都要(彼岸桌面壁纸)

爬取彼岸桌面网站较为简单,用到了requests、lxml、Beautiful Soup4

无代码时代来临,程序员如何保住饭碗?

编程语言层出不穷,从最初的机器语言到如今2500种以上的高级语言,程序员们大呼“学到头秃”。程序员一边面临编程语言不断推陈出新,一边面临由于许多代码已存在,程序员编写新应用程序时存在重复“搬砖”的现象。 无代码/低代码编程应运而生。无代码/低代码是一种创建应用的方法,它可以让开发者使用最少的编码知识来快速开发应用程序。开发者通过图形界面中,可视化建模来组装和配置应用程序。这样一来,开发者直...

面试了一个 31 岁程序员,让我有所触动,30岁以上的程序员该何去何从?

最近面试了一个31岁8年经验的程序猿,让我有点感慨,大龄程序猿该何去何从。

大三实习生,字节跳动面经分享,已拿Offer

说实话,自己的算法,我一个不会,太难了吧

程序员垃圾简历长什么样?

已经连续五年参加大厂校招、社招的技术面试工作,简历看的不下于万份 这篇文章会用实例告诉你,什么是差的程序员简历! 疫情快要结束了,各个公司也都开始春招了,作为即将红遍大江南北的新晋UP主,那当然要为小伙伴们做点事(手动狗头)。 就在公众号里公开征简历,义务帮大家看,并一一点评。《启舰:春招在即,义务帮大家看看简历吧》 一石激起千层浪,三天收到两百多封简历。 花光了两个星期的所有空闲时...

Java岗开发3年,公司临时抽查算法,离职后这几题我记一辈子

前几天我们公司做了一件蠢事,非常非常愚蠢的事情。我原以为从学校出来之后,除了找工作有测试外,不会有任何与考试有关的事儿。 但是,天有不测风云,公司技术总监、人事总监两位大佬突然降临到我们事业线,叫上我老大,给我们组织了一场别开生面的“考试”。 那是一个风和日丽的下午,我翘着二郎腿,左手端着一杯卡布奇诺,右手抓着我的罗技鼠标,滚动着轮轴,穿梭在头条热点之间。 “淡黄的长裙~蓬松的头发...

立即提问
相关内容推荐