Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/disneystreaming/smithy4s
https://disneystreaming.github.io/smithy4s/
https://github.com/disneystreaming/smithy4s
codegen http json scala scala-js scala-native smithy xml
Last synced: 3 months ago
JSON representation
https://disneystreaming.github.io/smithy4s/
- Host: GitHub
- URL: https://github.com/disneystreaming/smithy4s
- Owner: disneystreaming
- License: other
- Created: 2021-12-22T10:28:32.000Z (almost 3 years ago)
- Default Branch: series/0.18
- Last Pushed: 2024-04-12T13:38:30.000Z (7 months ago)
- Last Synced: 2024-04-13T16:31:32.197Z (7 months ago)
- Topics: codegen, http, json, scala, scala-js, scala-native, smithy, xml
- Language: Scala
- Homepage:
- Size: 20.6 MB
- Stars: 324
- Watchers: 15
- Forks: 62
- Open Issues: 73
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
- awesome-smithy - Scala - Community plugin for generation of clients/servers in Scala. (Code Generators / Server Code Generators)
README
[![CI](https://github.com/disneystreaming/smithy4s/actions/workflows/ci.yml/badge.svg)](https://github.com/disneystreaming/smithy4s/actions/workflows/ci.yml)
[![smithy4s-core Scala version support](https://index.scala-lang.org/disneystreaming/smithy4s/smithy4s-core/latest-by-scala-version.svg)](https://index.scala-lang.org/disneystreaming/smithy4s/smithy4s-core)
[![CLA assistant](https://cla-assistant.io/readme/badge/disneystreaming/smithy4s)](https://cla-assistant.io/disneystreaming/smithy4s)
[![Discord](https://img.shields.io/discord/1045676621761347615.svg?label=&logo=discord&logoColor=ffffff&color=404244&labelColor=6A7EC2)](https://discord.gg/wvVga94s8r)
# smithy4s## Usage
**For usage information, check out the [Documentation](https://disneystreaming.github.io/smithy4s/)**
## Benchmarks
There's a module with benchmarks to compare against the handcrafted implementations of an http4s with the generic ones run the benchmarks, one should execute:
```sh
sbt benchmark / Jmh / run
```To run http4s benchmarks:
```sh
benchmark / Jmh / run .*Http4sBenchmark.*
```To benchmark with Scala 2.12 version instead of 2.13, use `benchmark2_12 / Jmh / run` instead.
Smithy4s makes use of [YourKit Java Profiler](https://www.yourkit.com/java/profiler/) for performance optimisation.
![YourKit Logo](https://www.yourkit.com/images/yklogo.png)## Development environment
For the easiest setup of development tools, use [Nix](https://nixos.org).
The recommended way is to use `nix develop` (requires Flakes support, available since Nix 2.4 - read on if you don't use that experimental feature):
```bash
nix develop
```This will load all required packages into your shell. Run `exit` or press `ctrl+d` to clear it.
If you're a [direnv](https://github.com/nix-community/nix-direnv) user, we have that too.
If you don't have Flakes support:
```bash
nix-shell
```## Note for metals/bloop users
Smithy4s is a complex project with a heavy build-matrix. In order to ease development, we've elected to only enable bloop-config generation
for the `JVM/Scala 2.13` combo of build axes, by default.If you find yourself developing for another combination of build axes, it is possible to tweak the default by adding a `user.sbt` file in the root directory of your clone of this project, and fill it by following this example :
```scala
ThisBuild / bloopAllowedCombos := Seq(
Seq(
VirtualAxis.jvm,
VirtualAxis.scalaABIVersion("3.3.0")
)
)
```## Note for .sbtopts
You usually should use `.sbtopts` to add some more memory for `sbt`, as Smithy4s is complex. You copy the `.sbtopts.example` to `.sbtopts` and adjust the values to your needs:
```bash
cp .sbtopts.example .sbtopts
```