ioredis.d.ts 792 B

1234567891011121314151617181920212223
  1. import { BasePlugin, Span } from '@opencensus/core';
  2. export declare type IgnoreMatcher = string | RegExp;
  3. export declare type IORedisPluginConfig = {
  4. detailedCommands: boolean;
  5. };
  6. export declare type IORedisCommand = {
  7. reject: (err: Error) => void | undefined;
  8. resolve: (result: any) => void | undefined;
  9. promise: Promise<any>;
  10. args: Array<string | Buffer | number>;
  11. callback: Function | undefined;
  12. name: string;
  13. };
  14. export declare class IORedisPlugin extends BasePlugin {
  15. protected options: IORedisPluginConfig;
  16. constructor(moduleName: string);
  17. protected applyPatch(): any;
  18. applyUnpatch(): void;
  19. private getPatchSendCommand;
  20. patchEnd(span: Span, resultHandler: Function): Function;
  21. }
  22. declare const plugin: IORedisPlugin;
  23. export { plugin };