Commit Graph

19 Commits

Author SHA1 Message Date
Nathan Harris 556da6475f 56 -- Add ByteToMessageDecoderVerifier unit tests 2019-07-28 20:05:14 -07:00
Nathan Harris ce43dad72e Split tests into two targets: Unit tests and Integration tests
Motivation:

For users looking to contribute, and for those looking to validate the library, it was unclear what tests require an actual connection to a Redis instance in order to run.

Modifications:

Add a `RediStackIntegrationTests` that takes all tests that require a Redis instance in order to run.

Result:

Those looking to run just unit tests, or contribute new tests, can now directly point to a specific testTarget as defined in the Package manifest.
2019-07-28 00:09:19 -07:00
Nathan Harris aeae1f6c78 Properly export module 2019-07-10 22:46:20 -07:00
Nathan Harris 7e7e354697 61 -- Rebrand from RedisNIO to RediStack 2019-07-08 19:45:33 -07:00
Nathan Harris cd9bd04f73 Revisit RESPValue and RESPValueConvertible implementations.
Motivation:

Johannes provided a fair code review of the project and summarized his findings in issue #48, and one of the prime offenders was all of the `unsafe*` APIs (pointers, buffers, bytes)
that were used with `RESPValue` and `RESPValueConvertible`.

He also provided great feedback and pointed out good points of confusion with the API design of `RESPValue` and `RESPValueConvertible`.

Modifications:

- Return to using `Array` instead of `ContiguousArray` for `RESPValue.array` storage
- Update all documentation to be more thorough in explaining how the types should be used and conformed to.
- Remove all uses of `unsafe*` APIs where possible
- Change implementations to be a lot more type and memory safe, double checking assumptions
- Remove conformance to `ExpressibleBy*Literal` as it is too easy for users to shoot themselves in the foot and saves only a few characters over `.init(bulk:)`
- Create new `RedisNIOTestUtils` target for common test extensions, making them public
- Move most almost all implementations of `RESPValue` computed properties into the `RESPValueConvertible` conformances

Result:

Users should be more safeguarded by the API against unknowingly getting incorrect `RESPValue` representations, the API design of `RESPValue` and `RESPValueConvertible` should be much clearer,
and memory safety should be at a higher bar from these changes.

This resolves issues #55 & #48, and contributes to issue #47.
2019-07-02 23:19:15 -07:00
Nathan Harris dfbccf4c07 Rename package to match repo
Motivation:

SE-0226 changes how SPM resolves a dependency graph and as part of the accepted proposal was to require package names to match their repo URL segments.

Modifications:

Change package from `redis-nio` to `swift-redis-nio-client`

Result:

The project should compliant with SE-0226: https://github.com/apple/swift-evolution/blob/master/proposals/0226-package-manager-target-based-dep-resolution.md
2019-06-06 15:10:59 -07:00
Nathan Harris e81f9546d1 Rename NIORedis to RedisNIO
Motivation:

The SSWG has identified a fast approaching reality of namespace clashes in SPM within the ecosystem and has proposed a rule on names that `NIORedis` no longer complies with.

Modifications:

All references to `NIORedis` have been switched to `RedisNIO` as this module name is unique (at least within GitHub's public repositories).

The goals for this name are as follows:

1. To indicate that this is a Redis client library that is built with SwiftNIO
2. That it is a lower level library, as it directly exposes SwiftNIO as an implementation detail
    2a. The idea being that a higher level library (`Redis`) will be used, and to "go one level deeper" in the stack, you append the "deeper" `NIO` postfix
3. It follows a naming pattern adopted by Vapor who has expressed their desire to adopt this library as their Redis implementation

Result:

A repository, package name, and module name that are unique across GitHub's public repositories that achives the goals outlined above.
2019-06-06 09:55:08 -07:00
Nathan Harris 1a9f086c68 Add SwiftMetrics Dependency
This will eventually support issue #40
2019-05-17 18:34:45 -07:00
Nathan Harris c7a606d8a6 Add Copyright Notices, Acknowledgements, and Contributors List 2019-05-01 16:24:05 -07:00
Nathan Harris ed106a943f Update to use official release of SwiftLog 2019-04-10 11:33:52 -07:00
Nathan Harris 869625d47d Update to use NIO 2 2019-03-26 08:46:51 -07:00
Nathan Harris 73d5930f34 Add initial swift-log support for most paths
Closes #14
2019-03-18 22:04:47 -07:00
Nathan Harris 5c32b97a0c Remove DispatchRedis 2019-03-17 14:06:21 -07:00
Nathan Harris 915b620fa3 Update package description for Swift 5.0 2019-01-10 11:56:17 -08:00
Nathan Harris 473bdcbeed Clarify module and project names 2019-01-09 12:44:41 -08:00
Nathan Harris 58ac3c1298 Add basic non-NIO wrappers for Redis 2018-12-22 16:22:04 -08:00
Nathan Harris 99463bfcd1 Use SwiftNIO 2.0 development 2018-12-18 22:56:00 -08:00
Nathan Harris 7b1d2b46c5 Update package name and remove license 2018-12-18 21:55:15 -08:00
Nathan Harris 29160cd308 Initial project files commit 2018-12-13 13:34:30 -08:00