DocumentStatus
Enum representing the status of a DraftDocumentEntity.
Below one can find a simple representation of the same flow, represented as document statuses:
+------+------+
| INITIALIZED | <- Validation is run before initializing, an attempt won't be made if the input is invalid
+------+------+
|
|<--------------------------------+--------------------------------------------------+
| | |
| +--------------+---------------+ |
| | UPLOADING_PAUSED_NO_INTERNET | <retry count not reached>
v +--------------+---------------+ |
+-----+-----+ | +-------------+-------------+
| UPLOADING +---------------------------+--------------------+-------------->| UPLOAD_FAILED_RECOVERABLE |
+-----+-----+ | +-------------+-------------+
| | |
v | <retry count reached>
+-----+-----+ | |
| UPLOADED | | |
+-----+-----+ | |
|<----------+-------------------------+ | |
| | | | |
| +---------+---------+ +-------------+--------------+ | |
| | POLLING_TIMED_OUT | | POLLING_PAUSED_NO_INTERNET | | |
v +---------+---------+ +-------------+--------------+ | |
+-----+-----+ | | | |
| POLLING +-----+-------------------------+ | |
+-----+-----+ | |
| | |
|----------------------+ | |
| | | |
| | | |
vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv FINAL STATES vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
| | | |
| | | |
v v v v
+---------+---------+ +---------+---------+ +--------------+--------------+ +------------+------------+
| PROCESSED_SUCCESS | | PROCESSED_FAILED | | UPLOAD_FAILED_UNRECOVERABLE | | REACHED_MAX_RETRY_COUNT |
+---------+---------+ +---------+---------+ +--------------+--------------+ +------------+------------+
Entries
PROCESSED_FAILED
Link copied to clipboard
PROCESSED_FAILED("PROCESSED_FAILED", isFinal, true)
Content copied to clipboard
DraftDocumentEntity has returned with an invalid response while long polling.
PROCESSED_SUCCESS
Link copied to clipboard
PROCESSED_SUCCESS("PROCESSED_SUCCESS", isFinal, true)
Content copied to clipboard
DraftDocumentEntity has successfully been long polled and has returned with a valid response
REACHED_MAX_RETRY_COUNT
Link copied to clipboard
REACHED_MAX_RETRY_COUNT("REACHED_MAX_RETRY_COUNT", isFinal, true)
Content copied to clipboard
DraftDocumentEntity has reached its maximum retry count while uploading or polling.
POLLING_PAUSED_NO_INTERNET
Link copied to clipboard
POLLING_PAUSED_NO_INTERNET("POLLING_PAUSED_NO_INTERNET")
Content copied to clipboard
DraftDocumentEntity has been uploaded to the API, and is now being actively long polled, but while polling the network was lost and could not be continued.
POLLING_TIMED_OUT
Link copied to clipboard
POLLING_TIMED_OUT("POLLING_TIMED_OUT")
Content copied to clipboard
DraftDocumentEntity has been uploaded to the API, and is now being actively long polled, but has timed out.
UPLOAD_FAILED_UNRECOVERABLE
Link copied to clipboard
UPLOAD_FAILED_UNRECOVERABLE("UPLOAD_FAILED_UNRECOVERABLE", isFinal, true)
Content copied to clipboard
DraftDocumentEntity has failed to upload with what is deemed as unrecoverable error.
UPLOAD_FAILED_RECOVERABLE
Link copied to clipboard
UPLOAD_FAILED_RECOVERABLE("UPLOAD_FAILED_RECOVERABLE")
Content copied to clipboard
DraftDocumentEntity has failed to upload with what is deemed as recoverable error.
UPLOADING_PAUSED_NO_INTERNET
Link copied to clipboard
UPLOADING_PAUSED_NO_INTERNET("UPLOADING_PAUSED_NO_INTERNET")
Content copied to clipboard
DraftDocumentEntity has begun the upload step, but has no internet access to continue.
INITIALIZED
Link copied to clipboard
INITIALIZED("INITIALIZED")
Content copied to clipboard
DraftDocumentEntity has been created in the DraftDocumentDatabase.