-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
STAC Client pagination support (#327)
* StacClient supports pagination and has fs2.Streams in the interface * Cleanup PaginationToken companion object * Split StacClient and StreamingStacClient * Make a StreamingStacClient G independent from F; finish search pagination * Rename type alias
- Loading branch information
Showing
19 changed files
with
190 additions
and
113 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 0 additions & 3 deletions
3
modules/client/js/src/main/scala/com/azavea/stac4s/api/client/StacClient.scala
This file was deleted.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
modules/client/js/src/main/scala/com/azavea/stac4s/api/client/SttpStacClient.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
package com.azavea.stac4s.api.client | ||
|
||
import cats.MonadError | ||
import cats.MonadThrow | ||
import sttp.client3.SttpBackend | ||
import sttp.model.Uri | ||
|
||
object SttpStacClient { | ||
|
||
def apply[F[_]: MonadError[*[_], Throwable]](client: SttpBackend[F, Any], baseUri: Uri): SttpStacClient[F] = | ||
def apply[F[_]: MonadThrow](client: SttpBackend[F, Any], baseUri: Uri): SttpStacClient[F] = | ||
SttpStacClientF[F, SearchFilters](client, baseUri) | ||
} |
5 changes: 4 additions & 1 deletion
5
modules/client/js/src/main/scala/com/azavea/stac4s/api/client/package.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
package com.azavea.stac4s.api | ||
|
||
package object client { | ||
type SttpStacClient[F[_]] = SttpStacClientF[F, SearchFilters] | ||
type SttpStacClient[F[_]] = SttpStacClientF[F, SearchFilters] | ||
type StacClient[F[_]] = StacClientF[F, SearchFilters] | ||
type StreamingStacClientFS2[F[_]] = StreamingStacClientF[F, fs2.Stream[F, *], SearchFilters] | ||
type StreamingStacClient[F[_], G[_]] = StreamingStacClientF[F, G, SearchFilters] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 0 additions & 3 deletions
3
modules/client/jvm/src/main/scala/com/azavea/stac4s/api/client/StacClient.scala
This file was deleted.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
modules/client/jvm/src/main/scala/com/azavea/stac4s/api/client/SttpStacClient.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
package com.azavea.stac4s.api.client | ||
|
||
import cats.MonadError | ||
import cats.MonadThrow | ||
import sttp.client3.SttpBackend | ||
import sttp.model.Uri | ||
|
||
object SttpStacClient { | ||
|
||
def apply[F[_]: MonadError[*[_], Throwable]](client: SttpBackend[F, Any], baseUri: Uri): SttpStacClient[F] = | ||
def apply[F[_]: MonadThrow](client: SttpBackend[F, Any], baseUri: Uri): SttpStacClient[F] = | ||
SttpStacClientF[F, SearchFilters](client, baseUri) | ||
} |
5 changes: 0 additions & 5 deletions
5
modules/client/jvm/src/main/scala/com/azavea/stac4s/api/client/client.scala
This file was deleted.
Oops, something went wrong.
8 changes: 8 additions & 0 deletions
8
modules/client/jvm/src/main/scala/com/azavea/stac4s/api/client/package.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package com.azavea.stac4s.api | ||
|
||
package object client { | ||
type SttpStacClient[F[_]] = SttpStacClientF[F, SearchFilters] | ||
type StacClient[F[_]] = StacClientF[F, SearchFilters] | ||
type StreamingStacClientFS2[F[_]] = StreamingStacClientF[F, fs2.Stream[F, *], SearchFilters] | ||
type StreamingStacClient[F[_], G[_]] = StreamingStacClientF[F, G, SearchFilters] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.