{"record":{"id":"b30874b6895eaadd","repo":"ruvnet/ruflo","slug":"resource-not-found-uri","errorCode":null,"errorMessage":"Resource not found: ${uri}","messagePattern":"Resource not found: (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"v3/@claude-flow/mcp/src/resource-registry.ts","lineNumber":174,"sourceCode":"   */\n  async read(uri: string): Promise<ResourceReadResult> {\n    // Check cache first\n    if (this.options.cacheEnabled) {\n      const cached = this.cache.get(uri);\n      if (cached && Date.now() - cached.cachedAt < cached.ttl) {\n        this.logger.debug('Resource cache hit', { uri });\n        return { contents: cached.content };\n      }\n    }\n\n    // Find handler (exact match or template match)\n    let handler = this.handlers.get(uri);\n    if (!handler) {\n      handler = this.findTemplateHandler(uri);\n    }\n\n    if (!handler) {\n      throw new Error(`Resource not found: ${uri}`);\n    }\n\n    const contents = await handler(uri);\n\n    // Cache the result with size limit (LRU eviction)\n    if (this.options.cacheEnabled) {\n      // SECURITY: Enforce max cache size to prevent memory exhaustion\n      if (this.cache.size >= this.options.maxCacheSize) {\n        // Remove oldest entry (first entry in Map iteration order)\n        const oldestKey = this.cache.keys().next().value;\n        if (oldestKey) {\n          this.cache.delete(oldestKey);\n          this.logger.debug('Cache evicted oldest entry', { uri: oldestKey });\n        }\n      }\n\n      this.cache.set(uri, {\n        content: contents,","sourceCodeStart":156,"sourceCodeEnd":192,"githubUrl":"https://github.com/ruvnet/ruflo/blob/fa13ee4ad60ac2090b1480656eb233521790d640/v3/@claude-flow/mcp/src/resource-registry.ts#L156-L192","documentation":"ResourceRegistry.read() found no handler registered for the URI — neither an exact match nor a matching URI template. The read fails as unknown-resource after the cache miss; the URI in the message shows what was requested.","triggerScenarios":"Thrown at v3/@claude-flow/mcp/src/resource-registry.ts:174 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Register the resource under the requested URI before reading it.","Verify the URI spelling and scheme against the registered resource list."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"fa13ee4ad60ac2090b1480656eb233521790d640","analyzedAt":"2026-08-18T21:34:22.708Z","contentChangedAt":"2026-08-18T21:34:22.708Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}