Version 0.2.0
This commit is contained in:
parent
312b985229
commit
26376eaaec
43 changed files with 4699 additions and 2668 deletions
29
pappyproxy/schema/schema_5.py
Normal file
29
pappyproxy/schema/schema_5.py
Normal file
|
@ -0,0 +1,29 @@
|
|||
from pappyproxy import http
|
||||
from twisted.internet import defer
|
||||
|
||||
"""
|
||||
Schema v5
|
||||
|
||||
Description:
|
||||
Adds a column to the requests table which will store a dict that plugins can
|
||||
use to store metadata about requests.
|
||||
"""
|
||||
|
||||
update_queries = [
|
||||
"""
|
||||
ALTER TABLE requests ADD COLUMN plugin_data TEXT;
|
||||
""",
|
||||
|
||||
"""
|
||||
UPDATE requests SET plugin_data="{}";
|
||||
""",
|
||||
|
||||
"""
|
||||
UPDATE schema_meta SET version=5;
|
||||
"""
|
||||
]
|
||||
|
||||
@defer.inlineCallbacks
|
||||
def update(dbpool):
|
||||
for query in update_queries:
|
||||
yield dbpool.runQuery(query)
|
Loading…
Add table
Add a link
Reference in a new issue