Nextcloud PHP API (master)

IGlobalScaleService

Service related to sending data from instances in a global scale setup.

This service is only available when the globalsiteselector application is enabled.

Tags
since
34.0.3

Table of Contents

Methods

decodePayload()  : array<string|int, mixed>
Decode a receiving payload.
sendToSecondary()  : string
Send a payload from the primary server to the secondary server.

Methods

decodePayload()

Decode a receiving payload.

public decodePayload(non-empty-string $jwt) : array<string|int, mixed>

The payload is signed and will expire automatically in 5 min.

Parameters
$jwt : non-empty-string

The payload encoded as a JWT

Tags
since
34.0.3
Return values
array<string|int, mixed>

The original payload as sent by IGlobalScaleService::sendToSecondary

sendToSecondary()

Send a payload from the primary server to the secondary server.

public sendToSecondary(IUser $user, non-empty-string $path, array<string|int, mixed> $payload) : string

The payload will be signed and will expire automatically in 5 min. The payload can then be decoded on the receiving end with IGlobalScaleService::decodePayload().

Parameters
$user : IUser
$path : non-empty-string
$payload : array<string|int, mixed>
Tags
throws
Exception

When unable to send the payload.

since
34.0.3
Return values
string

The url of the secondary

On this page

Search results