|
Server : Apache System : Linux cvar2.toservers.com 3.10.0-962.3.2.lve1.5.73.el7.x86_64 #1 SMP Wed Aug 24 21:31:23 UTC 2022 x86_64 User : njnconst ( 1116) PHP Version : 8.4.18 Disable Function : NONE Directory : /opt/alt/python37/lib/python3.7/site-packages/ssa/__pycache__/ |
Upload File : |
B
��cZ
� @ s� d dl Z d dlZd dlZd dlmZmZ d dlmZmZmZm Z m
Z
mZmZm
Z
d dlmZ d dlmZ d dlmZ dZdZe� ZG d d
� d
e�Zdd� Zd
d� Zdd� Zdd� Zdd� Zddd�Zejed�dd��ZdS )� N)�datetime� timedelta)�Column�Boolean�DateTime�Integer�String�
create_engine�event�func)�declarative_base)� Inspector)�Sessionz/var/lve/ssa.db� c @ s� e Zd ZdZdZeedd�Zeeddd�Z eeddd�Z
eedd�Zeedd�Zee
dd�Zee
dd�Zeedd�Zeedd�Zee
dd�Zeedd�e�� d �Zeedd�e�� e�� d
�ZdS )�
RequestResultay
Describes processed request stored in database file.
E.g.
{
"timestamp": "1650008727",
"url": "http://mydomain.com/index.php",
"duration": 162077,
"hitting_limits": false,
"throttled_time": 0,
"io_throttled_time": 0,
"wordpress": true
}
Note: created_at, updated_at is saved in local TZ format
Z
scrape_resultT)Zprimary_keyF)�index�nullable)r )�timezone)�server_default)Zonupdater N)�__name__�
__module__�__qualname__�__doc__Z
__tablename__r r �idr �domain�path� timestamp�durationr �is_slow_request�hitting_limits�throttled_time�io_throttled_time� wordpressr r �now�
created_atZ
updated_at� r% r% �7/opt/alt/python37/lib/python3.7/site-packages/ssa/db.pyr "