Skip to main content

Monitoring

Deployxa provides comprehensive monitoring for your applications, including real-time metrics, logs, health checks, alerts, and auto-scaling.

Overview

Monitoring features include:

  • Metrics: CPU, RAM, bandwidth, requests
  • Logs: Build, runtime, error logs
  • Health Checks: Automatic health monitoring
  • Alerts: Configurable notifications
  • Auto-Scaling: Automatic resource scaling
  • Analytics: Performance insights

Metrics

CPU Metrics

Metrics tracked:

  • CPU usage percentage
  • CPU cores allocated
  • CPU throttling
  • CPU load average

View CPU metrics:

  1. Go to ProjectAnalytics
  2. Select "CPU" tab
  3. View real-time data
  4. Check historical trends

Alert thresholds:

  • Warning: 70% CPU usage
  • Critical: 90% CPU usage

RAM Metrics

Metrics tracked:

  • RAM usage (MB)
  • RAM allocated (MB)
  • Memory pressure
  • Swap usage

View RAM metrics:

  1. Go to ProjectAnalytics
  2. Select "Memory" tab
  3. View real-time data
  4. Check historical trends

Alert thresholds:

  • Warning: 70% RAM usage
  • Critical: 90% RAM usage

Bandwidth Metrics

Metrics tracked:

  • Incoming bandwidth
  • Outgoing bandwidth
  • Total bandwidth
  • Bandwidth rate

View bandwidth metrics:

  1. Go to ProjectAnalytics
  2. Select "Bandwidth" tab
  3. View real-time data
  4. Check historical trends

Alert thresholds:

  • Warning: 80% of plan limit
  • Critical: 95% of plan limit

Request Metrics

Metrics tracked:

  • Total requests
  • Requests per second
  • Requests by status code
  • Requests by endpoint
  • Request duration

View request metrics:

  1. Go to ProjectAnalytics
  2. Select "Requests" tab
  3. View real-time data
  4. Check historical trends

Key metrics:

  • 2xx: Successful requests
  • 3xx: Redirects
  • 4xx: Client errors
  • 5xx: Server errors

Response Time Metrics

Metrics tracked:

  • Average response time
  • P50 (median) latency
  • P95 latency
  • P99 latency
  • Slowest endpoints

View response time metrics:

  1. Go to ProjectAnalytics
  2. Select "Performance" tab
  3. View real-time data
  4. Check historical trends

Alert thresholds:

  • Warning: P95 > 1000ms
  • Critical: P95 > 3000ms

Logs

Build Logs

Build logs show the deployment process:

Includes:

  • Git clone process
  • Dependency installation
  • Build commands
  • Container creation
  • Deployment process

View build logs:

  1. Go to ProjectDeployments
  2. Click on a deployment
  3. Click "Build Logs"
  4. View log output

Log levels:

  • INFO: General information
  • WARN: Warnings
  • ERROR: Errors
  • DEBUG: Debug information

Runtime Logs

Runtime logs show application output:

Includes:

  • Application output
  • Request logs
  • Error messages
  • Performance metrics
  • Custom logs

View runtime logs:

  1. Go to ProjectLogs
  2. Select "Runtime" tab
  3. View real-time logs
  4. Filter by level

Log streaming:

  • Real-time streaming
  • Pause/resume
  • Search and filter
  • Download logs

Error Logs

Error logs show application errors:

Includes:

  • Application errors
  • Stack traces
  • Error frequency
  • Error patterns
  • Error trends

View error logs:

  1. Go to ProjectLogs
  2. Select "Errors" tab
  3. View error list
  4. Analyze error patterns

Error tracking:

  • Error frequency
  • Error trends
  • Error grouping
  • Error resolution

Log Management

Search logs:

# Search for specific text
error
timeout
database

# Search by level
level:error
level:warn

# Search by time range
time:1h
time:24h
time:7d

Filter logs:

  • By log level
  • By time range
  • By source
  • By keyword

Download logs:

  1. Go to ProjectLogs
  2. Click "Download"
  3. Select format (txt, json)
  4. Select time range
  5. Click "Download"

Log retention:

  • Free: 7 days
  • Pro: 30 days
  • Enterprise: 90 days

Health Checks

Automatic Health Checks

Deployxa automatically monitors your application:

Check frequency:

  • Every 30 seconds
  • Continuous monitoring
  • Instant detection

Check method:

  • HTTP GET request
  • Timeout: 10 seconds
  • Expected: 2xx status code

Health endpoints:

  • Default: /
  • Custom: Configure in settings

Health Check Configuration

Custom health endpoint:

  1. Go to ProjectSettingsHealth
  2. Enter health endpoint (e.g., /health)
  3. Set timeout (default: 10s)
  4. Set expected status (default: 200)
  5. Click "Save"

Example health endpoint:

// Express.js
app.get('/health', (req, res) => {
res.status(200).json({
status: 'healthy',
timestamp: new Date().toISOString()
});
});
# Flask
@app.route('/health')
def health():
return jsonify({
'status': 'healthy',
'timestamp': datetime.now().isoformat()
}), 200
// Laravel
Route::get('/health', function () {
return response()->json([
'status' => 'healthy',
'timestamp' => now()->toISOString()
]);
});

Health Check Status

Healthy:

  • Application is running
  • Health check passing
  • All systems operational

Unhealthy:

  • Application not responding
  • Health check failing
  • Issues detected

Degraded:

  • Application partially working
  • Some checks failing
  • Performance issues

Health Check Actions

Automatic actions:

  • Restart container on failure
  • Send alert notifications
  • Log health check failures
  • Update status dashboard

Manual actions:

  • View health history
  • Check health logs
  • Restart application
  • Contact support

Alerts

Alert Types

Metric Alerts:

  • CPU usage
  • RAM usage
  • Bandwidth usage
  • Error rate
  • Response time

Health Alerts:

  • Application down
  • Health check failed
  • Container crashed
  • Deployment failed

Billing Alerts:

  • Usage threshold
  • Budget exceeded
  • Payment failed
  • Invoice due

Creating Alerts

  1. Go to ProjectSettingsAlerts
  2. Click "Create Alert"
  3. Select alert type
  4. Configure threshold
  5. Choose notification method
  6. Click "Save"

Example alert:

{
"type": "cpu_usage",
"threshold": 90,
"duration": "5m",
"notification": {
"email": "admin@example.com",
"slack": "#alerts"
}
}

Notification Methods

Email:

  • Instant notifications
  • Detailed information
  • Action links

Slack:

  • Real-time notifications
  • Channel integration
  • Rich formatting

Webhook:

  • Custom integrations
  • JSON payload
  • Retry logic

SMS:

  • Critical alerts only
  • Short messages
  • Enterprise only

Alert Configuration

Thresholds:

  • Warning threshold
  • Critical threshold
  • Duration (time above threshold)
  • Cooldown period

Notification settings:

  • Notification channels
  • Notification frequency
  • Escalation rules
  • Quiet hours

Alert History

View alert history:

  1. Go to ProjectAlerts
  2. Click "History"
  3. View all alerts
  4. Filter by type
  5. Export data

Alert information:

  • Alert type
  • Trigger time
  • Resolution time
  • Duration
  • Notification sent

Auto-Scaling

Horizontal Scaling

Automatically add/remove containers:

Scaling triggers:

  • CPU usage
  • RAM usage
  • Request count
  • Custom metrics

Scaling limits:

  • Minimum containers
  • Maximum containers
  • Scale-up threshold
  • Scale-down threshold

Configuration:

  1. Go to ProjectSettingsScaling
  2. Enable auto-scaling
  3. Set minimum containers
  4. Set maximum containers
  5. Configure triggers
  6. Click "Save"

Example configuration:

{
"enabled": true,
"minContainers": 2,
"maxContainers": 10,
"triggers": [
{
"metric": "cpu_usage",
"threshold": 70,
"action": "scale_up"
},
{
"metric": "cpu_usage",
"threshold": 30,
"action": "scale_down"
}
]
}

Vertical Scaling

Automatically adjust resources:

Scaling triggers:

  • CPU usage
  • RAM usage
  • Performance metrics

Resource limits:

  • Minimum CPU/RAM
  • Maximum CPU/RAM
  • Increment size
  • Cooldown period

Configuration:

  1. Go to ProjectSettingsResources
  2. Enable auto-scaling
  3. Set resource limits
  4. Configure triggers
  5. Click "Save"

Scale-to-Zero

Automatically scale to zero when idle:

Benefits:

  • Cost savings
  • Resource efficiency
  • Automatic wake-up

Configuration:

  1. Go to ProjectSettingsScaling
  2. Enable scale-to-zero
  3. Set idle timeout (default: 15 minutes)
  4. Configure wake-up triggers
  5. Click "Save"

Wake-up triggers:

  • HTTP request
  • Scheduled task
  • Manual trigger

Scaling Metrics

View scaling metrics:

  1. Go to ProjectAnalytics
  2. Select "Scaling" tab
  3. View container count
  4. Check scaling events
  5. Analyze trends

Scaling events:

  • Scale-up events
  • Scale-down events
  • Trigger reasons
  • Duration

Analytics

Dashboard Analytics

Overview metrics:

  • Total requests
  • Average response time
  • Error rate
  • Bandwidth usage
  • Active users

View dashboard:

  1. Go to ProjectAnalytics
  2. View overview dashboard
  3. Check key metrics
  4. Analyze trends

Request Analytics

Request breakdown:

  • By endpoint
  • By method (GET, POST, etc.)
  • By status code
  • By time period

View request analytics:

  1. Go to ProjectAnalytics
  2. Select "Requests" tab
  3. View breakdown
  4. Filter by criteria

Performance Analytics

Performance metrics:

  • Response times
  • Latency percentiles
  • Slowest endpoints
  • Performance trends

View performance analytics:

  1. Go to ProjectAnalytics
  2. Select "Performance" tab
  3. View metrics
  4. Identify bottlenecks

Error Analytics

Error breakdown:

  • By error type
  • By endpoint
  • By time period
  • Error trends

View error analytics:

  1. Go to ProjectAnalytics
  2. Select "Errors" tab
  3. View breakdown
  4. Analyze patterns

Exporting Analytics

Export analytics data:

  1. Go to ProjectAnalytics
  2. Click "Export"
  3. Select format (CSV, JSON, PDF)
  4. Select time range
  5. Click "Export"

Performance Optimization

Identify Bottlenecks

Check metrics:

  • CPU usage
  • RAM usage
  • Response times
  • Error rates

Analyze logs:

  • Error logs
  • Performance logs
  • Slow queries

Use analytics:

  • Request analytics
  • Performance analytics
  • Error analytics

Optimize Application

Code optimization:

  • Optimize algorithms
  • Reduce complexity
  • Use caching
  • Minimize I/O

Database optimization:

  • Add indexes
  • Optimize queries
  • Use connection pooling
  • Cache results

Asset optimization:

  • Minify assets
  • Compress images
  • Use CDN
  • Enable caching

Optimize Resources

Right-size containers:

  • Monitor usage
  • Adjust resources
  • Use auto-scaling
  • Avoid over-provisioning

Enable caching:

  • Application cache
  • Database cache
  • CDN cache
  • Browser cache

Use compression:

  • Gzip compression
  • Brotli compression
  • Image compression
  • Asset minification

Troubleshooting

High CPU Usage

Problem: CPU usage consistently high

Solution:

  1. Check analytics for bottlenecks
  2. Review application code
  3. Optimize algorithms
  4. Enable caching
  5. Scale up resources
  6. Consider auto-scaling

High RAM Usage

Problem: RAM usage consistently high

Solution:

  1. Check for memory leaks
  2. Review application code
  3. Optimize data structures
  4. Enable garbage collection
  5. Scale up resources
  6. Consider auto-scaling

Slow Response Times

Problem: Response times are slow

Solution:

  1. Check performance analytics
  2. Identify slow endpoints
  3. Optimize database queries
  4. Enable caching
  5. Use CDN
  6. Optimize application code

Health Check Failing

Problem: Health checks are failing

Solution:

  1. Check health endpoint
  2. Verify endpoint is accessible
  3. Check application logs
  4. Verify timeout settings
  5. Test endpoint manually
  6. Contact support if issue persists

Alerts Not Working

Problem: Alerts not sending notifications

Solution:

  1. Check alert configuration
  2. Verify notification channels
  3. Test notification settings
  4. Check alert history
  5. Verify threshold settings
  6. Contact support if issue persists

Best Practices

Monitoring Setup

✅ Set up health checks ✅ Configure alerts ✅ Monitor key metrics ✅ Review logs regularly ✅ Use analytics

Alert Configuration

✅ Set appropriate thresholds ✅ Use multiple notification channels ✅ Avoid alert fatigue ✅ Test alerts regularly ✅ Document alert procedures

Performance Optimization

✅ Monitor performance regularly ✅ Identify bottlenecks ✅ Optimize code and queries ✅ Use caching ✅ Enable compression

Scaling Strategy

✅ Use auto-scaling ✅ Set appropriate limits ✅ Monitor scaling events ✅ Test scaling behavior ✅ Plan for traffic spikes

Resources


Need Help? Contact support@deployxa.com or join our community Discord.