摘要:
Dockerfile config.txt scrapyd.conf docker-compose.yml 阅读全文
摘要:
抄自:pytrends 阅读全文
摘要:
1,创建项目 目录结构 定义Items 编辑items.py 编辑pipelines.py 编写爬虫 spiders/weibo_com.py 修改Setting.py 执行爬虫 阅读全文
摘要:
#!/bin/bash function scandir() { local cur_dir parent_dir workdir workdir=$1 cd ${workdir} if [ ${workdir} = "/" ] then cur_dir="" else cur_dir=$(pwd) fi ... 阅读全文
摘要:
面试题,当时写了一个漏洞百出,被人鄙视了,所以回来用一上午写了一个,自己测试了一下,好像还可以。 思路 如中文数字 阅读全文
摘要:
//入参$in1 = '2017-01-01'; //必填$in2 = '2017-08-01'; //必填$in3 = ''; //选填 $tns = '(DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 0.0.0.0)(PORT = 1521)) 阅读全文
摘要:
副本 实例1 m1.config port=27017 #端口 replSet=spock #副本名称随便取 dbpath=/usr/local/mongodb/fuben/db1 #数据存放目录 logpath=/usr/local/mongodb/fuben/log1/mongodb.log # 阅读全文
摘要:
固定集合(适用于记录日志) 固定集合需要事先创建好,而且它的大小是固定的.当固定集合被占满时,如果再插入新文档,固定集合会自动将最老的文档从集合中删除。 固定集合的文档数量不能超过文档数量限制,固定集合的大小也不能超过大小限制。已首先到达限制为准。 创建固定集合 db.createCollectio 阅读全文
摘要:
创建索引 db.users.ensureIndex({'username':1}) 内嵌文档索引 db.users.ensureIndex({'addr.City':1}) 数组索引 db.users.ensureIndex({'subject.data':1}) 联合索引 db.users.ens 阅读全文
摘要:
简单命令 mongo --nodb 不指定链接数据库 conn = new Mongo(" some-host: 30000") db = conn.getDB(" myDB") 链接数据库 db.help() 查看帮助 db.foo.update 查看update使用方法 function (qu 阅读全文