From 9b1221fb57680a31c04bf6939395b40acf31a7cf Mon Sep 17 00:00:00 2001 From: Enno Runne <458526+ennru@users.noreply.github.com> Date: Fri, 20 Sep 2024 16:20:22 +0200 Subject: [PATCH] docs: revise URL structure (libraries) (#4425) * docs: revise URL structure (libraries) * Update current links --- .algolia-search-index-config.json | 4 ++-- CONTRIBUTING.md | 4 ++-- README.md | 8 ++++---- akka-http-core/src/main/resources/reference.conf | 2 +- .../akka/http/impl/engine/client/PoolInterface.scala | 2 +- .../akka/http/javadsl/model/ws/UpgradeToWebSocket.scala | 2 +- .../akka/http/javadsl/model/ws/WebSocketUpgrade.scala | 2 +- .../akka/http/scaladsl/model/ws/WebSocketUpgrade.scala | 2 +- build.sbt | 4 ++-- docs/release-train-issue-template.md | 2 +- docs/src/main/paradox/client-side/client-transport.md | 2 +- .../routing-dsl/directives/route-directives/handle.md | 4 ++-- project/AkkaDependency.scala | 4 ++-- .../src/main/resources/logback.xml | 2 +- 14 files changed, 22 insertions(+), 22 deletions(-) diff --git a/.algolia-search-index-config.json b/.algolia-search-index-config.json index cf0472819e2..91ca0f0c07c 100644 --- a/.algolia-search-index-config.json +++ b/.algolia-search-index-config.json @@ -2,7 +2,7 @@ "index_name": "akka_http_docs", "start_urls": [ { - "url": "https://doc.akka.io/docs/akka-http/current/", + "url": "https://doc.akka.io/libraries/akka-http/current/", "extra_attributes": { "language": [ "scala", @@ -41,4 +41,4 @@ "299459375" ], "nb_hits": 1650 -} \ No newline at end of file +} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index bd824f8a137..6910da08792 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -130,7 +130,7 @@ This allows simple and fast iterations on changes that would need to be introduc ## Binary compatibility Binary compatibility rules and guarantees are described in depth in the [Binary Compatibility Rules -](https://doc.akka.io/docs/akka/current/common/binary-compatibility-rules.html) section of the documentation. +](https://doc.akka.io/libraries/akka-core/current/common/binary-compatibility-rules.html) section of the documentation. Akka-http uses MiMa (which is short for [Lightbend Migration Manager](https://github.com/lightbend/migration-manager)) to validate binary compatibility of incoming Pull Requests. If your PR fails due to binary compatibility issues, you may see @@ -150,7 +150,7 @@ Situations when it may be fine to ignore a MiMa issued warning include: - if it is touching any class marked as `private[akka]`, `/** INTERNAL API*/` or similar markers - if it is concerning internal classes (often recognizable by package names like `dungeon`, `impl`, `internal` etc.) - if it is adding API to classes / traits which are only meant for extension by Akka itself, i.e. should not be extended by end-users -- if it is touching any class marked with the `@InternalApi`, `@DoNotInherit`, and `@ApiMayChange`. See [API stability annotations and comments](https://doc.akka.io/docs/akka/current/common/binary-compatibility-rules.html#api-stability-annotations-and-comments) +- if it is touching any class marked with the `@InternalApi`, `@DoNotInherit`, and `@ApiMayChange`. See [API stability annotations and comments](https://doc.akka.io/libraries/akka-core/current/common/binary-compatibility-rules.html#api-stability-annotations-and-comments) - other tricky situations If it turns out that the change can be safely ignored, please add the filter to a file with the issue number in the filename, placed in the submodule's `src/main/mima-filters/.backwards.excludes` directory. diff --git a/README.md b/README.md index a120897ad7c..68cab1d7aa4 100644 --- a/README.md +++ b/README.md @@ -21,15 +21,15 @@ Documentation ------------- The documentation is available at -[doc.akka.io](https://doc.akka.io/docs/akka-http/current/), for -[Scala](https://doc.akka.io/docs/akka-http/current/scala/http/) and -[Java](https://doc.akka.io/docs/akka-http/current/java/http/). +[doc.akka.io](https://doc.akka.io/libraries/akka-http/current/), for +[Scala](https://doc.akka.io/libraries/akka-http/current/scala/http/) and +[Java](https://doc.akka.io/libraries/akka-http/current/java/http/). Current versions of all Akka libraries -------------------------------------- -The current versions of all Akka libraries are listed on the [Akka Dependencies](https://doc.akka.io/docs/akka-dependencies/current/) page. Releases of the Akka HTTP libraries in this repository are listed on the [GitHub releases](https://github.com/akka/akka-http/releases) page. +The current versions of all Akka libraries are listed on the [Akka Dependencies](https://doc.akka.io/libraries/akka-dependencies/current/) page. Releases of the Akka HTTP libraries in this repository are listed on the [GitHub releases](https://github.com/akka/akka-http/releases) page. Community diff --git a/akka-http-core/src/main/resources/reference.conf b/akka-http-core/src/main/resources/reference.conf index f338b78f87e..b37e0a12222 100644 --- a/akka-http-core/src/main/resources/reference.conf +++ b/akka-http-core/src/main/resources/reference.conf @@ -337,7 +337,7 @@ akka.http { # # It is also possible to provide a payload for each heartbeat message, # this setting can be configured programatically by modifying the websocket settings. - # See: https://doc.akka.io/docs/akka-http/current/server-side/websocket-support.html + # See: https://doc.akka.io/libraries/akka-http/current/server-side/websocket-support.html periodic-keep-alive-mode = ping # Interval for sending periodic keep-alives diff --git a/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolInterface.scala b/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolInterface.scala index f8c97910d2f..9001d8d98f6 100644 --- a/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolInterface.scala +++ b/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolInterface.scala @@ -94,7 +94,7 @@ private[http] object PoolInterface { private[this] val PoolOverflowException = new BufferOverflowException( // stack trace cannot be prevented here because `BufferOverflowException` is final s"Exceeded configured max-open-requests value of [${poolId.hcps.setup.settings.maxOpenRequests}]. This means that the request queue of this pool (${poolId.hcps}) " + s"has completely filled up because the pool currently does not process requests fast enough to handle the incoming request load. " + - "Please retry the request later. See https://doc.akka.io/docs/akka-http/current/scala/http/client-side/pool-overflow.html for " + + "Please retry the request later. See https://doc.akka.io/libraries/akka-http/current/scala/http/client-side/pool-overflow.html for " + "more information.") val hcps = poolId.hcps diff --git a/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/UpgradeToWebSocket.scala b/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/UpgradeToWebSocket.scala index a4c4942848c..1927c656670 100644 --- a/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/UpgradeToWebSocket.scala +++ b/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/UpgradeToWebSocket.scala @@ -17,7 +17,7 @@ import akka.stream._ * This low-level API is expected to be replaced by an Attribute in the future. * * In any case, you might want to use `handleWebSocketMessages` instead as documented - * at https://doc.akka.io/docs/akka-http/current/server-side/websocket-support.html#routing-support + * at https://doc.akka.io/libraries/akka-http/current/server-side/websocket-support.html#routing-support * * @deprecated use the WebSocketUpgrade attribute instead since 10.2.0 */ diff --git a/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/WebSocketUpgrade.scala b/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/WebSocketUpgrade.scala index 01fe75c0c1a..32a87a0b032 100644 --- a/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/WebSocketUpgrade.scala +++ b/akka-http-core/src/main/scala/akka/http/javadsl/model/ws/WebSocketUpgrade.scala @@ -14,7 +14,7 @@ import akka.stream.{ FlowShape, Graph, SinkShape, SourceShape } * create a WebSocket handshake response and handle the WebSocket message stream with the given handler. * * This is a low-level API. You might want to use `handleWebSocketMessages` instead as documented - * at https://doc.akka.io/docs/akka-http/current/server-side/websocket-support.html#routing-support + * at https://doc.akka.io/libraries/akka-http/current/server-side/websocket-support.html#routing-support */ trait WebSocketUpgrade { /** diff --git a/akka-http-core/src/main/scala/akka/http/scaladsl/model/ws/WebSocketUpgrade.scala b/akka-http-core/src/main/scala/akka/http/scaladsl/model/ws/WebSocketUpgrade.scala index 9f571f67813..0d021312415 100644 --- a/akka-http-core/src/main/scala/akka/http/scaladsl/model/ws/WebSocketUpgrade.scala +++ b/akka-http-core/src/main/scala/akka/http/scaladsl/model/ws/WebSocketUpgrade.scala @@ -18,7 +18,7 @@ import akka.http.scaladsl.model.HttpResponse * registers a WebSocket handler. * * This is a low-level API. You might want to use `handleWebSocketMessages` instead as documented - * at https://doc.akka.io/docs/akka-http/current/server-side/websocket-support.html#routing-support + * at https://doc.akka.io/libraries/akka-http/current/server-side/websocket-support.html#routing-support */ trait WebSocketUpgrade extends jm.ws.WebSocketUpgrade { /** diff --git a/build.sbt b/build.sbt index e0b7d90574b..cf79f2db960 100644 --- a/build.sbt +++ b/build.sbt @@ -485,12 +485,12 @@ lazy val docs = project("docs") "quickstart-scala/index.html"), Compile / paradoxProperties ++= Map( "project.name" -> "Akka HTTP", - "canonical.base_url" -> "https://doc.akka.io/docs/akka-http/current", + "canonical.base_url" -> "https://doc.akka.io/libraries/akka-http/current", "akka.version" -> AkkaDependency.docs.version, "akka.minimum.version" -> AkkaDependency.minimumExpectedAkkaVersion, "jackson.xml.version" -> Dependencies.jacksonXmlVersion, "scalafix.version" -> _root_.scalafix.sbt.BuildInfo.scalafixVersion, // grab from scalafix plugin directly - "extref.akka-docs.base_url" -> s"https://doc.akka.io/docs/akka/${AkkaDependency.docs.link}/%s", + "extref.akka-docs.base_url" -> s"https://doc.akka.io/libraries/akka-core/${AkkaDependency.docs.link}/%s", "javadoc.akka.http.base_url" -> { val v = if (isSnapshot.value) "current" else version.value s"https://doc.akka.io/japi/akka-http/$v" diff --git a/docs/release-train-issue-template.md b/docs/release-train-issue-template.md index ab9448b1524..5b6dbdadfca 100644 --- a/docs/release-train-issue-template.md +++ b/docs/release-train-issue-template.md @@ -72,7 +72,7 @@ For minor or major releases: ### Afterwards - [ ] Add the released version to `project/MiMa.scala` to the `mimaPreviousArtifacts` key *of all current compatible branches*. -- [ ] Update [akka-dependencies bom](https://github.com/lightbend/akka-dependencies) and version for [Akka module versions](https://doc.akka.io/docs/akka-dependencies/current/) in [akka-dependencies repo](https://github.com/akka/akka-dependencies) +- [ ] Update [akka-dependencies bom](https://github.com/lightbend/akka-dependencies) and version for [Akka module versions](https://doc.akka.io/libraries/akka-dependencies/current/) in [akka-dependencies repo](https://github.com/akka/akka-dependencies) - [ ] Update [Akka Guide samples](https://github.com/akka/akka-platform-guide) - [ ] Update sbt new (g8) template: - [ ] [Akka HTTP Scala](https://github.com/akka/akka-http-quickstart-scala.g8/blob/main/src/main/g8/default.properties) diff --git a/docs/src/main/paradox/client-side/client-transport.md b/docs/src/main/paradox/client-side/client-transport.md index a756cb5ea6e..e249ccb0b28 100644 --- a/docs/src/main/paradox/client-side/client-transport.md +++ b/docs/src/main/paradox/client-side/client-transport.md @@ -109,7 +109,7 @@ Java You can use @apidoc[ClientTransport.withCustomResolver](ClientTransport) to customize host name resolution. The given resolution function will be called for every connection attempt to resolve a hostname / port combination (potentially asynchronously) to an `InetSocketAddress`. -As a backend to implement the resolution function you can use Akka's [Async DNS Resolution](https://doc.akka.io/docs/akka/current/io-dns.html#dns-extension). +As a backend to implement the resolution function you can use Akka's [Async DNS Resolution](https://doc.akka.io/libraries/akka-core/current/io-dns.html#dns-extension). Potential use cases: diff --git a/docs/src/main/paradox/routing-dsl/directives/route-directives/handle.md b/docs/src/main/paradox/routing-dsl/directives/route-directives/handle.md index 556529e15ff..3645517cd54 100644 --- a/docs/src/main/paradox/routing-dsl/directives/route-directives/handle.md +++ b/docs/src/main/paradox/routing-dsl/directives/route-directives/handle.md @@ -14,7 +14,7 @@ Creates a @scala[@scaladoc[Route](akka.http.scaladsl.server.index#Route=akka.htt that handles the request using a function or `PartialFunction` from @apidoc[HttpRequest] to a @scala[`Future`]@java[`CompletionStage`] of @apidoc[HttpResponse]. This directive can be used to include external components request processing components defined as a `Function` or `PartialFunction` -(like [those provided by akka-grpc](https://doc.akka.io/docs/akka-grpc/current/server/walkthrough.html#serving-multiple-services)) +(like [those provided by akka-grpc](https://doc.akka.io/libraries/akka-grpc/current/server/walkthrough.html#serving-multiple-services)) into a routing tree defined by directives and routes. For the `PartialFunction` variant, the given list of rejections will be used to reject the request with if the `PartialFunction` is not defined for a request. By default, @@ -25,4 +25,4 @@ There is also a strict version called @ref[handleSync](handleSync.md). ## Example Scala -: @@snip [RouteDirectivesExamplesSpec.scala](/docs/src/test/scala/docs/http/scaladsl/server/directives/RouteDirectivesExamplesSpec.scala) { #handle-examples-with-PF } \ No newline at end of file +: @@snip [RouteDirectivesExamplesSpec.scala](/docs/src/test/scala/docs/http/scaladsl/server/directives/RouteDirectivesExamplesSpec.scala) { #handle-examples-with-PF } diff --git a/project/AkkaDependency.scala b/project/AkkaDependency.scala index c5a71fbd0de..495e1a5b970 100644 --- a/project/AkkaDependency.scala +++ b/project/AkkaDependency.scala @@ -39,7 +39,7 @@ object AkkaDependency { } } - // Default version updated only when needed, https://doc.akka.io//docs/akka/current/project/downstream-upgrade-strategy.html + // Default version updated only when needed, https://doc.akka.io/libraries/akka-core/current/project/downstream-upgrade-strategy.html val minimumExpectedAkkaVersion = "2.9.3" val default = akkaDependency(defaultVersion = minimumExpectedAkkaVersion) val docs = akkaDependency(defaultVersion = minimumExpectedAkkaVersion) @@ -87,7 +87,7 @@ object AkkaDependency { import scala.concurrent.Await import scala.concurrent.duration._ - val versionFile = "https://doc.akka.io/docs/akka/snapshot/paradox.json" + val versionFile = "https://doc.akka.io/libraries/akka-core/snapshot/paradox.json" val body = Await.result(http.run(url(versionFile)), 10.seconds).bodyAsString val versionProperty = """"version" : """" val i = body.indexOf(versionProperty) diff --git a/samples/akka-http-quickstart-scala/src/main/resources/logback.xml b/samples/akka-http-quickstart-scala/src/main/resources/logback.xml index 210d7b4a19d..4fbb269f357 100644 --- a/samples/akka-http-quickstart-scala/src/main/resources/logback.xml +++ b/samples/akka-http-quickstart-scala/src/main/resources/logback.xml @@ -1,6 +1,6 @@ + logging config, see the Akka docs: https://doc.akka.io/libraries/akka-core/current/typed/logging.html#logback --> [%date{ISO8601}] [%level] [%logger] [%thread] [%X{akkaSource}] - %msg%n