dubbo RPCcontext 分析
MongoDB实现case when 和 id in的查询
1 | db.store.aggregate([{ |
放回 当groupIds集合中包含1000 返回auth=true
$cond 判断表达式文档
https://docs.mongodb.com/v3.2/meta/aggregation-quick-reference/#expressions
它有下面几种表达式判断
Boolean Expressions
$and $or 用于表达式嵌套
result: { $and: [ { $gt: [ “$qty”, 100 ] }, { $lt: [ “$qty”, 250 ] } ] }
Set Expressions
判断集合是否包含 $setIsSubset
ComparisonExpressions
$eq $gt
Arithmetic Expressions
用来做计算$abs $floor
String Expressions
字符串运算
$concat $substr
Text Search expressions
$meta
Array Expressions
$size
Date Expressions
等等
JavaAPI实现
1 | BasicDBObject bson = new BasicDBObject(); |
Servlet笔记
HttpServletRequest
GET http://localhost:8080/test?a=1
request.getRequestURL();
request.getRequestURI();
/test
request.getQueryString();
a=1