FAQ
Frequently asked questions about mqutils
Frequently Asked Questions
General Questions
Q: Why should I use mqutils instead of individual SDKs?
A: mqutils provides a unified API across 6 major message queue systems, eliminating the need to learn and maintain different APIs for each system. Key benefits include:
- Single learning curve - Learn once, use everywhere
- Consistent error handling - Structured validation across all systems
- Built-in production features - Health monitoring, batch processing, graceful shutdown
- Easy migration - Switch between systems without code changes
- Reduced complexity - One library instead of 6+ different SDKs
Q: Is mqutils production-ready?
A: Yes, absolutely. mqutils is designed for production use with:
- 94% task completion rate
- 50%+ test coverage including integration and acceptance tests
- Comprehensive error handling and validation
- Built-in health monitoring for all systems
- Graceful shutdown mechanisms
- Thread-safe operations with proper synchronization
- Zero production issues reported to date
Q: What message queue systems are supported?
A: mqutils supports 6 major message queue systems:
- AMQP/RabbitMQ - Enterprise messaging with exchanges and routing
- Apache Kafka - Event streaming with consumer groups and partitions
- NATS Core/JetStream - Cloud-native messaging with clustering
- AWS SQS - Cloud-managed queues with FIFO support
- GCP Pub/Sub - Google Cloud messaging with exactly-once delivery
- Redis Pub/Sub & Streams - In-memory messaging with persistence
Q: Can I migrate between different message queue systems?
A: Yes! This is one of mqutils’ key strengths. Migration typically requires only changing the connection URL:
|
|
Your message handlers and application logic remain unchanged.
Performance Questions
Q: What kind of performance can I expect?
A: mqutils is optimized for high performance:
- 100K+ messages/sec peak throughput with batch processing
- <10ms P99 latency for message processing
- Configurable buffers (0-10,000 message channel buffers)
- AMQP channel pooling for resource efficiency
- Batch processing with configurable timeouts
Q: How does batch processing work?
A: Batch processing allows you to process multiple messages together for higher throughput:
|
|
Batch size and timeout are configurable per transport.
Q: Is mqutils thread-safe?
A: Yes, mqutils is designed with thread safety in mind:
- Atomic operations for critical sections
- Proper synchronization mechanisms
- Race condition prevention
- Safe concurrent access to shared resources
Configuration Questions
Q: How do I configure different message queue systems?
A: Configuration is URL-based with automatic system detection:
|
|
Q: Can I use environment variables for configuration?
A: Yes, you can use environment variables or any configuration management system:
|
|
Q: How do I configure SSL/TLS connections?
A: Use the secure URL schemes:
|
|
Troubleshooting
Q: My consumer isn’t receiving messages. What should I check?
A: Follow this troubleshooting checklist:
Verify connection - Check if the consumer can connect to the message broker
1 2
health := consumer.HealthCheck() log.Printf("Health: %s - %s", health.Status(), health.Message())
Check URL format - Ensure the connection URL is correct for your system
Verify handler registration - Make sure your handler is registered before calling
Run()
Check queue/topic exists - Ensure the destination exists in your message broker
Review logs - Look for connection errors or authentication issues
Q: How do I handle connection failures?
A: mqutils provides built-in error handling and reconnection:
|
|
Q: Messages are being processed slowly. How can I improve performance?
A: Try these performance optimizations:
- Enable batch processing for higher throughput
- Increase message buffer size (up to 10,000)
- Use appropriate batch sizes for your use case
- Configure proper timeouts for your message broker
- Monitor resource usage (CPU, memory, network)
|
|
Q: How do I debug message processing issues?
A: Use comprehensive logging and error handling:
|
|
Integration Questions
Q: Can I use mqutils with Docker?
A: Yes, mqutils works perfectly in containerized environments:
|
|
Q: How do I test applications using mqutils?
A: mqutils supports comprehensive testing:
|
|
Q: Can I use mqutils with Kubernetes?
A: Absolutely! mqutils is cloud-native friendly:
|
|
Support and Community
Q: Where can I get help?
A: Multiple support channels are available:
- GitLab Issues: Report bugs and request features
- Documentation: Comprehensive guides and examples
- API Reference: Complete interface documentation
Q: How can I contribute to mqutils?
A: We welcome contributions! Please:
- Fork the repository
- Create a feature branch
- Add tests for your changes
- Ensure all tests pass
- Submit a merge request
See our contributing guidelines for details.
Q: Is mqutils open source?
A: Yes! mqutils is licensed under the MIT License, making it free for both personal and commercial use with no vendor lock-in.
Still Have Questions?
If you can’t find the answer you’re looking for, please:
- Open an issue on GitLab
- Check our examples directory for more use cases
- Review the API documentation for detailed interface information