Skip to main content
WuKongIM supports smooth upgrades, ensuring service continuity and data security.

Description

WuKongIM’s version numbering follows the major.minor.patch format, for example 1.0.0. When the patch number increases, it indicates bug fixes or minor feature updates; when the minor version increases, it indicates new features; when the major version increases, it indicates incompatible API changes. Therefore, as long as you don’t upgrade major versions, the upgrade process is smooth.
Version Compatibility:
  • Patch updates (e.g., 2.0.1 → 2.0.2): Always safe, includes bug fixes and minor improvements
  • Minor updates (e.g., 2.0.x → 2.1.x): Generally safe, includes new features with backward compatibility
  • Major updates (e.g., 2.x.x → 3.x.x): May include breaking changes, requires careful planning

Upgrade Steps

1. Check Current Version

First, check your current WuKongIM version:
Before upgrading, it’s recommended to backup your data:

3. Update Docker Compose Configuration

Modify the image field of the wukongim service in docker-compose.yml to the new version. For example:

4. Pull New Image

Use the following command to get the latest image:

5. Restart Services

6. Verify Upgrade

After restart, verify the upgrade was successful:

Rolling Upgrade for Clusters

For cluster deployments, perform rolling upgrades to maintain service availability:

1. Upgrade One Node at a Time

2. Verify Cluster Health

Upgrade Strategies

Blue-Green Deployment

For critical production environments, consider blue-green deployment:
  1. Prepare Green Environment: Set up a new environment with the new version
  2. Data Sync: Ensure data is synchronized between blue and green environments
  3. Switch Traffic: Update load balancer to point to green environment
  4. Verify: Confirm everything works correctly
  5. Cleanup: Remove blue environment after successful verification

Canary Deployment

For gradual rollout:
  1. Deploy to Subset: Upgrade only a portion of nodes
  2. Monitor: Watch metrics and logs for issues
  3. Gradual Rollout: Progressively upgrade more nodes
  4. Full Deployment: Complete upgrade once confident

Rollback Procedures

If issues occur during upgrade, you can rollback:

1. Quick Rollback

2. Data Rollback (if needed)

Upgrade Checklist

Pre-Upgrade

  • Check current version and target version compatibility
  • Review release notes for breaking changes
  • Create data backup
  • Plan maintenance window
  • Notify users of potential downtime
  • Prepare rollback plan

During Upgrade

  • Monitor system resources
  • Watch application logs
  • Verify service health endpoints
  • Test critical functionality
  • Monitor cluster status (for multi-node)

Post-Upgrade

  • Verify version upgrade successful
  • Test all major features
  • Monitor performance metrics
  • Check data integrity
  • Update documentation
  • Clean up old backups (after verification period)

Troubleshooting

Common Issues

Container fails to start after upgrade:
Data migration issues:
Cluster nodes out of sync:

Recovery Steps

  1. Stop services: docker-compose stop
  2. Restore backup: Restore from backup created before upgrade
  3. Revert configuration: Use previous docker-compose.yml
  4. Restart: docker-compose up -d
  5. Verify: Confirm system is working correctly

Best Practices

Planning

  • Test in staging: Always test upgrades in a staging environment first
  • Read release notes: Understand what changes are included
  • Schedule maintenance: Plan upgrades during low-traffic periods
  • Communicate: Inform stakeholders about planned maintenance

Execution

  • Monitor closely: Watch logs and metrics during upgrade
  • Upgrade gradually: For clusters, upgrade one node at a time
  • Verify thoroughly: Test all critical functionality after upgrade
  • Keep backups: Maintain backups until upgrade is fully verified

Automation

Consider automating upgrades for consistency:

Next Steps

Monitoring Setup

Set up monitoring for upgraded system

Performance Tuning

Optimize performance after upgrade

Best Practices

Backup strategies and best practices

Cluster Management

Learn about cluster scaling and management