# -*- coding: utf-8 -*-
# Generated by Django 1.11.1 on 2017-05-25 10:42
from __future__ import unicode_literals

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='ProfileLog',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(blank=True, max_length=255, null=True)),
                ('start_time', models.DateTimeField()),
                ('end_time', models.DateTimeField(blank=True, null=True)),
                ('hostname', models.CharField(blank=True, max_length=255, null=True)),
                ('total_requests', models.IntegerField(blank=True, null=True)),
                ('avg_time', models.FloatField(blank=True, null=True)),
                ('total_time', models.FloatField(blank=True, null=True)),
                ('avg_cpu_time', models.FloatField(blank=True, null=True)),
                ('total_user_cpu_time', models.FloatField(blank=True, null=True)),
                ('total_system_cpu_time', models.FloatField(blank=True, null=True)),
                ('avg_sql_time', models.FloatField(blank=True, null=True)),
                ('total_sql_time', models.FloatField(blank=True, null=True)),
                ('avg_sql_queries', models.FloatField(blank=True, null=True)),
                ('total_sql_queries', models.IntegerField(blank=True, null=True)),
                ('avg_cache_hits', models.FloatField(blank=True, null=True)),
                ('total_cache_hits', models.IntegerField(blank=True, null=True)),
                ('avg_cache_misses', models.FloatField(blank=True, null=True)),
                ('total_cache_misses', models.IntegerField(blank=True, null=True)),
            ],
        ),
        migrations.CreateModel(
            name='ProfileLogRecord',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('timestamp', models.DateTimeField(auto_now_add=True)),
                ('request_path', models.CharField(max_length=255)),
                ('ip_address', models.CharField(max_length=255)),
                ('device', models.CharField(max_length=255)),
                ('arguments', models.TextField(default='')),
                ('kw_arguments', models.TextField(default='')),
                ('timer_utime', models.FloatField(blank=True, null=True)),
                ('timer_stime', models.FloatField(blank=True, null=True)),
                ('timer_cputime', models.FloatField(blank=True, null=True)),
                ('timer_total', models.FloatField(blank=True, null=True)),
                ('timer_vcsw', models.IntegerField(blank=True, null=True)),
                ('timer_ivcsw', models.IntegerField(blank=True, null=True)),
                ('sql_num_queries', models.IntegerField(blank=True, null=True)),
                ('sql_time', models.FloatField(blank=True, null=True)),
                ('sql_queries', models.FloatField(blank=True, null=True)),
                ('cache_num_calls', models.IntegerField(blank=True, null=True)),
                ('cache_time', models.FloatField(blank=True, null=True)),
                ('cache_hits', models.IntegerField(blank=True, null=True)),
                ('cache_misses', models.IntegerField(blank=True, null=True)),
                ('cache_sets', models.IntegerField(blank=True, null=True)),
                ('cache_gets', models.IntegerField(blank=True, null=True)),
                ('cache_get_many', models.IntegerField(blank=True, null=True)),
                ('cache_deletes', models.IntegerField(blank=True, null=True)),
                ('cache_calls', models.TextField(default='')),
                ('profile_log', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='profile_log', to='django_web_profiler.ProfileLog')),
            ],
        ),
    ]
