你的浏览器禁用了JavaScript, 请开启后刷新浏览器获得更好的体验!
输入关键字进行搜索
搜索:
没有找到相关结果
beyond - imgeek运营
赞同来自: admin 、大帅哥嗨嗨嗨
赞同来自: 大帅哥嗨嗨嗨 、yingzi8544
lizg - ……
赞同来自: 大帅哥嗨嗨嗨
大帅哥嗨嗨嗨
yingzi8544
geekontheway
lengmo
日月双悬
CharlesHe
要回复问题请先登录或注册
31 个回复
beyond - imgeek运营
赞同来自: admin 、大帅哥嗨嗨嗨
beyond - imgeek运营
赞同来自: 大帅哥嗨嗨嗨 、yingzi8544
这是消息保存过程中出问题导致的,这个错误之前缺少监控。
对于这个问题,第一,我们会加强监控,第二,增加针对这种异常,会增加自动修复功能,这个正在开发中,预计近期会上线。
lizg - ……
赞同来自: 大帅哥嗨嗨嗨
beyond - imgeek运营
大帅哥嗨嗨嗨
大帅哥嗨嗨嗨
yingzi8544
大帅哥嗨嗨嗨
大帅哥嗨嗨嗨
queryStrNode.put("limit", 1000L);
queryStrNode.put("ql", "select * where timestamp > 1434604651953 and timestamp < 1434611366774" ); 这样查询有问题吗
geekontheway
lengmo
日月双悬
Response Body: {"error":"unsupported_service_operation","timestamp":1470624721108,"duration":0,"exception":"org.apache.usergrid.services.exceptions.UnsupportedServiceOperationException","error_description":"Service operation not supported"}
[framework] 2016-08-08 10:52:06,433 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -1323 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - ===========Response End===========
Status: 500
Response Body: {"error":"unsupported_service_operation","timestamp":1470624721108,"duration":0,"exception":"org.apache.usergrid.services.exceptions.UnsupportedServiceOperationException","error_description":"Service operation not supported"}
lizg - ……
日月双悬
[framework] 2016-08-08 10:52:06,073 - com.easemob.server.example.comm.TokenGenerator -963 [main] DEBUG com.easemob.server.example.comm.TokenGenerator - New token expires: 5183999000
[framework] 2016-08-08 10:52:06,073 - com.easemob.server.example.comm.TokenGenerator -963 [main] INFO com.easemob.server.example.comm.TokenGenerator - Token has been refreshed with YWMtFC6GmF0TEeaHd10nVZV71QAAAVedDfa9wC6PCQ8wVvRI-LmlyC3gJ_uPJ8M and will be expired at 1475808725073.
[framework] 2016-08-08 10:52:06,074 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -964 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - =============Request=============
[framework] 2016-08-08 10:52:06,074 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -964 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - Method: DELETE
[framework] 2016-08-08 10:52:06,074 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -964 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - URL: https://a1.easemob.com/yue-health/healthchat/chatmessages
[framework] 2016-08-08 10:52:06,074 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -964 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - Header: [Content-Type:application/json] [Authorization:Bearer YWMtFC6GmF0TEeaHd10nVZV71QAAAVedDfa9wC6PCQ8wVvRI-LmlyC3gJ_uPJ8M]
[framework] 2016-08-08 10:52:06,074 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -964 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - Body:
[framework] 2016-08-08 10:52:06,074 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -964 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - Query: [limit:20] [ql:select * where timestamp<1470624725138]
[framework] 2016-08-08 10:52:06,074 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -964 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - ===========Request End===========
[framework] 2016-08-08 10:52:06,432 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -1322 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - =============Response=============
[framework] 2016-08-08 10:52:06,433 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -1323 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - Status: 500
日月双悬
ResponseWrapper chatResponse = (ResponseWrapper)chat.exportChatMessages(20L, null, "select * where timestamp<"+currentTimestamp);
// ResponseWrapper userResponse = (ResponseWrapper)user.getIMUsersByUserName("py0011");
//
// String username = ((ObjectNode) userResponse.getResponseBody()).get("entities").get(0).get("username").asText();
System.out.println(chatResponse);
在main 方法中这样写不知道有没有什么问题?建立用户和获取用户没有问题,但导出聊天记录就报500错误?
lizg - ……
日月双悬
日月双悬
lizg - ……
lengmo
lengmo
//
String nextTimestamp = "1465180245995";
String ql = "select * where timestamp>"+nextTimestamp;
日月双悬
日月双悬
lengmo
日月双悬
lengmo
public class EasemobChatMessage extends EasemobRestAPI implements ChatMessageAPI {
private static final String ROOT_URI = "/chatmessages";
public Object exportChatMessages(Long limit, String cursor, String query) {
String url = getContext().getSeriveURL() + getResourceRootURI();
HeaderWrapper header = HeaderHelper.getDefaultHeaderWithToken();
QueryWrapper queryWrapper = QueryWrapper.newInstance().addQueryLang(query).addLimit(limit).addCursor(cursor);
//匿名类
return getInvoker().sendRequest(HTTPMethod.METHOD_GET, url, header, new BodyWrapper() {
@Override
public Boolean validate() {
// TODO Auto-generated method stub
return true;
}
@Override
public ContainerNode<?> getBody() {
// TODO Auto-generated method stub
return null;
}
}, queryWrapper);
}
CharlesHe
盼尽快解决!!!
日月双悬
[framework] 2016-08-10 14:52:57,331 - com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker -1437 [main] DEBUG com.easemob.server.example.comm.invoker.HttpClientRestAPIInvoker - ===========Response End===========
Status: 200
Response Body: {"action":"get","path":"/chatmessages","uri":"http://a1.easemob.com/yue-health/healthchat/chatmessages","entities":[{"uuid":"f8dde39a-5d10-11e6-b0ba-bbd172df6d03","type":"chatmessage","created":1470623815753,"modified":1470623815753,"timestamp":1470623815112,"from":"admin","msg_id":"227886734652740224","to":"admin","chat_type":"chat","payload":{"bodies":[{"type":"txt","msg":"4444"}]}},{"uuid":"9b4ae4ba-5d12-11e6-a65f-e712cba6acca","type":"chatmessage","created":1470624517755,"modified":1470624517755,"timestamp":1470624517239,"from":"admin","msg_id":"227889750248264084","to":"zhang0011","chat_type":"chat","payload":"{\"from\":\"py0011\",\"to\":\"zhang0011\",\"bodies\":[\"from\":\"py0011\",\"to\":\"zhang0011\",{\"from\":\"py0011\",\"to\":\"zhang0011\",\"type\":\"txt\",\"msg\":\"qqqqqq\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"ext\":{\"from\":\"py0011\",\"to\":\"zhang0011\",\"bodies\":[\"from\":\"py0011\",\"to\":\"zhang0011\",{\"from\":\"py0011\",\"to\":\"zhang0011\",\"type\":\"txt\",\"msg\":\"qqqqqq\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"weichat\":{\"from\":\"py0011\",\"to\":\"zhang0011\",\"bodies\":[\"from\":\"py0011\",\"to\":\"zhang0011\",{\"from\":\"py0011\",\"to\":\"zhang0011\",\"type\":\"txt\",\"msg\":\"qqqqqq\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"originType\":\"webim\"}}}"},{"uuid":"9fbf55da-5d12-11e6-8aa2-4f1b959609c5","type":"chatmessage","created":1470624525229,"modified":1470624525229,"timestamp":1470624524571,"from":"admin","msg_id":"227889781709734292","to":"zhang0011","chat_type":"chat","payload":"{\"from\":\"py0011\",\"to\":\"zhang0011\",\"bodies\":[\"from\":\"py0011\",\"to\":\"zhang0011\",{\"from\":\"py0011\",\"to\":\"zhang0011\",\"type\":\"txt\",\"msg\":\"[:s]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"ext\":{\"from\":\"py0011\",\"to\":\"zhang0011\",\"bodies\":[\"from\":\"py0011\",\"to\":\"zhang0011\",{\"from\":\"py0011\",\"to\":\"zhang0011\",\"type\":\"txt\",\"msg\":\"[:s]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"weichat\":{\"from\":\"py0011\",\"to\":\"zhang0011\",\"bodies\":[\"from\":\"py0011\",\"to\":\"zhang0011\",{\"from\":\"py0011\",\"to\":\"zhang0011\",\"type\":\"txt\",\"msg\":\"[:s]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"originType\":\"webim\"}}}"},{"uuid":"a46425ca-5d12-11e6-af26-df85027162a6","type":"chatmessage","created":1470624533020,"modified":1470624533020,"timestamp":1470624532293,"from":"admin","msg_id":"227889814903456148","to":"admin","chat_type":"chat","payload":"{\"from\":\"py0011\",\"to\":\"admin\",\"bodies\":[\"from\":\"py0011\",\"to\":\"admin\",{\"from\":\"py0011\",\"to\":\"admin\",\"type\":\"txt\",\"msg\":\"6666\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"ext\":{\"from\":\"py0011\",\"to\":\"admin\",\"bodies\":[\"from\":\"py0011\",\"to\":\"admin\",{\"from\":\"py0011\",\"to\":\"admin\",\"type\":\"txt\",\"msg\":\"6666\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"weichat\":{\"from\":\"py0011\",\"to\":\"admin\",\"bodies\":[\"from\":\"py0011\",\"to\":\"admin\",{\"from\":\"py0011\",\"to\":\"admin\",\"type\":\"txt\",\"msg\":\"6666\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"originType\":\"webim\"}}}"},{"uuid":"a662b4ea-5d12-11e6-b5f4-cdfb2018bae8","type":"chatmessage","created":1470624536366,"modified":1470624536366,"timestamp":1470624535923,"from":"admin","msg_id":"227889830426575252","to":"admin","chat_type":"chat","payload":"{\"from\":\"py0011\",\"to\":\"admin\",\"bodies\":[\"from\":\"py0011\",\"to\":\"admin\",{\"from\":\"py0011\",\"to\":\"admin\",\"type\":\"txt\",\"msg\":\"[({)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"ext\":{\"from\":\"py0011\",\"to\":\"admin\",\"bodies\":[\"from\":\"py0011\",\"to\":\"admin\",{\"from\":\"py0011\",\"to\":\"admin\",\"type\":\"txt\",\"msg\":\"[({)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"weichat\":{\"from\":\"py0011\",\"to\":\"admin\",\"bodies\":[\"from\":\"py0011\",\"to\":\"admin\",{\"from\":\"py0011\",\"to\":\"admin\",\"type\":\"txt\",\"msg\":\"[({)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"originType\":\"webim\"}}}"},{"uuid":"bbb1442e-5d12-11e6-83c6-7bb448be4cea","type":"chatmessage","created":1470624572113,"modified":1470624572113,"timestamp":1470624570980,"from":"admin","msg_id":"227889980993700244","to":"py0011","chat_type":"chat","payload":"{\"from\":\"admin\",\"to\":\"py0011\",\"bodies\":[\"from\":\"admin\",\"to\":\"py0011\",{\"from\":\"admin\",\"to\":\"py0011\",\"type\":\"txt\",\"msg\":\"44444[(F)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"ext\":{\"from\":\"admin\",\"to\":\"py0011\",\"bodies\":[\"from\":\"admin\",\"to\":\"py0011\",{\"from\":\"admin\",\"to\":\"py0011\",\"type\":\"txt\",\"msg\":\"44444[(F)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"weichat\":{\"from\":\"admin\",\"to\":\"py0011\",\"bodies\":[\"from\":\"admin\",\"to\":\"py0011\",{\"from\":\"admin\",\"to\":\"py0011\",\"type\":\"txt\",\"msg\":\"44444[(F)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"originType\":\"webim\"}}}"},{"uuid":"bfcf09ce-5d12-11e6-a168-ad46e42aee5e","type":"chatmessage","created":1470624579019,"modified":1470624579019,"timestamp":1470624578681,"from":"admin","msg_id":"227890014095147412","to":"py0011","chat_type":"chat","payload":"{\"from\":\"admin\",\"to\":\"py0011\",\"bodies\":[\"from\":\"admin\",\"to\":\"py0011\",{\"from\":\"admin\",\"to\":\"py0011\",\"type\":\"txt\",\"msg\":\"[(|)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"ext\":{\"from\":\"admin\",\"to\":\"py0011\",\"bodies\":[\"from\":\"admin\",\"to\":\"py0011\",{\"from\":\"admin\",\"to\":\"py0011\",\"type\":\"txt\",\"msg\":\"[(|)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"weichat\":{\"from\":\"admin\",\"to\":\"py0011\",\"bodies\":[\"from\":\"admin\",\"to\":\"py0011\",{\"from\":\"admin\",\"to\":\"py0011\",\"type\":\"txt\",\"msg\":\"[(|)]\"},\"function(val) {\n\tfor (var i = 0; i < this.length; i++) {\n\t\tif (this[i].name == val.name)\n\t\t\treturn i;\n\t}\n\treturn -1;\n}\",\"function(val) {\n\tvar index = this.indexOf(val);\n\tif (index > -1) {\n\t\tthis.splice(index, 1);\n\t}\n}\"],\"originType\":\"webim\"}}}"}],"timestamp":1470811970308,"duration":20,"count":7}
日月双悬
lengmo
日月双悬