Skip to content

Releases: salient-labs/toolkit

v0.99.50

11 Sep 06:03
v0.99.50
44ccf2b

Choose a tag to compare

Changed

Contract

  • Simplify StreamWrapper and related interfaces

Cache

  • Remove problematic $maxAge parameters from cache store methods
  • Rename getAllKeys() to getItemKeys() for consistency
  • Rename CacheStoreInterface to CacheInterface

v0.99.49

10 Sep 08:01
v0.99.49
21e9dd1

Choose a tag to compare

Added

Contract

  • Add StreamWrapper, an abstraction of the streamWrapper prototype class described in the PHP manual

Curler

  • Add CurlerPageRequest and allow it to be returned from CurlerPagerInterface::getFirstRequest() to minimise query string deserialization between requests
  • Add CurlerPage methods getCurrent() and getTotal(), which return $current and $total values passed to __construct(), so progress can be tracked across responses if needed
  • Add AbstractRequestException and AbstractResponseException to API so middleware can extend them

Testing (new)

  • Add MockPhpStream
  • Add MockTarget (from Console)

Changed

Curler

  • In CurlerPagerInterface::getPage(), add $response and $query parameters to simplify pager code and improve consistency
  • Move isLastPage() and getNextRequest() from CurlerPageInterface to CurlerPageRequestInterface and extend the latter from the former
  • Replace isLastPage() with hasNextRequest()

Sli

  • Review sli subcommand names

Sync

  • Move SendHttpRequest from Sli to Sync, rename it to SendHttpSyncProviderRequest, and refactor for consistency
  • Rename GetSyncEntities to GetSyncEntity for consistency

Removed

Console

  • Remove ConsoleInvalidTargetException

Curler

  • Remove redundant HttpErrorExceptionInterface::getStatusCode() and isNotFoundError() methods

Fixed

Curler

  • Fix Curler issue where initial query is not passed to pagers
  • Fix Curler pagination issue where entities are returned with the same keys for each page of data

Sync

  • Fix SyncEntityProvider issue where upstream iterator keys are preserved unnecessarily, leading to possible data loss

v0.99.48

06 Sep 09:45
v0.99.48
a461a13

Choose a tag to compare

Added

Container

  • Add application method getHarFilename()

Changed

Container

  • In application method exportHar():
    • Defer creation of HAR file until first Curler request
    • Allow $uuid to be given via callback (e.g. to match Sync::getRunUuid())

Curler

  • Add optional $event parameter to CurlerHarRecorder::start()

Fixed

Http

  • Fix OAuth2Client issue where a stale JWKS may not be refreshed
  • Fix HttpHeaders issue where getLines() returns unsorted headers after the collection is sorted or reversed
  • Add and implement HttpHeadersInterface::canonicalize() to resolve issue where HttpHeaders::getLines() may return headers in an order not compliant with [RFC7230]

v0.99.47

05 Sep 03:33
v0.99.47
82fa865

Choose a tag to compare

Changed

Console

  • Adopt "^ " instead of "? " as the default warning message prefix

Curler

  • Rename CurlerHttpArchiveRecorder to CurlerHarRecorder
  • Follow Location headers in Curler instead of enabling cURL's CURLOPT_FOLLOWLOCATION option
    • This allows CurlerHarRecorder to be used when following redirects
    • It will also allow redirect behaviour, including caching, to be customised in a future release
  • Throw TooManyRedirectsException if MaxRedirects is exceeded in Curler
  • Improve cache stability by serializing header values, not HttpHeaders instances, when caching responses in Curler
  • Don't silently remove query and fragment from request URI in Curler::withRequest()
    • An exception is now thrown if the given URI has a query or fragment

Fixed

Curler

  • Fix issue where Curler response cache resolves equivalent requests separately if one has an empty path and the other path is "/"
  • Fix Curler issue where HTTP error responses are cached if they are not thrown
  • Fix Curler issue where request bodies larger than 2MiB are not rewound when they are retried after "429 Too Many Requests"
    • An exception is now thrown if a request body cannot be rewound after redirection or "429 Too Many Requests"
  • Fix Curler issue where multiple response bodies may be returned as one when a request is retried after "429 Too Many Requests"

v0.99.46

02 Sep 13:06
v0.99.46
23218f6

Choose a tag to compare

Added

Container

  • Add application method exportHar()

Curler

  • Add CurlerHttpArchiveRecorder
  • Add, implement and dispatch Curler request and response events
  • Add and implement Curler exception interfaces
  • Add Curler method getFormDataFlags()

Http

  • Add Http::replaceQuery()

Changed

Container

  • Rename methods:
    • ContainerInterface::unbindInstance() -> removeInstance()
    • ApplicationInterface::syncNamespace() -> registerSyncNamespace()
  • In Application:
    • Use var/lib/config and var/lib/data instead of config and var/lib as default config and data directories
    • Use $_SERVER['REQUEST_TIME_FLOAT'] to calculate elapsed time
    • Throw an exception if logOutput() is called multiple times
  • Update ApplicationInterface::registerShutdownReport() parameters for consistency

Curler

  • Replace CurlerInterface::getUriWithQuery() with replaceQuery()

Http

  • Build out jsonSerialize() methods
  • Rename Http::applyToQuery() to mergeQuery()

Removed

Curler

  • CurlerFile: remove unused getCurlFile() method

Fixed

File

  • In File::maybeOpen(), always set $uri if null

v0.99.45

28 Aug 04:34
v0.99.45
8a7508c

Choose a tag to compare

Added

Sync

  • Add and implement new exception interfaces:
    • HeartbeatCheckFailedExceptionInterface
    • SyncOperationNotImplementedExceptionInterface
    • UnreachableBackendExceptionInterface

Utility

  • Add $trim arguments to Format::list() and Format::array()

Changed

Sync

  • Move Http- and Db-specific classes to their own namespaces
  • Rename exception classes for consistency:
    • SyncFilterPolicyViolationException -> FilterPolicyViolationException
    • SyncInvalidFilterException -> InvalidFilterException
    • SyncInvalidFilterSignatureException -> InvalidFilterSignatureException
    • SyncProviderBackendUnreachableException -> UnreachableBackendException
    • SyncProviderHeartbeatCheckFailedException -> HeartbeatCheckFailedException

Removed

Sync

  • Remove unused SyncInvalidRequestException

Fixed

Sync

  • Fix issue where HttpSyncDefinition fails to pass payloads applied via withArgs() to READ or READ_LIST operations regardless of the HTTP method they resolve to
  • Fix HttpSyncDefinition issue where context values are claimed as if they are filters

v0.99.44

26 Aug 07:16
v0.99.44
92a6ef9

Choose a tag to compare

Added

  • Add PHPStan extension for Arr::flatten()

v0.99.43

24 Aug 04:28
v0.99.43
010f2e5

Choose a tag to compare

Fixed

  • Fix PHP 8.4 Implicitly marking parameter as nullable is deprecated notice

v0.99.42

22 Aug 09:55
v0.99.42
b1718d2

Choose a tag to compare

Added

Utility

  • Add optional $nullEmpty parameter to Arr::trim() so empty strings can be replaced with null instead of being removed

Changed

Cli

  • Fall back to defaults when _man or _md commands receive empty arguments

Fixed

Cli

  • Fix issue where long synopses cause Markdown usage information with man page extensions to be generated with unwanted line breaks

Console

  • Fix inconsistent newline handling in ConsoleFormatter

v0.99.41

14 Aug 06:22
v0.99.41
c64322f

Choose a tag to compare

Added

Http

  • Add Http::applyToQuery() for simple manipulation of query strings in URIs

Changed

Core

  • Move Graph from Iterator to Core and refactor
    • Allow Graph to be extended
    • Rename Graph::inner() to getValue()
    • Don't create missing properties or array keys on Graph::offsetGet() unless enabled via new constructor parameters
    • Add and implement GraphInterface

Removed

Core

  • Remove Graph::with() and Graph::from()