list_rpop
Remove and return elements from the right end of a Redis list to process queue items or retrieve stored data in order.
Instructions
右侧弹出列表
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | 列表键名 | |
| count | No | 弹出数量(可选) |
Implementation Reference
- src/services/mcpService.ts:1058-1070 (handler)The MCP tool handler for 'list_rpop' that ensures Redis connection and calls rpop on the RedisService with key and optional count.private async handleListRpop(args: any) { this.ensureRedisConnection(); const result = await this.redisService!.rpop(args.key, args.count); return { content: [ { type: 'text', text: JSON.stringify(result, null, 2) } ] }; }
- src/services/mcpService.ts:326-337 (registration)Registration of the 'list_rpop' tool in the ListTools response, including name, description, and input schema.{ name: 'list_rpop', description: '右侧弹出列表', inputSchema: { type: 'object', properties: { key: { type: 'string', description: '列表键名' }, count: { type: 'number', description: '弹出数量(可选)' } }, required: ['key'] } },
- src/services/mcpService.ts:664-665 (registration)Dispatcher case in CallToolRequestSchema handler that routes 'list_rpop' calls to the handleListRpop method.case 'list_rpop': return await this.handleListRpop(args);