Maintenance release:
- Update libuv to v1.42.0, rewrite
UV_Stream
'sOutput
instance to perform auv_try_write
first since nowuv_try_write
is sensible.
- Clean function names in
Z.IO.BIO
module, now noBIO
orNode
suffix anymore. Z.IO.BIO
is not re-exported fromZ.IO
anymore, user are recommended to import it with qualified name, e.g.import qualified Z.IO.BIO as BIO
.- Add
foldl'
andfoldIO'
toZ.IO.BIO
to use withFold
andFoldM
fromfoldl
package. - Add
INLINABLE
pragmas to many functions. - Add
printStdLnP
toZ.IO.StdStream
, aParser
debug tool.
- Remove
-march=native
flag to improve binary portability.
- Add
getInterface
toZ.IO.Network
. mkstemp
now return opend file, the type changed tomkstemp :: CBytes -> CBytes -> Bool -> Resource (CBytes, File)
, which has an option for keep file or not.initTempFile
andinitTempDir
now do not need a prefix argument, the prefix is hardcoded asZ-IO-
.
This is an experimental version to test new 'BIO' module.
- Rewrite
Z.IO.BIO
module, nowBIO
is push based. - Remove
>|>
,>~>
,>!>
, nowBIO
nodes can be composed via funtion composition(.)
! - Remove
zipSource/zipBIO
, addstepBIO/stepBIO_/runBIO_
. - Add
zipBIO
toZ.IO.BIO.Concurrent
, which run two BIO nodes concurrently. - Add
ungroupingNode
, changenewGroupingNode
to useVector
. - Rename
EOF
exception toUnexpectedEOF
to avoid the clash withEOF
pattern.
- Use
CPtr
from Z-Data instead ofForeignPtr
.
- Change resource
Pool
to keyed by default, addSimplePool
. - Add
Semigroup
instance toLogger
. - Add
clearInputBuffer/clearOutputBuffer
toZ.IO.Buffered
. - Add
catchSync/ingoreSync
toZ.IO.Exception
. - Add
putStdLn/printStdLn
back.
- Add
initProcess'
to kill process while finish using the process resource by default.
- Split
Z.IO.UV.FFI
toZ.IO.UV.FFI
andZ.IO.UV.FFI_Env
, to make the module buildable when memory is constrained. - Make functions works on TTY in
Z.IO.StdStream
correctly ignore redirected streams. - Move
pathSeparator
topathSeparators
, nowpathSeparator
return the default path separator.
- Hide
Logger
constructor fromZ.IO.Logger
, remove implementation details such asdefaultTSCache
,pushLogIORef
,flushLogIORef
, addloggerFormatter
toLoggerConfig
. - Add
newStdLogger/newFileLogger
to make new logger easily. - Rework
Z.IO.FileSystem.Watch
's API, changewatchDirs
to accept a recursive param and a callback. - Hide
Z.IO.UV.Win
module, which should not be directly used by user. - Fix a bug when stdio is redirected to pipes: #16
- Fix a bug in
newMagicSplitter/newLineSplitter
code. - Remove
sourceFromInput
and related functions to reduce API surface, usenewBufferedInput
withsourceFromBuffered
instead. - Refactor server loop to allow more code sharing between
Z.IO.Network.TCP
andZ.IO.Network.IPC
.
- FileSystem: replace
DEFAULT_MODE
withDEFAULT_FILE_MODE
&DEFAULT_DIR_MODE
. - Ignore exception while
mkdirp
on an exist directory. - Make
rmrf
more likerm -rf
, which can be used on files. - Add
doesPathExist/doesFileExist/doesDirExist
to file system module. - Add
Z.IO.FileSystem
re-exportZ.IO.FileSystem.Watch
andZ.IO.FileSystem.FilePath
. - Add
mkstemp
,initTempFile/initTempDir
to file system module.
- Add
unwrap/unwrap'
toZ.IO.Exception
. - Add
readParseChunks
toZ.IO.Buffered
, ChangereadParser
's type to matchreadParseChunks
. - Add
sourceParseChunksBufferedInput
,sourceParseChunksInput
toZ.IO.BIO
. - Add
newJSONLogger/defaultJSONFmt
toZ.IO.Logger
, provide simple JSON structured logging.
- Add
getSystemTime'
toZ.IO.Time
. - Add
shutdownUVStream
toZ.IO.UV.UVStream
. - Change
sourceFrom/sinkToFile
toinitSourceFrom/initSinkToFile
. - Bump
Z-Data
version.
- Add
sourceParsedBufferInput
and JSON sources toZ.IO.BIO
. - Fix
readLine
andnewLineSplitter
. - Improve low resolution timer precision.
- Fix a bug in
Z.IO.FileSystem.FilePath.relative
, see #17.
- Clean up API in
Z.IO.Buffered
, removereadToMagic'
,readLine'
,readExactly'
. readExactly
now throw exception when not reading enough bytes before EOF.- Add
Show/ShowT
instance toUVStream
,StdStream
,UDP
,UVManager
. - Add JSON instance to various types:
SocketAddr
and all configure types. - Rename
InetAddr
toIPv4
,Inet6Addr
toIPv6
, changeSocketAddr
's constructor name, and payload order. - Add
seek
toZ.IO.FileSystem
.
- Export
ZStream
type fromZ.IO.BIO.Zlib
- Remove type index from
BufferedInput
,BufferedOutput
. - Add
Z.IO.BIO
module to facilitate streaming process, andZ.IO.BIO.Concurrent
to facilitate producer-consumer model. - Remove streamming related functions from
Z.IO.Buffered
, useZ.IO.BIO
instead. - Move
Z.IO.Compression.Zlib
toZ.IO.BIO.Zlib
, change API toBIO
style. - Add
Z.IO.FileSystem.Watch
module, provides cross-platform filesystem watching.
- Add
iso8016DateFormat
, change logger's default time format to include time zone. - Rename
warn
towarning
, changeLevel
toInt
type alias inZ.IO.Logger
, addcritical
. - Export
TimeVal
fromZ.IO.Environment
. - Add
getCPUInfo
,getLoadAvg
,getXXXMem
toZ.IO.Environment
.
- Export
ResUsage
fromZ.IO.Environment
. - Export
Level
fromZ.IO.Logger
. - Add linefeed with default logger formattor.
- Fix a bug affects udp exception raising(simliar to the one fixed in 0.1.5.2).
- Add
Z.IO.StdStream.Ansi
module, add a default colored logger. - Add
Z.IO.Time
module, for fast time parsing and formatting. - Add
Z.IO.FileSystem.FilePath
module for file path manipulations. - Add
getCWD
,chDir
,getHomeDir
,getTempDir
,getPassWD
toZ.IO.Environment
. - Add
chown
,fchown
,lchown
toZ.IO.FileSystem
andZ.IO.FileSystem.Threaded
. - Rename
UVFD
toFD
accross module.
- Fix windows dist(add
fs-fd-hash-inl.h
to other-source-files).
- Export
ProcessFlag
fromZ.IO.Process
. - Add quick read & write functions to fileSystem modules.
- Fix a bug: when exception raise from server loop an uninitialized uv_check_t is closed.
- Update libuv's version to 1.40.1.
- Change
IOEInfo
type to useText
instead ofCBytes
.
- Add
Z.IO.Process
module. - Move many flag type to type alias from newtype, adjust patterns haddock.
- Sync IPC's server API to TCP's.
- Add
Z.IO.Environment
module. - Add various instances to data types in
Z.IO.UV.FFI
. - Fix a UDP batch receiving bug.
- Remove
UV
prefix in config data types(Z.IO.FileSystem
,Z.IO.UDP
). - Change
TCP
,IPC
server config, move server worker to start params instead of config. Logger
type rework, colorful logger are possible.
- Rename
newBufferedInput/Output
tonewBufferedInput'/Output'
, add default chunknewBufferedInput/Output
. - Remove
ghc-pirm
depends. - Make library works with GHC 8.6 and 8.8 again.
- Add file offset interface back, see
FilePtr
andFilePtrT
. - Remove
checkFileTClosed
fromZ.IO.FileSystem.Threaded
. - Take c source file list from libuv Makefile, remove lib requirements on linux and osx.
- Fix
uv_check_t
initiate order in accept loop, which cause a segfault.
- Fix macOS build problem caused by missing zconf.h.
- Add more tests(TCP, IPC).
- Add stream utilities to
Z.IO.Buffered
. - Add
Z.Compression.Zlib
.