Skip to content

Commit 0848475

Browse files
committed
Merge remote-tracking branch 'origin/master' into try-tapFailure
2 parents 3afdbe9 + 8f8ceee commit 0848475

File tree

41 files changed

+1164
-534
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+1164
-534
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,14 @@ on:
1616

1717
env:
1818
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19-
REDIS_VERSION: 6.2.12
2019

2120
jobs:
2221
build:
2322
name: Build and Test
2423
strategy:
2524
matrix:
2625
os: [ubuntu-latest]
27-
scala: [2.13.14]
26+
scala: [2.13.16]
2827
java: [temurin@17, temurin@21]
2928
runs-on: ${{ matrix.os }}
3029
steps:
@@ -52,12 +51,6 @@ jobs:
5251
- name: Setup sbt
5352
uses: sbt/setup-sbt@v1
5453

55-
- name: Cache Redis
56-
uses: actions/cache@v2
57-
with:
58-
path: ./redis-${{ env.REDIS_VERSION }}
59-
key: ${{ runner.os }}-redis-cache-v2-${{ env.REDIS_VERSION }}
60-
6154
- name: Setup Node.js
6255
uses: actions/setup-node@v2
6356
with:
@@ -69,9 +62,6 @@ jobs:
6962
mongodb-version: 7.0
7063
mongodb-replica-set: test-rs
7164

72-
- name: Setup Redis
73-
run: ./install-redis.sh
74-
7565
- name: Check that workflows are up to date
7666
run: sbt '++ ${{ matrix.scala }}' githubWorkflowCheck
7767

@@ -85,7 +75,7 @@ jobs:
8575
strategy:
8676
matrix:
8777
os: [ubuntu-latest]
88-
scala: [2.13.14]
78+
scala: [2.13.16]
8979
java: [temurin@17]
9080
runs-on: ${{ matrix.os }}
9181
steps:

.scala-steward.conf

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
pullRequests.grouping = [
2+
{
3+
name = "jetty",
4+
title = "Update Jetty dependencies",
5+
filter = [{ group = "org.eclipse.jetty" }, { group = "org.eclipse.jetty*" }]
6+
}
7+
]

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
[`OptRef`](http://avsystem.github.io/scala-commons/api/com/avsystem/commons/misc/OptRef.html) (implemented as value
3434
classes)
3535
* [Components](docs/Components.md) and Dependency Injection library
36-
* `commons-redis` - [Scala driver for Redis](docs/RedisDriver.md)
36+
* `commons-redis` (DEPRECATED) - [Scala driver for Redis](docs/RedisDriver.md)
3737
* `commons-macros` contains implementations of macros used in other modules and reusable macro utilities:
3838
* `MacroCommons` trait with several convenience functions for implementing macros
3939
* `TypeClassDerivation` - implements infrastructure for automatic type class derivation

analyzer/src/main/scala/com/avsystem/commons/analyzer/AnalyzerPlugin.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ final class AnalyzerPlugin(val global: Global) extends Plugin { plugin =>
7070
private object component extends PluginComponent {
7171
val global: plugin.global.type = plugin.global
7272
val runsAfter = List("typer")
73-
override val runsBefore = List("patmat", "silencer")
73+
override val runsBefore = List("patmat")
7474
val phaseName = "avsAnalyze"
7575

7676
import global._

benchmark/js/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
How to run benchmark:
2+
- compile `sbt commons-benchmark-js/fullOptJS`
3+
- open `fullopt-2.13.html` file in a browser
4+
- select test suite and run

benchmark/js/src/main/scala/com/avsystem/commons/ser/JsonBenchmarks.scala

Lines changed: 33 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ package com.avsystem.commons
22
package ser
33

44
import com.avsystem.commons.serialization.json.{JsonStringInput, JsonStringOutput}
5+
import com.avsystem.commons.serialization.nativejs.{NativeJsonInput, NativeJsonOutput}
56
import io.circe.parser._
67
import io.circe.syntax._
78
import japgolly.scalajs.benchmark.gui.GuiSuite
@@ -10,62 +11,86 @@ import japgolly.scalajs.benchmark.{Benchmark, Suite}
1011
object JsonBenchmarks {
1112
val suite = GuiSuite(
1213
Suite("JSON serialization benchmarks")(
13-
Benchmark("Writing case class: GenCodec") {
14+
Benchmark("Writing case class: GenCodec, String Json format") {
1415
JsonStringOutput.write(Something.Example)
1516
},
17+
Benchmark("Writing case class: GenCodec, Native Json format") {
18+
NativeJsonOutput.writeAsString(Something.Example)
19+
},
1620
Benchmark("Writing case class: Circe") {
1721
Something.Example.asJson.noSpaces
1822
},
1923
Benchmark("Writing case class: uPickle") {
2024
upickle.default.write(Something.Example)
2125
},
22-
Benchmark("Reading case class: GenCodec") {
26+
Benchmark("Reading case class: GenCodec, String Json format") {
2327
JsonStringInput.read[Something](Something.ExampleJsonString)
2428
},
29+
Benchmark("Reading case class: GenCodec, Native Json format") {
30+
NativeJsonInput.readString[Something](Something.ExampleJsonString)
31+
},
2532
Benchmark("Reading case class: Circe") {
2633
decode[Something](Something.ExampleJsonString).fold(e => throw e, identity)
2734
},
2835
Benchmark("Reading case class: uPickle") {
2936
upickle.default.read[Something](Something.ExampleJsonString)
3037
},
3138

32-
Benchmark("Writing sealed hierarchy: GenCodec") {
39+
Benchmark("Writing sealed hierarchy: GenCodec, String Json format") {
3340
JsonStringOutput.write(SealedStuff.ExampleList)
3441
},
35-
Benchmark("Writing sealed hierarchy: GenCodec (flat)") {
42+
Benchmark("Writing sealed hierarchy: GenCodec (flat), String Json format") {
3643
JsonStringOutput.write(FlatSealedStuff.ExampleList)
3744
},
45+
Benchmark("Writing sealed hierarchy: GenCodec, Native Json format") {
46+
NativeJsonOutput.writeAsString(SealedStuff.ExampleList)
47+
},
48+
Benchmark("Writing sealed hierarchy: GenCodec (flat), Native Json format") {
49+
NativeJsonOutput.writeAsString(FlatSealedStuff.ExampleList)
50+
},
3851
Benchmark("Writing sealed hierarchy: Circe") {
3952
SealedStuff.ExampleList.asJson.noSpaces
4053
},
4154
Benchmark("Writing sealed hierarchy: uPickle") {
4255
upickle.default.write(SealedStuff.ExampleList)
4356
},
44-
Benchmark("Reading sealed hierarchy: GenCodec") {
57+
Benchmark("Reading sealed hierarchy: GenCodec, String Json format") {
4558
JsonStringInput.read[List[SealedStuff]](SealedStuff.ExampleJsonString)
4659
},
47-
Benchmark("Reading sealed hierarchy: GenCodec (flat)") {
60+
Benchmark("Reading sealed hierarchy: GenCodec (flat), String Json format") {
4861
JsonStringInput.read[List[FlatSealedStuff]](FlatSealedStuff.ExampleJsonString)
4962
},
63+
Benchmark("Reading sealed hierarchy: GenCodec, Native Json format") {
64+
NativeJsonInput.readString[List[SealedStuff]](SealedStuff.ExampleJsonString)
65+
},
66+
Benchmark("Reading sealed hierarchy: GenCodec (flat), Native Json format") {
67+
NativeJsonInput.readString[List[FlatSealedStuff]](FlatSealedStuff.ExampleJsonString)
68+
},
5069
Benchmark("Reading sealed hierarchy: Circe") {
5170
decode[List[SealedStuff]](SealedStuff.ExampleJsonString).fold(e => throw e, identity)
5271
},
5372
Benchmark("Reading sealed hierarchy: uPickle") {
5473
upickle.default.read[List[SealedStuff]](SealedStuff.ExampleUpickleJsonString)
5574
},
5675

57-
Benchmark("Writing foos: GenCodec") {
76+
Benchmark("Writing foos: GenCodec, String Json format") {
5877
JsonStringOutput.write(Foo.ExampleMap)
5978
},
79+
Benchmark("Writing foos: GenCodec, Native Json format") {
80+
NativeJsonOutput.writeAsString(Foo.ExampleMap)
81+
},
6082
Benchmark("Writing foos: Circe") {
6183
Foo.ExampleMap.asJson.noSpaces
6284
},
6385
Benchmark("Writing foos: uPickle") {
6486
upickle.default.write(Foo.ExampleMap)
6587
},
66-
Benchmark("Reading foos: GenCodec") {
88+
Benchmark("Reading foos: GenCodec, String Json format") {
6789
JsonStringInput.read[Map[String, Foo]](Foo.ExampleJsonString)
6890
},
91+
Benchmark("Reading foos: GenCodec with Native Json format") {
92+
NativeJsonInput.readString[Map[String, Foo]](Foo.ExampleJsonString)
93+
},
6994
Benchmark("Reading foos: Circe") {
7095
decode[Map[String, Foo]](Foo.ExampleJsonString).fold(e => throw e, identity)
7196
},

benchmark/jvm/src/main/scala/com/avsystem/commons/redis/EncodingBenchmark.scala

Lines changed: 0 additions & 40 deletions
This file was deleted.

benchmark/jvm/src/main/scala/com/avsystem/commons/redis/Profiled.scala

Lines changed: 0 additions & 18 deletions
This file was deleted.

0 commit comments

Comments
 (0)