Function at 0x1002dc3b
Capabilities:
Reference sql statements

Disassembly:
push 0x104
mov eax, 0x100afecf
call fcn.100aaeb4
mov edi, ecx
push str.PRAGMA_auto_vacuumFULL
push dword [edi + 0x40]
lea ecx, [ebp - 0x40]
xor ebx, ebx
call fcn.1002bea2
mov dword [ebp - 4], ebx
cmp dword [eax + 8], ebx
je 0x1002dc6e
push ebx
mov ecx, eax
call fcn.1002c061
mov dword [ebp - 4], 1
cmp byte [ebp - 0x2c], 0
je 0x1002dc86
push dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x40]
call fcn.1002bc35
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x40]
push str.PRAGMA_journal_modeWAL
push dword [edi + 0x40]
call fcn.1002bea2
mov dword [ebp - 4], 2
cmp dword [eax + 8], ebx
je 0x1002dcae
push ebx
mov ecx, eax
call fcn.1002c061
mov dword [ebp - 4], 3
cmp byte [ebp - 0x2c], 0
je 0x1002dcc6
push dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x40]
call fcn.1002bc35
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x40]
push str.PRAGMA_synchronousNORMAL
push dword [edi + 0x40]
call fcn.1002bea2
mov dword [ebp - 4], 4
cmp dword [eax + 8], ebx
je 0x1002dcee
push ebx
mov ecx, eax
call fcn.1002c061
mov dword [ebp - 4], 5
cmp byte [ebp - 0x2c], 0
je 0x1002dd06
push dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x40]
call fcn.1002bc35
or dword [ebp - 4], 0xffffffff
push ecx
lea ecx, [ebp - 0x110]
call fcn.10026855
mov edx, str.PRAGMA_temp_store_directory__
mov dword [ebp - 4], 6
lea ecx, [ebp - 0x110]
call fcn.10010ff9
lea ecx, [ebp - 0x58]
mov esi, eax
call fcn.100a08fe
mov edx, eax
mov byte [ebp - 4], 7
mov ecx, esi
call fcn.1002758f
mov edx, 0x100b42dc
mov ecx, eax
call fcn.10010ff9
lea ecx, [ebp - 0x58]
mov byte [ebp - 4], 6
call fcn.10004eea
lea eax, [ebp - 0x28]
push eax
lea ecx, [ebp - 0x10c]
call fcn.10010eea
mov byte [ebp - 4], 8
lea eax, [ebp - 0x28]
cmp dword [ebp - 0x14], 0xf
lea ecx, [ebp - 0x40]
cmova eax, dword [ebp - 0x28]
push eax
push dword [edi + 0x40]
call fcn.1002bea2
mov byte [ebp - 4], 9
cmp dword [eax + 8], ebx
je 0x1002dd97
push ebx
mov ecx, eax
call fcn.1002c061
mov byte [ebp - 4], 0xa
cmp byte [ebp - 0x2c], 0
je 0x1002ddac
push dword [ebp - 0x3c]
mov ecx, dword [ebp - 0x40]
call fcn.1002bc35
lea ecx, [ebp - 0x28]
call fcn.10004eea
or esi, 0xffffffff
lea ecx, [ebp - 0xc0]
mov dword [ebp - 4], esi
call fcn.10026825
lea ecx, [ebp - 0xc0]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_ios_char__struct_std::char_traits_char__::destructor_void_]
push 0x100b6b60
push dword [edi + 0x40]
lea ecx, [ebp - 0x28]
call fcn.1002bea2
mov dword [ebp - 4], 0xb
cmp dword [ebp - 0x20], 0
je 0x1002ddf9
push ebx
lea ecx, [ebp - 0x28]
call fcn.1002c061
jmp 0x1002ddfb
mov al, bl
test al, al
je 0x1002e20a
lea eax, [ebp - 0x60]
push eax
lea ecx, [ebp - 0x28]
call fcn.1002e741
test al, al
je 0x1002e20a
mov dword [ebp - 4], 0xd
cmp byte [ebp - 0x14], 0
je 0x1002de2f
push dword [ebp - 0x24]
mov ecx, dword [ebp - 0x28]
call fcn.1002bc35
mov dword [ebp - 4], esi
mov eax, dword [ebp - 0x60]
cmp eax, 1
je 0x1002deea
test eax, eax
je 0x1002de4b
cmp eax, 1
jge 0x1002e222
xor edx, edx
lea ecx, [ebp - 0x13]
inc edx
call fcn.1000982c
push ecx
lea ecx, [ebp - 0x13]
push ecx
push eax
lea ecx, [ebp - 0x58]
call fcn.10009844
push 0x14
push str.PRAGMA_user_version
push ecx
lea ecx, [ebp - 0x58]
mov dword [ebp - 4], 0xe
call fcn.10009796
push eax
lea ecx, [ebp - 0x40]
call fcn.100066ed
mov byte [ebp - 4], 0xf
lea eax, [ebp - 0x40]
cmp dword [ebp - 0x2c], 0xf
lea ecx, [ebp - 0x78]
cmova eax, dword [ebp - 0x40]
push eax
push dword [edi + 0x40]
call fcn.1002bea2
mov byte [ebp - 4], 0x10
cmp dword [eax + 8], ebx
je 0x1002deb5
push ebx
mov ecx, eax
call fcn.1002bfdc
mov byte [ebp - 0x59], al
jmp 0x1002deb8
mov byte [ebp - 0x59], bl
mov byte [ebp - 4], 0x11
cmp byte [ebp - 0x64], 0
je 0x1002decd
push dword [ebp - 0x74]
mov ecx, dword [ebp - 0x78]
call fcn.1002bc35
lea ecx, [ebp - 0x40]
call fcn.10004eea
lea ecx, [ebp - 0x58]
mov dword [ebp - 4], esi
call fcn.10004eea
cmp byte [ebp - 0x59], 0
je 0x1002e222
push str.CREATE_TABLE_IF_NOT_EXISTS_events__record_id_TEXT_tenant_token_TEXT_NOT_NULL_latency_INTEGER_persistence_INTEGER_timestamp_INTEGER_retry_count_INTEGER_DEFAULT_0_reserved_until_INTEGER_DEFAULT_0_payload_BLOB_
push dword [edi + 0x40]
lea ecx, [ebp - 0x78]
call fcn.1002bea2
mov dword [ebp - 4], 0x12
cmp dword [eax + 8], ebx
je 0x1002df13
push ebx
mov ecx, eax
call fcn.1002bfdc
mov byte [ebp - 0x59], al
jmp 0x1002df16
mov byte [ebp - 0x59], bl
mov dword [ebp - 4], 0x13
cmp byte [ebp - 0x64], 0
je 0x1002df2e
push dword [ebp - 0x74]
mov ecx, dword [ebp - 0x78]
call fcn.1002bc35
cmp byte [ebp - 0x59], 0
mov dword [ebp - 4], esi
je 0x1002e222
push str.CREATE_INDEX_IF_NOT_EXISTS_k_latency_timestamp_ON_events__latency_DESC__persistence_DESC__timestamp_ASC_
push dword [edi + 0x40]
lea ecx, [ebp - 0x78]
call fcn.1002bea2
mov dword [ebp - 4], 0x14
cmp dword [eax + 8], ebx
je 0x1002df64
push ebx
mov ecx, eax
call fcn.1002bfdc
mov byte [ebp - 0x59], al
jmp 0x1002df67
mov byte [ebp - 0x59], bl
mov dword [ebp - 4], 0x15
cmp byte [ebp - 0x64], 0
je 0x1002df7f
push dword [ebp - 0x74]
mov ecx, dword [ebp - 0x78]
call fcn.1002bc35
cmp byte [ebp - 0x59], 0
mov dword [ebp - 4], esi
je 0x1002e222
push str.CREATE_TABLE_IF_NOT_EXISTS_settings__name_TEXT_value_TEXT__PRIMARY_KEY__name__
push dword [edi + 0x40]
lea ecx, [ebp - 0x78]
call fcn.1002bea2
mov dword [ebp - 4], 0x16
cmp dword [eax + 8], ebx
je 0x1002dfb5
push ebx
mov ecx, eax
call fcn.1002bfdc
mov byte [ebp - 0x59], al
jmp 0x1002dfb8
mov byte [ebp - 0x59], bl
mov dword [ebp - 4], 0x17
cmp byte [ebp - 0x64], 0
je 0x1002dfd0
push dword [ebp - 0x74]
mov ecx, dword [ebp - 0x78]
call fcn.1002bc35
cmp byte [ebp - 0x59], 0
mov dword [ebp - 4], esi
je 0x1002e222
push str.PRAGMA_page_size
push dword [edi + 0x40]
lea ecx, [ebp - 0x28]
call fcn.1002bea2
mov dword [ebp - 4], 0x18
cmp dword [ebp - 0x20], 0
je 0x1002e005
push ebx
lea ecx, [ebp - 0x28]
call fcn.1002c061
mov bl, al
test bl, bl
je 0x1002e201
lea eax, [edi + 0x44]
push eax
lea ecx, [ebp - 0x28]
call fcn.1002e741
test al, al
je 0x1002e201
mov dword [ebp - 4], 0x1a
cmp byte [ebp - 0x14], 0
je 0x1002e039
push dword [ebp - 0x24]
mov ecx, dword [ebp - 0x28]
call fcn.1002bc35
mov dword [ebp - 4], esi
mov ecx, dword [edi + 0x40]
push str.BEGIN_IMMEDIATE
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.COMMIT
mov dword [edi + 0x80], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.ROLLBACK
mov dword [edi + 0x84], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.PRAGMA_page_count
mov dword [edi + 0x88], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_count___FROM_events
mov dword [edi + 0x8c], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_count___FROM_events_WHERE_latency_
mov dword [edi + 0x90], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_tenant_token_FROM_events_ORDER_BY_persistence_ASC__timestamp_ASC_LIMIT_MAX_1__SELECT_COUNT_record_id__FROM_events______100_
mov dword [edi + 0x94], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.DELETE_FROM_events_WHERE_record_id_IN__SELECT_record_id_FROM_events_ORDER_BY_persistence_ASC__timestamp_ASC_LIMIT_MAX_1__SELECT_COUNT_record_id__FROM_events______100__
mov dword [edi + 0x98], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.WITH_RECURSIVE_ids_id__AS__SELECT_0_UNION_ALL_SELECT_tokenize____FROM_ids_WHERE_id_IS_NOT_NULL_LIMIT_10000_OFFSET_1__DELETE_FROM_events_WHERE_tenant_token_IN_ids
mov dword [edi + 0x9c], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.WITH_RECURSIVE_ids_id__AS__SELECT_0_UNION_ALL_SELECT_tokenize____FROM_ids_WHERE_id_IS_NOT_NULL_LIMIT_10000_OFFSET_1__DELETE_FROM_events_WHERE_record_id_IN_ids
mov dword [edi + 0xa8], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.UPDATE_events_SET_reserved_until0__retry_countretry_count1_WHERE_reserved_until__0_AND_reserved_until__
mov dword [edi + 0xa0], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_record_id_tenant_token_latency_timestamp_retry_count_reserved_until_payload_FROM_events_WHERE_latency___AND_reserved_until0_ORDER_BY_latency_DESC_persistence_DESC__timestamp_ASC_LIMIT__
mov dword [edi + 0xa4], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_record_id_tenant_token_latency_timestamp_retry_count_reserved_until_payload_FROM_events_WHERE_latency___ORDER_BY_latency_DESC_persistence_DESC__timestamp_ASC_LIMIT__
mov dword [edi + 0xac], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_record_id_tenant_token_latency_timestamp_retry_count_reserved_until_payload_FROM_events_WHERE_latency_SELECT_MIN_latency__FROM_events_WHERE_reserved_until0_AND_latency____AND_reserved_until0_ORDER_BY_timestamp_ASC_LIMIT__
mov dword [edi + 0xb0], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.WITH_RECURSIVE_ids_id__AS__SELECT_0_UNION_ALL_SELECT_tokenize____FROM_ids_WHERE_id_IS_NOT_NULL_LIMIT_10000_OFFSET_1__UPDATE_events_SET_reserved_until__WHERE_record_id_IN_ids
mov dword [edi + 0xb4], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.WITH_RECURSIVE_ids_id__AS__SELECT_0_UNION_ALL_SELECT_tokenize____FROM_ids_WHERE_id_IS_NOT_NULL_LIMIT_10000_OFFSET_1__UPDATE_events_SET_reserved_until0__retry_countretry_count__WHERE_record_id_IN_ids_AND_reserved_until_0
mov dword [edi + 0xb8], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_tenant_token_FROM_events_WHERE_retry_count__
mov dword [edi + 0xbc], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.DELETE_FROM_events_WHERE_retry_count__
mov dword [edi + 0xc4], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.REPLACE_INTO_events__record_id_tenant_token_latency_persistence_timestamp_payload__VALUES______________
mov dword [edi + 0xc0], eax
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.REPLACE_INTO_settings__name_value__VALUES______
mov dword [edi + 0xc8], eax
call fcn.1002bb8f
mov dword [edi + 0xcc], eax
mov ecx, dword [edi + 0x40]
push str.DELETE_FROM_settings_WHERE_name_
call fcn.1002bb8f
mov ecx, dword [edi + 0x40]
push str.SELECT_value_FROM_settings_WHERE_name_
mov dword [edi + 0xd0], eax
call fcn.1002bb8f
sub esp, 0x18
mov dword [edi + 0xd4], eax
mov eax, dword [edi]
mov ecx, esp
push str.DELETE_FROM_packages
mov esi, dword [eax + 0x54]
call fcn.10004eb1
mov ecx, edi
call esi
mov edx, dword [edi]
mov ecx, edi
call dword [edx + 0x4c]
mov al, 1
jmp 0x1002e224
mov dword [ebp - 4], 0x19
jmp 0x1002e211
mov dword [ebp - 4], 0xc
cmp byte [ebp - 0x14], 0
je 0x1002e222
push dword [ebp - 0x24]
mov ecx, dword [ebp - 0x28]
call fcn.1002bc35
xor al, al
call fcn.100aae69
ret