FHttpManager

Manages Http request that are currently being processed

Windows
MacOS
Linux

Inheritance Hierarchy

FTickerObjectBase

FHttpManager

References

Module

HTTP

Header

/Engine/Source/Runtime/Online/HTTP/Public/HttpManager.h

Include

#include "HttpManager.h"

Syntax

class FHttpManager : public FTickerObjectBase

Remarks

Manages Http request that are currently being processed

Variables

Name Description

Protected variable

TFunction< FStr...

 

CorrelationIdMethod

This method will be called to generate a CorrelationId on all requests being sent if one is not already set

Protected variable

TQueue< TFuncti...

 

GameThreadQueue

Queue of tasks to run on the game thread

Protected variable

TArray< TShared...

 

Requests

List of Http requests that are actively being processed

Protected variable

FHttpThread ...

 

Thread

Constructors

Name Description

Public function

FHttpManager()

Constructor

Destructors

Name Description

Public function Virtual

~FHttpManager()

Destructor

Functions

Name Description

Public function

void

 

AddGameThreadTask

(
    TFunction< void()>&& Task
)

Add task to be ran on the game thread next tick

Public function

void

 

AddRequest

(
    const TSharedRef< IHttpRequest, ESP...
)

Adds an Http request instance to the manager for tracking/ticking Manager should always have a list of requests currently being processed

Public function

void

 

AddThreadedRequest

(
    const TSharedRef< IHttpThreadedRequ...
)

Add a http request to be executed on the http thread

Public function

void

 

CancelThreadedRequest

(
    const TSharedRef< IHttpThreadedRequ...
)

Mark a threaded http request as cancelled to be removed from the http thread

Public function Const

FString

 

CreateCorrelationId()

Create a new correlation id for a request

Protected function Virtual

FHttpThread ...

 

CreateHttpThread()

Create HTTP thread object

Public function Const

void

 

DumpRequests

(
    FOutputDevice& Ar
)

List all of the Http requests currently being processed

Public function

void

 

Flush

(
    bool bShutdown
)

Block until all pending requests are finished processing

Public function Virtual

void

 

FlushTick

(
    float DeltaSeconds
)

Tick called during Flush

Public function Static

TFunction< F...

 

GetDefaultCorrelationIdMethod()

Get the default method for creating new correlation ids for a request

Public function

void

 

Initialize()

Initialize

Public function Const

bool

 

IsDomainAllowed

(
    const FString& Url
)

Determine if the domain is allowed to be accessed

Public function Const

bool

 

IsValidRequest

(
    const IHttpRequest* RequestPtr
)

Find an Http request in the lists of current valid requests

Public function Virtual

void

 

OnAfterFork()

Inform that HTTP Manager that we have completed a fork().

Public function Virtual

void

 

OnBeforeFork()

Inform that HTTP Manager that we are about to fork().

Public function Virtual

void

 

OnEndFramePostFork()

Inform the HTTP Manager that we finished ticking right after forking.

Public function

void

 

RemoveRequest

(
    const TSharedRef< IHttpRequest, ESP...
)

Removes an Http request instance from the manager Presumably it is done being processed

Public function

void

 

SetCorrelationIdMethod

(
    TFunction< FString()> InCorrelation...
)

Set the method used to set a Correlation id on each request, if one is not already specified.

Public function Virtual Const

bool

 

SupportsDynamicProxy()

Method to check dynamic proxy setting support.

Public function Virtual

void

 

UpdateConfigs()

Update configuration. Called when config has been updated and we need to apply any changes.

Overridden from FTickerObjectBase

Name Description

Public function Virtual

bool

 

Tick

(
    float DeltaSeconds
)

FTicker callback

Constants

Name

Description

RequestLock

Used to lock access to add/remove/find requests

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss