上传图片到图片服务器,因为域名不同,多以会有跨域问题。 No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://img.xxx.com' is therefore not ...
分类:
Web程序 时间:
2017-05-22 15:04:22
阅读次数:
1048
这可能是两个原因造成的,首先可能是redis的6379端口无法访问,请先在cmd中输入命令 telnet 127.0.0.1 6379 看看可不可以访问redis-server 机器的6379端口,如果不能访问,需要在远程机器关掉防火墙或者添加允许通过 1)使用root用户登录,vi /etc/sy ...
分类:
编程语言 时间:
2017-05-21 01:04:59
阅读次数:
1676
BaseAdapter在调用notifyDataSetChanged()方法后,GridView就刷新了,下面从源码角度对此原理进行剖析。 首先进到BaseAdapter中查看其notifyDataSetChanged()方法,发现它调用了DataSetObservable的notifyChange ...
分类:
移动开发 时间:
2017-05-17 18:24:53
阅读次数:
159
在登录过滤器中。推断请求是ajax请求还是超链接或者地址栏变化的请求 if (httpServletReq.getHeader("x-requested-with") != null && httpServletReq.getHeader("x-requested-with").equalsIgno ...
分类:
编程语言 时间:
2017-05-14 18:47:18
阅读次数:
189
Cannot assign requested address解决办法 apache ab压力测试报错(apr_socket_recv: Connection reset by peer (104)) 报错connect:Cannot assign requested address 按字面意思是不 ...
分类:
其他好文 时间:
2017-05-14 10:47:58
阅读次数:
230
1.八种结束Linux进程的方法: 五种正常终止方式: main函数返回; 调用exit; 调用_exit或_Exit 最后一个线程从其启动例程返回 最后一个线程调用pthread_exit 三种异常终止方式: 调用abort。 接收到一个信号终止; 最后一个线程对取消请求做出响应。 exit函数与 ...
分类:
系统相关 时间:
2017-05-12 13:35:57
阅读次数:
290
Hit: if the data CPU is looking for can not be found in a cache, it constitutes a hit. Miss: cache miss is a state where the data requested by a proce ...
分类:
其他好文 时间:
2017-05-09 12:40:22
阅读次数:
123
commit()的文档官方文档如下:CommityourpreferenceschangesbackfromthisEditortotheSharedPreferencesobjectitisediting.Thisatomicallyperformstherequestedmodifications,replacingwhateveriscurrentlyintheSharedPreferences.Notethatwhentwoeditorsaremodifyingpreferences..
分类:
移动开发 时间:
2017-05-08 14:46:03
阅读次数:
193
git 下的(difftool)和(mergetool)是专门提供给使用者用自己的工具进行diff和merge的命令: 然后直接使用命令进行两次提交的比较和合并: 缺点: 虽然使用git difftool已经基本满足了我的需要,但还有个小问题:如果我要比较两次提交之间的差异时,difftool只能一 ...
分类:
其他好文 时间:
2017-05-04 11:05:48
阅读次数:
388
測试一个简单的TCP套接字程序,client向server请求建立连接然后释放。 在一台主机上同一时候执行两个client时。出现报错“Cannot assign requestedaddress” 将server的请求处理改为3线程的线程池后问题解决。 但同一时候执行的client数量继续添加时, ...
分类:
其他好文 时间:
2017-05-01 20:56:34
阅读次数:
189