Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate to Cats-Effect 3.x #155

Merged
merged 6 commits into from
Mar 12, 2023
Merged

Migrate to Cats-Effect 3.x #155

merged 6 commits into from
Mar 12, 2023

Conversation

danicheg
Copy link
Member

No description provided.

@danicheg
Copy link
Member Author

@armanbilge Wouldn't you mind glancing at this few-liner?...

build.sbt Outdated
@@ -40,11 +35,11 @@ lazy val core = project
libraryDependencies ++= Seq(
"org.typelevel" %% "cats-core" % catsV,
"org.typelevel" %% "cats-effect" % catsEffectV,
"io.chrisdavenport" %% "random" % "0.0.2",
"io.chrisdavenport" %% "mapref" % "0.1.1",
"io.chrisdavenport" %% "mapref" % "0.2.1",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have MapRef in CE std now, I wonder if this dependency is still needed?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left it since there is a version of mapref on CE 3 from io.chrisdavenport, and have removed random since it lacks CE 3 support. But yeah, let's migrate that one too 👍🏻

numShards: Int = 4,
numBytes: Int = 32 // The session ID length must be at least 128 bits (16 bytes)
// numBytes is entropy / 2 SecureRandom
): F[SessionStore[F, A]] = for {
random <- Random.javaSecuritySecureRandom(numShards)
random <- SecureRandom.javaSecuritySecureRandom(numShards)
ref <- MapRef.ofShardedImmutableMap[F, SessionIdentifier, A](numShards)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think this one is in CE now :)

@danicheg
Copy link
Member Author

It is good to go, I suppose. Arman, thanks for reviewing. If something has to be changed, I will do a follow-up PR doubtless.

@danicheg danicheg merged commit 63d765b into http4s:main Mar 12, 2023
@danicheg danicheg deleted the ce3 branch March 12, 2023 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants