compression

package module
v0.0.0-...-a54b27e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 4, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

README

xk6-compression

Compression tools for k6.

Supported compression algorithms:

  • Zstandard

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ToNativeBytes

func ToNativeBytes(rt *sobek.Runtime, bytes sobek.Value) []byte

convert Sobek array to Go byte array

Types

type Compression

type Compression struct {
	// contains filtered or unexported fields
}

func (*Compression) ZstdCompress

func (m *Compression) ZstdCompress(data sobek.Value) sobek.Value

func (*Compression) ZstdDecompress

func (m *Compression) ZstdDecompress(compressed sobek.Value) sobek.Value

type ModuleInstance

type ModuleInstance struct {
	// contains filtered or unexported fields
}

ModuleInstance represents an instance of the JS module.

func (*ModuleInstance) Exports

func (mi *ModuleInstance) Exports() modules.Exports

Exports implements the modules.Instance interface and returns the exported types for the JS module.

type RootModule

type RootModule struct{}

RootModule is the global module instance that will create module instances for each VU.

func New

func New() *RootModule

New returns a pointer to a new RootModule instance.

func (*RootModule) NewModuleInstance

func (*RootModule) NewModuleInstance(vu modules.VU) modules.Instance

NewModuleInstance implements the modules.Module interface returning a new instance for each VU.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL