Skip to content

Probably Memory leak found #63

@Sulverus

Description

@Sulverus

Config

if ( $request_method = GET ) {
    tnt_method "read";
}
if ( $request_method = PUT ) {
    tnt_method "insert";
}
if ( $request_method = POST ) {
    tnt_method "update";
}
if ( $request_method = DELETE ) {
    tnt_method "delete";
}
tnt_http_rest_methods get delete;
tnt_http_methods all;
tnt_multireturn_skip_count 2;
tnt_pure_result on;
tnt_pass_http_request on parse_args;
tnt_pass tnt;

Request

request('PUT', '/ucp/internal/0001/tnt:sh/dpc_po_cache/soc/68ALLNVS2','{"id":0,"params":[{"soc":"68ALLNVS2","product_number":2355574,"description":"sd", "business_types":["B2C"], "product_spec_characteristic_values":{"asd":{"value":"1123asda"}}}]}')

Logging in tarantool:

-- nginx handler
function insert(request, data)
    log.info(yaml.encode(request))
    log.info(yaml.encode(data))
    --- some code...
end

In logs

2016-09-12 23:10:25.589 [22528] main/358/main I> --- {'method': 'PUT', 'uri': '/ucp/internal/0001/tnt:sh/dpc_po_cache/soc/68ALLNVS2',
  'args': {}, 'proto': 'HTTP/1.1', 'headers': {'Bauth-token': 'KyitaIN9b7MgITEaEmoejZmCFPk/5EeU4JYFQuOcP0udhHOWcb7/gmXLVOOdogPJOcncM7GBaUnkZavWNkNVJcwX3ngbqC1euT7HReOlQrfI7Kyj0RqDvknV7cJFQvbPG2X2Ai/8vruvcsKQukaWMW0nBKceDyC2chmNct0qogD3JsCplWTfUaZztHTdGT1fP1hIBdqwdYzzx5W5T6Mwc25/hi+hCWmnxjdTtCzGP8DOQkSSYGvMKRNKPU38gMO+jpeVA2chK0vyLIUU/kcH0tRBb0tpQecdYRAdFVSoDpp+pnwrESfiRs3gOBHSAj+SPrpvRvu/1ZrFXpVEJAlNSQ==',
    'Host': 'tst-ucpappl001.vimpelcom.ru', 'Connection': 'close', 'Content-length': '168',
    'Te': 'trailers', 'Referer': 'http://tst-ucpappl001.vimpelcom.ru/ucp/internal/0001/tnt:sh/dpc_po_cache/soc/68ALLNVS2',
    'User-agent': 'Tarantool http client'}}
...

2016-09-12 23:10:25.589 [22528] main/358/main I> --- {'PREP': 'product_spec_characteristic_values', 'product_number': 2355574, 'lines': [
    {'method': 'PUT', 'uri': '/ucp/internal/0001/tnt:sh/dpc_po_cache/soc/68ALLNVS2',
      'args': {}, 'proto': 'HTTP/1.1', 'headers': {'Bauth-token': 'KyitaIN9b7MgITEaEmoejZmCFPk/5EeU4JYFQuOcP0udhHOWcb7/gmXLVOOdogPJOcncM7GBaUnkZavWNkNVJcwX3ngbqC1euT7HReOlQrfI7Kyj0RqDvknV7cJFQvbPG2X2Ai/8vruvcsKQukaWMW0nBKceDyC2chmNct0qogD3JsCplWTfUaZztHTdGT1fP1hIBdqwdYzzx5W5T6Mwc25/hi+hCWmnxjdTtCzGP8DOQkSSYGvMKRNKPU38gMO+jpeVA2chK0vyLIUU/kcH0tRBb0tpQecdYRAdFVSoDpp+pnwrESfiRs3gOBHSAj+SPrpvRvu/1ZrFXpVEJAlNSQ==',
        'Host': 'tst-ucpappl001.vimpelcom.ru', 'Connection': 'close', 'Content-length': '168',
        'Te': 'trailers', 'Referer': 'http://tst-ucpappl001.vimpelcom.ru/ucp/internal/0001/tnt:sh/dpc_po_cache/soc/68ALLNVS2',
        'User-agent': 'Tarantool http client'}}], 'soc': '68ALLNVS2', 'description': 'sd'}
...

Total:
data from nginx in tarantool

{'PREP': 'product_spec_characteristic_values', 'product_number': 2355574, 'lines': [
    {'method': 'PUT', 'uri': '/ucp/internal/0001/tnt:sh/dpc_po_cache/soc/68ALLNVS2',
      'args': {}, 'proto': 'HTTP/1.1', 'headers': {'Bauth-token': 'KyitaIN9b7MgITEaEmoejZmCFPk/5EeU4JYFQuOcP0udhHOWcb7/gmXLVOOdogPJOcncM7GBaUnkZavWNkNVJcwX3ngbqC1euT7HReOlQrfI7Kyj0RqDvknV7cJFQvbPG2X2Ai/8vruvcsKQukaWMW0nBKceDyC2chmNct0qogD3JsCplWTfUaZztHTdGT1fP1hIBdqwdYzzx5W5T6Mwc25/hi+hCWmnxjdTtCzGP8DOQkSSYGvMKRNKPU38gMO+jpeVA2chK0vyLIUU/kcH0tRBb0tpQecdYRAdFVSoDpp+pnwrESfiRs3gOBHSAj+SPrpvRvu/1ZrFXpVEJAlNSQ==',
        'Host': 'tst-ucpappl001.vimpelcom.ru', 'Connection': 'close', 'Content-length': '168',
        'Te': 'trailers', 'Referer': 'http://tst-ucpappl001.vimpelcom.ru/ucp/internal/0001/tnt:sh/dpc_po_cache/soc/68ALLNVS2',
        'User-agent': 'Tarantool http client'}}], 'soc': '68ALLNVS2', 'description': 'sd'}

Waiting for

{"soc":"68ALLNVS2","product_number":2355574,"description":"sd", "business_types":["B2C"], "product_spec_characteristic_values":{"asd":{"value":"1123asda"}}}

Seems like memory leak

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions