serialized: don't copy strings in policy lookups 26/249426/1
authorAdrian Szyndela <adrian.s@samsung.com>
Fri, 11 Dec 2020 09:06:16 +0000 (10:06 +0100)
committerAdrian Szyndela <adrian.s@samsung.com>
Fri, 11 Dec 2020 09:11:10 +0000 (10:11 +0100)
commit7e357b033baac41efed09a4a021ca113b1c280d8
treee8cbb3edb30ff9fafb515ac5f43fdc6cf9bedf80
parentc97b4b2fc2282f2754e99bc70d00f0b194bbde30
serialized: don't copy strings in policy lookups

Direct serialization allows more optimizing. Now, that other
backends are gone, we can slightly modify the interface.

This commit makes send index searching pass boost::string_ref
to the backend instead of copied C-string. The backend interface
is modified to accept string_ref. This way we can remove
string copying which was necessary for having null-terminated C-string.

Change-Id: I5a1f9657efd050d93023b5256f13afd6d150c369
src/internal/storage_backend_direct.hpp
src/internal/storage_backend_serialized.cpp