v3.0.14
Pre-releaseWARNING: BREAKING API CHANGES - API is now frozen for the pre-releases
This is an extra large release in expectation of becoming the initial stable release of the major version 3 library.
This release contains the following API changes:
-
The
fpos
andlast
arguments ofms3_readmsr()
,ms3_readmsr_r()
, andms3_readmsr_selection()
have been removed. The same capabilities are available and details are included in the porting guide. -
The
MS3TraceList.numtraces
member was renamedMS3TraceList.numtraceids
to clarify. -
The
ptr
argument, previously namedpath
, to mseh_get and mseh_set routines is now in JSON Pointer (RFC 6901) format. This is a more appropriate, and standardized, format than the pseudo-JSON Path, dotted string style previously used. It also allows more flexibility such as specification of an array element. -
The
mseh_get_path_r()
andmseh_set_path_r()
were previously named without the_r
suffix, now take a additionalparsestate
argument. This functionality allows the parsed extra headers to be retained between calls to avoid re-parsing. For advanced usage, this allows more efficient getting or setting of multiple extraheader values. If used, this state information must be free'd withmseh_free_parsestate()
. If used withmseh_set_path_r()
the headers must also be serialized withmseh_serialize()
. -
mstl3_printtracelist() now takes an additional
versions
argument. When non-zero the routine will decorate SIDs with publication versions. -
The
MS3TraceID
structure is no longer a simple linked list. Instead, it is a skip list, slightly changing the syntax for traversing the list as illustrated in the examples.
Furthermore, this release contains the following changes:
- Add JSON Merge Patch capability to
mseh_set_ptr_r()
using the value typeM
. This allows flexible modification, including deletes, of extra header values. - New test suite based on Tau (https://github.com/jasmcaus/tau). Many tests were added and the suite now works on MS-Windows.
- Replace JSON library with yyjson (https://github.com/ibireme/yyjson). Benefits include performance, shortest accurate real number representation, JSON Pointer support, and UTF-8 support.
- Significant optimization for the case of constructing trace lists with large numbers of different source IDs, by using a skip list. Implementation inspired by: https://github.com/tdeck/c-skiplist, thanks @tdeck!
- Add new
mstl3_findID()
function for searching a trace list for specific SourceID and, optionally, publication version. - Optimize trace construction in
mstl3_addmsr_recordptr()
for the case of duplicate records. - Add cURL detection and full build support to example/Makefile.
- Add 'const' declarations to
ms_sid2nslc()
andms_nslc2sid()
to guarantee input will not be modified. - Update example/lm_pack.c to a) use improved test data (a sinusoid) that contains all differences for Steim1 and Steim2 encoding, and b) add an
-F
option to set the format version to create. mseh_get_path_r()
andmseh_set_path_r()
now accept a value type ofi
that is used with int64_t values.- Add
nstime_t
special value ofNSTUNSET
for use as "unset" meaning. - Fix logic test for
LIBMSEED_NO_THREADING
declaration. - Fix zero-padding of empty bytes following data in miniSEED v2 creation.
- Rename
DE_ASCII
toDE_TEXT
to generalize to UTF-8, legacy mapping provided. - Change sample type for text encoding to 't', value 'a' still supported as an alternative.
- Add
MS3Tolerance_INITIALIZER
forMS3Tolerance
values. - Handle special case of year 0 when parsing version 2 blockettes. These are now treated as "unset" and not included in the extra headers.
- Added FAQ to documentation and update example code to match API changes.