|
Defines |
#define | PARQ_MAX_UL_RETRY_DELAY 1200 /**< 20 minutes retry rate max. */ |
| 20 minutes retry rate max
|
#define | PARQ_GRACE_TIME 90 /**< Grace period after life expired */ |
| Grace period after life expired.
|
Functions |
void | parq_init (void) |
| Initialises the upload queue for PARQ.
|
void | parq_close (void) |
| Saves any queueing information and frees all memory used by PARQ.
|
const gchar * | get_parq_dl_id (const struct download *d) |
| Retrieves the PARQ ID associated with an download.
|
void | parq_dl_reparent_id (struct download *d, struct download *cd) |
| Called from download_clone to reparent the PARQ ID from the parent `d' to the cloned `cd'.
|
gpointer | parq_dl_create (struct download *d) |
| Creates a queue structure for a download.
|
void | parq_dl_add_id (struct download *d, const gchar *new_id) |
| Assigns an parq ID to a download, and places them in various lists for lookup.
|
void | parq_dl_remove (struct download *d) |
| Tells the parq logic that a download has been removed.
|
void | parq_dl_free (struct download *d) |
| Removes the queue information for a download from memory.
|
void | parq_download_retry_active_queued (struct download *d) |
| Active queued means we didn't close the http connection on a HTTP 503 busy when the server supports queueing.
|
gboolean | parq_download_supports_parq (header_t *header) |
gboolean | parq_download_parse_queue_status (struct download *d, header_t *header) |
| Retrieve and parse queueing information.
|
gboolean | parq_download_is_active_queued (struct download *d) |
| Whether the download is queued remotely or not.
|
void | parq_download_add_header (gchar *buf, size_t len, size_t *rw, struct download *d) |
| Needs brief description here.
|
gboolean | parq_download_is_passive_queued (struct download *d) |
| Whether the download is queued remotely without keeping the connection or not.
|
void | parq_download_queue_ack (struct gnutella_socket *s) |
| parq_download_queue_ack
|
void | parq_upload_timer (time_t now) |
| Removes any PARQ uploads which show no activity.
|
void | parq_upload_add_header (gchar *buf, gint *retval, gpointer arg, guint32 flags) |
| Adds X-Queued status in the HTTP reply header for a queued upload.
|
void | parq_upload_add_header_id (gchar *buf, gint *retval, gpointer arg, guint32 flags) |
| Adds X-Queued status in the HTTP reply header showing the queue ID for an upload getting a slot.
|
gpointer | parq_upload_get (gnutella_upload_t *u, header_t *header, gboolean replacing) |
| Get a queue slot, either existing or new.
|
gboolean | parq_upload_request (gnutella_upload_t *u, guint used_slots) |
gboolean | parq_upload_request_force (gnutella_upload_t *u, gpointer handle, guint used_slots) |
| If the download may continue, true is returned.
|
guint | parq_upload_lookup_position (const gnutella_upload_t *u) |
const gchar * | parq_upload_lookup_id (const gnutella_upload_t *u) |
gboolean | parq_upload_queue_full (gnutella_upload_t *u) |
guint | parq_upload_lookup_size (const gnutella_upload_t *u) |
gboolean | parq_upload_addr_can_proceed (const gnutella_upload_t *u) |
| Check that the IP is not already downloading more than is alllowed.
|
time_t | parq_upload_lookup_lifetime (const gnutella_upload_t *u) |
time_t | parq_upload_lookup_retry (const gnutella_upload_t *u) |
guint | parq_upload_lookup_eta (const gnutella_upload_t *u) |
guint | parq_upload_lookup_queue_no (const gnutella_upload_t *u) |
gboolean | parq_upload_lookup_quick (const gnutella_upload_t *u) |
gboolean | parq_upload_queued (gnutella_upload_t *u) |
| Whether the current upload is already queued.
|
gboolean | parq_upload_remove (gnutella_upload_t *u) |
| When an upload is removed this function should be called so parq knows the current upload status of an upload.
|
void | parq_upload_collect_stats (const gnutella_upload_t *u) |
| Collect running stats about the completed / removed upload.
|
void | parq_upload_upload_got_freed (gnutella_upload_t *u) |
| Makes sure parq doesn't keep any internal reference to the upload structure.
|
void | parq_upload_upload_got_cloned (gnutella_upload_t *u, gnutella_upload_t *cu) |
void | parq_upload_force_remove (gnutella_upload_t *u) |
void | parq_upload_add (gnutella_upload_t *u) |
void | parq_upload_busy (gnutella_upload_t *u, gpointer handle) |
| Mark an upload as really being active instead of just being queued.
|
void | parq_upload_save_queue (void) |
| Saves all the current queues and their items so it can be restored when the client starts up again.
|
void | parq_upload_send_queue_conf (gnutella_upload_t *u) |
| 'Call back' connection was succesfull.
|
gboolean | parq_ul_id_sent (const gnutella_upload_t *u) |
| Determines whether the PARQ ID was already sent for an upload.
|
time_t | parq_banned_source_expire (const host_addr_t addr) |