Commit Graph

138 Commits (ec00f7f14fbf16992b71ddd54e583ba07fdfd523)

Author SHA1 Message Date
Brad Payne (Vir Linden) a04a706c1b merge 2013-05-21 16:18:48 -04:00
Oz Linden ddd5659f81 merge changes for DRTVWR-294 2013-04-19 10:11:29 -04:00
Don Kjer beeefb4526 Renaming HTTP_HEADER_* into HTTP_IN_HEADER_* and HTTP_OUT_HEADER_* to make it more clear which header strings should be used for incoming vs outgoing situations.
Using constants for commonly used llhttpnode context strings.
2013-04-04 21:50:45 +00:00
Graham Madarasz bf6182daa8 Update Mac and Windows breakpad builds to latest 2013-03-29 07:50:08 -07:00
Don Kjer f945415210 Large changes to the LLCurl::Responder API, as well as pulling in some changes to common libraries from the server codebase:
* Additional error checking in http handlers.
* Uniform log spam for http errors.
* Switch to using constants for http heads and status codes.
* Fixed bugs in incorrectly checking if parsing LLSD xml resulted in an error.
* Reduced spam regarding LLSD parsing errors in the default completedRaw http handler.  It should not longer be necessary to short-circuit completedRaw to avoid spam.
* Ported over a few bug fixes from the server code.
* Switch mode http status codes to use S32 instead of U32.
* Ported LLSD::asStringRef from server code; avoids copying strings all over the place.
* Ported server change to LLSD::asBinary; this always returns a reference now instead of copying the entire binary blob.
* Ported server pretty notation format (and pretty binary format) to llsd serialization.

* The new LLCurl::Responder API no longer has two error handlers to choose from.  Overriding the following methods have been deprecated:
** error - use httpFailure
** errorWithContent - use httpFailure
** result - use httpSuccess
** completed - use httpCompleted
** completedHeader - no longer necessary; call getResponseHeaders() from a completion method to obtain these headers.

* In order to 'catch' a completed http request, override one of these methods:
** httpSuccess - Called for any 2xx status code.
** httpFailure - Called for any non-2xx status code.
** httpComplete - Called for all status codes.  Default implementation is to call either httpSuccess or httpFailure.
* It is recommended to keep these methods protected/private in order to avoid triggering of these methods without using a 'push' method (see below).

* Uniform error handling should followed whenever possible by calling a variant of this during httpFailure:
** llwarns << dumpResponse() << llendl;
* Be sure to include LOG_CLASS(your_class_name) in your class in order for the log entry to give more context.

* In order to 'push' a result into the responder, you should no longer call error, errorWithContent, result, or completed.
* Nor should you directly call httpSuccess/Failure/Completed (unless passing a message up to a parent class).
* Instead, you can set the internal content of a responder and trigger a corresponding method using the following methods:
** successResult - Sets results and calls httpSuccess
** failureResult - Sets results and calls httpFailure
** completedResult - Sets results and calls httpCompleted

* To obtain information about a the response from a reponder method, use the following getters:
** getStatus - HTTP status code
** getReason - Reason string
** getContent - Content (Parsed body LLSD)
** getResponseHeaders - Response Headers (LLSD map)
** getHTTPMethod - HTTP method of the request
** getURL - URL of the request

* It is still possible to override completeRaw if you want to manipulate data directly out of LLPumpIO.

* See indra/llmessage/llcurl.h for more information.
2013-03-13 06:26:25 +00:00
Don Kjer 54cdc322b8 Fixing issues with not detecting when LLSD XML parsing fails. Changing most http error handlers to understand LLSD error responses. Fleshing out most http error handler message spam. 2013-03-05 22:05:22 -08:00
Monty Brandenberg 0755cb098d Merge. Refresh DRTVWR-209 with 3.4.2-beta1 code.
Two fairly simple conflicts:  dead stats sending code in the
texture fetch code (new llcorehttp library) and the cleanup
code in llappviewer was moved around in 3.4.x.
2012-11-07 13:28:42 -05:00
Oz Linden 1709952adb pull back 3.4.1-beta6 fixes 2012-10-10 21:40:10 -04:00
Dave Parks 827d8814cf MAINT-1688 Potential fix for crash on exit in LLTextureFetch 2012-10-09 13:34:28 -05:00
Dave Parks 374f20edf0 Fix non-thread-safe refcounting of LLHTTPClient::Responder and fix out-of-order deletion of LLTextureFetch on shutdown 2012-10-03 14:30:21 -05:00
Dave Parks 05dbd7dafe Instrument debug builds on windows to help track down source of heap corruption 2012-10-02 16:06:14 -05:00
Monty Brandenberg 04e8d074b2 DRTVWR-209 Merge of viewer-development with SH-3316 drano-http code.
This was yet another refresh from v-d because of significant changes
to lltexturefetch that would not have been resolvable by casual
application of any merge tool.  There are still a few questions
outstanding but this is the initial, optimistic merge.
2012-09-07 12:53:07 -04:00
Monty Brandenberg 8e5197a71b Merge 3.3.3 release with Drano HTTP library at 3.3.0
Big delta was converting the new texture debugger support code
to the new library.  Viewer manifest should probably get an eyeball
before release.
2012-07-02 18:06:22 -04:00
Xiaohong Bao 0730b24d7c fix merge conflicts: v-r to drano 2012-06-26 22:27:24 -06:00
Brad Payne (Vir Linden) 74d4f8af01 v-r to drano merge conflicts wip 2012-06-26 16:43:58 -04:00
Monty Brandenberg 841a447e55 Limit libcurl's DNS resolution to IPV4 addresses for now. Callers
who want to try IPV6 can still override at will using CURLOPT_IPRESOLVE.
2012-06-08 16:12:52 +00:00
simon@Simon-PC.lindenlab.com 1777fa5187 Merge pull from lindenlab/viewer-development as requested by Oz for DRTVWR-148 2012-05-25 15:07:22 -07:00
Xiaohong Bao cbb14e223c fix for SH-3137: delay to issue new http fetching requests if http connection failure happens 2012-05-25 14:08:33 -06:00
Xiaohong Bao e37917b668 fix for VWR-28996: Texture stalls and threading models 2012-05-24 14:32:14 -06:00
Merov Linden 56af97063a Pull from vir/drano 2012-05-02 15:59:15 -07:00
Merov Linden efd19dddd9 SH-3126 : Improve curl byte range call, test implementation in lltexturefetch (not final) 2012-05-02 10:37:51 -07:00
Brad Payne (Vir Linden) 678864e4ed merge viewer-release to drano 2012-05-02 13:00:59 -04:00
Nat Goodspeed 78f2663c4a Automated merge with http://hg.secondlife.com/viewer-release 2012-04-26 14:04:55 -04:00
callum 4ccae31320 SH-3115 FIX Crash on exit, curl handles not empty
Reviewed by Ted.
2012-04-23 11:28:52 -07:00
Xiaohong Bao 88edb8da4e fix for MAINT-701: crash at LLCurl::Multi::markDead()
reviewed by davep
2012-03-08 17:58:25 -07:00
Richard Linden 2ed1de224a Automated merge with http://hg.secondlife.com/viewer-development 2012-02-06 15:28:45 -08:00
Xiaohong Bao 5e74293b0c fix for SH-2941: crash at LLCurl::Easy::~Easy() 2012-02-03 22:01:46 -07:00
Richard Linden 5a14a67e06 converted a bunch of narrowing implicit conversions to explicit 2012-02-01 13:03:46 -08:00
Xiaohong Bao 717a6f3306 Introduce two new parameters "CurlUseMultipleThreads" and "CurlRequestTimeOut" for QA to test Curl. 2012-01-25 18:27:40 -07:00
Xiaohong Bao 1316f33130 fix for SH-2904: textures remain stuck in HTP state 2012-01-25 16:01:56 -07:00
Xiaohong Bao 9e6a5d7211 fix for SH-2823 and SH-2824: LLCurl crash inside LLBufferArray::countAfter() and LLBufferArray::copyIntoBuffers 2012-01-20 11:55:15 -07:00
Xiaohong Bao 25c21c3761 add more exception handlings for llcurl fix. 2012-01-17 22:56:28 -07:00
Xiaohong Bao 11bd5cb860 trivial: fix a mac build error. 2012-01-12 20:32:32 -07:00
Xiaohong Bao f082de03ff fix for SH-2845, SH-2846, SH-2847, SH-2851: curl crashes and out-of-memory crashes. 2012-01-12 16:36:56 -07:00
Brad Payne (Vir Linden) a3e30250e8 merge 2012-01-04 09:59:57 -05:00
Xiaohong Bao ec06aa129f add mutex to protect curl_multi-init() 2011-12-20 15:02:21 -07:00
Xiaohong Bao 1620ad6d00 more tuning of llcurl code targeting crashes like SH-2777. 2011-12-20 11:04:10 -07:00
Xiaohong Bao cfc6ac76e1 more tuning of llcurl code targeting crashes like SH-2777. 2011-12-20 11:04:10 -07:00
Dave Parks 5affaf264d SH-2738 Don't lock unless we really need to 2011-12-19 16:55:21 -06:00
Dave Parks 43e3603cd7 SH-2738 Don't lock unless we really need to 2011-12-19 16:55:21 -06:00
Dave Parks 58f9982fbc SH-2738 Add comment documenting need to not make main thread wait on curl_multi_perform 2011-12-19 15:35:38 -06:00
Xiaohong Bao efec138037 fix for SH-2738 and SH-2777, might also help SH-2723: heap corruption
SH-2738: Texture fetching freezes due to LLcurl
SH-2777: viewer crashed on logout in LLCurl::Easy::releaseEasyHandle
2011-12-15 21:39:48 -07:00
Xiaohong Bao 4ec112bfce fix for SH-2738 and SH-2777, might also help SH-2723: heap corruption
SH-2738: Texture fetching freezes due to LLcurl
SH-2777: viewer crashed on logout in LLCurl::Easy::releaseEasyHandle
2011-12-15 21:39:48 -07:00
Brad Payne (Vir Linden) 642ea00a08 merge 2011-12-12 10:45:13 -05:00
Dave Parks 50a57ba9fe Backed out changeset fafd857891b1 2011-12-09 12:23:04 -06:00
Dave Parks 1516e4c497 merge 2011-12-05 17:56:38 -06:00
Dave Parks 78233d1bf9 SH-2652 WIP -- Add timers to relevant areas, pause render pipeline while occlusion queries from previous frame are still pending and perform texture decode work. 2011-12-05 17:55:40 -06:00
Xiaohong Bao 09feaac844 fix for sh-2738: Texture fetching freezes due to LLcurl 2011-12-05 13:23:05 -07:00
Xiaohong Bao 3fc4c14464 fix a mac build error: a friend declaration issue. 2011-11-29 16:18:50 -07:00
Xiaohong Bao b4766d2fde fix for sh-2601: [crashhunters] crash in LLBufferArray::countAfter()
sh-2602: [crashhunters] crash on exit in ~LLPumpIO()
2011-11-21 14:42:21 -07:00