About Adding an Attachment
Starting October 11, 2024 (Zephyr Enterprise 8.2), the Zephyr Enterprise documentation moved from its current location on Atlassian to a dedicated, standalone Zephyr Enterprise documentation page. Please see: About Adding an Attachment | Zephyr Enterprise Documentation
Consider the following conditions while adding a file as an attachment:
The default maximum file size is 50 MB.
The following file extensions are allowed:
.7z, .bmp, .csv, .doc, .docx, .eml, .feature, .gif, .gz, .htm, .html, .jpeg, .jpg, .json, .key, .lic, .log, .m4p, .MHT, .mkv, .mp4, .msg, .odp, .ods, .odt, .pdf, .png, .pps, .ppt, .pptx, .py, .rar, .rtf, .sql, .svg, .tar, .txt, .wmv, .wrf, .xls, .xlsx, .xml, .yaml, .yml, .crt, .cer, .ca-bundle, .p7b, .p7c, .p7s, .pem, .keystore, .jks, .p12, .pfx, .pem, and .zipThe file MIME type should match the file extension.
To upload an unsupported file extension, zip it and attach it.
Configuring the File Size
The different ways to configure a file size in the system are:
You can configure the file size using the API endpoint and the method is PUT.
/flex/services/rest/latest/admin/preference/admin
In the request body, the unit for the file size must be in bytes.
You must include the following parameters:
[
{
"name": "allowed.upload.max.file.size",
"value": "52428800"
}
]
Â
Internal Storage for Attachments
Attachments are stored in the attachment folder under Zephyrdata folder. The path to Zephyrdata folder can be found in jdbc.properties file saved under property ZEPHYR_DATA.
The folder Zephyrdata is a shared directory in case of a cluster setup as the data contained in this folder should be accessible to all the cluster nodes.
Attachment file and folder structure logic
The attachments are saved using the following logic:
attachment/<entityType>/seq-<sequenceId>/<entityId>/<attachmentId>
The placeholders occupied are:
<entityType>: This is the type of entity against which the attachment is being saved.
For example, testcase, requirement, user, and so on.<sequenceId>: This ID consists of 4 digits. The format consists of:
<last four digits of entityId> + <padding count to 4 with 0>
.
For example,If the <entityId> is 1, then padding to make 4-digit count is 000, hence <sequenceId> is 1000.
If the <entityId> is 34, then padding to make 4-digit count is 00, hence<sequenceId> is 3400.
If the <entityId> is 12345, then padding to make 4-digit count is not required, hence <sequenceId> is 2345 as only the last 4 digits are taken.
<entityId>: This is the ID of the entity against which the attachment is being saved.
For example, testcaseId, requirementId, userId, and so on.<attachmentId>: This is the id given to every attachment as a unique identifier. This placeholder is the attachment file that was uploaded against the entity. The attachment is not saved with the original name in the directory but is saved with attachmentId.
The following are the examples:
For a testcase with id 1, attachments will be found in the following path:
For a testcase with id 34, attachments will be found in the following path:
For a testcase with id 12345, attachments will be found in the following path:
Â
Starting Release 8.2, Zephyr Enterprise documentation is moving from its current location on Atlassian to a dedicated, standalone Zephyr Enterprise Documentation page. https://support.smartbear.com/zephyr-enterprise/docs/en/welcome-to-zephyr-enterprise.html