Upgrading
Sections run newest first: start at the top and read down to the section for the release after the one you are on. Each lists what the release notes flag as able to stop a build that compiled, or to change what a program does. Removals in 0.5.0 lists every API due to go in the next minor release, with the recipe that migrates it.
Removals in 0.5.0
Each of these compiles today with javac's [removal] warning, which fails a -Werror build. The org.higherkindedj.openrewrite.MigrateDeprecationsTo0_5_0 recipe runs every recipe the table names; see 0.5.0 deprecation migration.
| Deprecated | Since | Use instead | Recipe |
|---|---|---|---|
KindValidator.narrowWithPattern | 0.4.4 | KindValidator.narrowHolder | RenameKindValidatorNarrowWithPattern |
StateTKind.narrowK | 0.4.5 | StateTKind.narrow | RenameStateTKindNarrowK |
StateT.evalStateT(state) and execStateT(state), and the StateTKindHelper forms without a monad | 0.4.6 | The overloads that take the Monad<F> | By hand |
StateT.monadF() | 0.4.6 | Pass the Monad<F> to the runner | By hand |
Try.fold and TryPath.fold, success first | 0.4.6 | foldFailureFirst(failureMapper, successMapper) | SwapTryFoldToFoldFailureFirstRecipe |
Each.eachWithIndex() | 0.4.7 | Narrow to EachIndexed and call indexedTraversal() | By hand |
@PathConfig | 0.4.11, unreleased | Nothing, since it has no effect; to rename a Path, set suffix on @PathSource | RemovePathConfig |
@PathSource capability EFFECTFUL | 0.4.11, unreleased | CHAINABLE, which generates the same | ReplaceDeprecatedPathSourceCapabilitiesRecipe |
@PathSource capability ACCUMULATING | 0.4.11, unreleased | RECOVERABLE, which generates the same | ReplaceDeprecatedPathSourceCapabilitiesRecipe |
StateT also changes shape in 0.5.0: its monadF record component goes, so two StateT values with the same state function compare equal whichever Monad built them. Its equals, hashCode and toString change with it.
fold is planned to return on Try and TryPath in 0.6.0, with the failure-first order, so migrate to foldFailureFirst rather than to a local helper named fold.
To 0.4.11
This release is not out yet. Its notes split what changes into what a running program can notice and what stops a build that compiled: read Upgrading from 0.4.10 before you move.
To 0.4.10
The details are in each group of the 0.4.10 notes.
- A sparse PATCH scans a same-typed container for
null: anullelement, which used to reach the domain, now reports astags.1: must not be null. - Explicit type witnesses on some
@ImportOpticsmethods stop compiling: a generated method's type parameters can fall, asOpticsSpec<Pair<A, String>>now generates<A>. Drop the witnesses: the inferred result is unchanged. - The processor refuses some
@InstanceOffocuses: one naming a type argument the source does not pin, and a parameterised member of a generic type. - A resolved
copyConstructoris emitted as a cast: the cast can select a different constructor than ran in 0.4.9, so check overloaded types withLensLaws. - Generated signatures carry
@Nullable: a nullness checker in your build can report differently. @GenerateFocusrefuses a raw or wildcardSetorCollection: such a component used to throwClassCastExceptionon first use. Name the type argument.- Three navigator return types move to what the static method reports: a
Collectionsubtype such asArrayListis aFocusPathover the container. A nestedList<Optional<String>>composes to the leaf, so drop a trailing.some(). - An SPI container of non-navigable elements stops at the container: set
widenCollections = trueon the declaring record to widen it as before. - Four more
@Nullableannotations widen toAffinePath: JSpecify's, JetBrains', AndroidX's and SpotBugs'. Read such a component withgetOptional. Traversals.forSet()andtraverseSetreturn an unmodifiable set: they used to return a mutableLinkedHashSet.- A varargs bridge method takes a bare
nullonly with a cast: write(String[]) null. @GeneratePathBridgerefuses more shapes, and warns on an empty interface: it refuses a raw effect return type, a wildcardValidatederror type, and astaticorprivate@PathViamethod. An interface with no@PathViamethod draws a warning, which fails a-Werrorbuild.- A
@ComposeEffectssupport class changes shape: each field must be aClass<XOp<?>>naming an@EffectAlgebra, andBoundSet<F>becomesBoundSet. Fix any field the processor refuses, then recompile, and the last effect dispatches at its correct depth. discarded-effectreports a deferred Path dropped as a statement: such asPath.io(() -> 1).peek(log). The check is an error by default, so such a statement stops the build.
To 0.4.9
The details are in the 0.4.9 notes.
- An all-
FieldErrorresponse is a 422, not a 400 (#627): sethkj.web.validation-field-error-status: 400to keep the old status. - A
nullon a wire parses as a located error:parseand a fallibleassembleused to throwNullPointerException. At a Spring boundary a 500 becomes a 422. - A list element's failure carries its index:
emails: not an email addressbecomesemails.1: not an email address. - A leaf naming no domain component is a compile error: so is a spec method that collides with a generated member (#654).
- A leaf on a projected component now takes effect: the projection then offers the validated
patchin place ofasLens(), so a call toasLens()stops compiling. - Unused
hkj-springconfiguration properties are removed (#642): delete the keys, since none changed behaviour. Code that read them programmatically stops compiling. hkj.security.validated-user-detailsdefaults tofalseand starts empty (#642): the sample accounts moved toValidatedUserDetailsService.withSampleUsers(), so enabling it without registering accounts fails every login.- A JWT with a missing or malformed authorities claim is a 401 (#642): set
hkj.security.reject-missing-authorities-claim: falseto accept a missing claim. - An SSE response commits after the stream's first element (#642): a stream failing at its start returns the configured failure status. Emit an early heartbeat on a stream that stays idle.
- Ambiguous effect-boundary interpreters fail at startup (#642): the choice used to follow scan order silently.
To 0.4.1 through 0.4.8
Besides the deprecations in Removals in 0.5.0, the notes for these releases flag these changes.
- 0.4.1:
FreegainsHandleErrorandApcases: an exhaustiveswitchoverFreestops compiling until it handles them, andAddHandleErrorCaseRecipefinds such a switch.Free'sFbound tightens toWitnessArity<TypeArity.Unary>. See the 0.4.1 notes. - 0.4.2: Effect Path handlers honour
@ResponseStatus: an annotated handler method now answers with its status, such as201for a POST. See the 0.4.2 notes. - 0.4.2:
hkj.web.either.default-error-statustakes effect (#490): the property used not to bind. The flathkj.web.default-error-statusstill works as an alias. - 0.4.3: error class names match status keywords by whole word:
RevalidationErrorno longer matches thevalidationheuristic, so its status can change. See the 0.4.3 notes. - 0.4.5: the compile-time checker gains eleven checks: the build plugins enable it, so a finding at error stops the build and one at warning fails a
-Werrorbuild. See Compile-Time Checks. - 0.4.5: every Effect Path prints one
toStringform (#530): a test that compares the old text fails. See the 0.4.5 notes. - 0.4.7: the checker's
raw-kindcheck warns on a rawKind: the warning fails a-Werrorbuild. See the 0.4.7 notes. - 0.4.7:
recoverWithrejects anullargument at once (#553): on everyMonadError, where some instances used to fail later.
To 0.3.5
VTask.run()no longer declaresthrows Throwable: it wraps a checked exception inVTaskExecutionException, so code that caught a checked exception fromrun()catches the wrapper instead. See the 0.3.5 notes.
To 0.3.0
Kindcarries its arity from 0.3.0: type parameters used as witnesses needWitnessAritybounds, and theAddArityBoundsrecipe adds them. See Arity migration and the 0.3.0 notes.
Previous: Release History Next: Unreleased: 0.4.11