Documentation

Service
in package

Wrapper handling boilerplate code around the ARCHE microservice initialization

Requires following config file structure:

dissCacheService:
  db: sqlite:/some/path
  log:
    file: /some/path
    level: debug
   ttl:
     resource: 3600
     response: 31536000
   repoDb:
   - repoConfigPath.yaml
   allowedNmsp:
   - https://one
   - https://another
   metadataMode: parents
   parentProperty: ""
   resourceProperties: []
   relativesProperties: []
Tags
author

zozlak

Table of Contents

Properties

$cacheDb  : CachePdo
$clbck  : callable
$config  : object
$log  : Log

Methods

__construct()  : mixed
getConfig()  : object
getLog()  : Log
processException()  : ResponseCacheItem
serveRequest()  : ResponseCacheItem
setCallback()  : void

Properties

Methods

__construct()

public __construct(string $confFile) : mixed
Parameters
$confFile : string

getConfig()

public getConfig() : object
Return values
object

getLog()

public getLog() : Log
Return values
Log

serveRequest()

public serveRequest(string $id, array<string|int, mixed> $param[, bool $clearCache = false ]) : ResponseCacheItem
Parameters
$id : string
$param : array<string|int, mixed>
$clearCache : bool = false
Return values
ResponseCacheItem

setCallback()

public setCallback(callable $clbck) : void
Parameters
$clbck : callable

response cache miss handler with signature fn(acdhOeaw\arche\lib\RepoResourceInterface $res, array $param) where the $param will passed from the serveRequest() method $param parameter.


        
On this page

Search results