__init__.py 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. from __future__ import absolute_import
  2. from .legacy import (
  3. create_message, create_gzip_message,
  4. create_snappy_message, create_message_set,
  5. CODEC_NONE, CODEC_GZIP, CODEC_SNAPPY, ALL_CODECS,
  6. ATTRIBUTE_CODEC_MASK, KafkaProtocol,
  7. )
  8. API_KEYS = {
  9. 0: 'Produce',
  10. 1: 'Fetch',
  11. 2: 'ListOffsets',
  12. 3: 'Metadata',
  13. 4: 'LeaderAndIsr',
  14. 5: 'StopReplica',
  15. 6: 'UpdateMetadata',
  16. 7: 'ControlledShutdown',
  17. 8: 'OffsetCommit',
  18. 9: 'OffsetFetch',
  19. 10: 'FindCoordinator',
  20. 11: 'JoinGroup',
  21. 12: 'Heartbeat',
  22. 13: 'LeaveGroup',
  23. 14: 'SyncGroup',
  24. 15: 'DescribeGroups',
  25. 16: 'ListGroups',
  26. 17: 'SaslHandshake',
  27. 18: 'ApiVersions',
  28. 19: 'CreateTopics',
  29. 20: 'DeleteTopics',
  30. 21: 'DeleteRecords',
  31. 22: 'InitProducerId',
  32. 23: 'OffsetForLeaderEpoch',
  33. 24: 'AddPartitionsToTxn',
  34. 25: 'AddOffsetsToTxn',
  35. 26: 'EndTxn',
  36. 27: 'WriteTxnMarkers',
  37. 28: 'TxnOffsetCommit',
  38. 29: 'DescribeAcls',
  39. 30: 'CreateAcls',
  40. 31: 'DeleteAcls',
  41. 32: 'DescribeConfigs',
  42. 33: 'AlterConfigs',
  43. }