When a ticket is created or modified Fossil extends BACKLINK
table with
the links extracted from the J-cards of the ticket change artifact.
That extraction requires the knowledge of which markup is used.
Previously Fossil derived this information solely from the value
of J-card named "mimetype"1, which was considered only if
a regular "mimetype" column was defined in TICKET
or TICKETCHNG
table.
This branch adds the ability to specify mimetypes using
GENERATED "mimetype" columns.
It implements the following rules:
If either
TICKET
orTICKETCHNG
table has a regular (not generated) "mimetype" column, then traditional processing is applied (as schetched in the beginning).Otherwise: if just one of the above tables has generated "mimetype" column then the generated value in the corresponding row is used.
Otherwise: if just one of two generated values is not NULL then that value is used for all fields.
Otherwise (when both generated values are not NULL):
- all fields that are defined in the
TICKETCHNG
table are processed using mimetype from theTICKETCHNG
table; - the rest fields (that are specific to
TICKET
table) are processed using mimetype from theTICKET
table.
- all fields that are defined in the
If a NULL value has to be interpreted as mimetype it works as Fossil-Wiki.
That also applies to the case when "mimetype" column is missing
in both TICKET
and TICKETCHNG
.
See forum thread 40c1208a0f84 for rationale and discussion.
- ^ Here and further the naming "mimetype" is case-sensitive. Presumably due to performance considerations.