Skip to content

Commit

Permalink
misc comments and spelling
Browse files Browse the repository at this point in the history
  • Loading branch information
gammazero committed Dec 2, 2024
1 parent 59fbac9 commit 7ab1575
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 15 deletions.
2 changes: 1 addition & 1 deletion examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Once you have your example finished, do not forget to run `go mod tidy` and addi

## Examples and Tutorials

- [Transfering UnixFS file data with Bitswap](./bitswap-transfer)
- [Transferring UnixFS file data with Bitswap](./bitswap-transfer)
- [Gateway backed by a local blockstore in form of a CAR file](./gateway/car-file)
- [Gateway backed by a remote (HTTP) blockstore and IPNS resolver](./gateway/proxy-blocks)
- [Gateway backed by a remote (HTTP) CAR Gateway](./gateway/proxy-car)
Expand Down
17 changes: 4 additions & 13 deletions pinning/remote/client/openapi/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Go API client for openapi



## About this spec
The IPFS Pinning Service API is intended to be an implementation-agnostic API:
- For use and implementation by pinning service providers
Expand All @@ -15,8 +13,10 @@ This section describes the most important object types and conventions.
A full list of fields and schemas can be found in the `schemas` section of the [YAML file](https://github.com/ipfs/pinning-services-api-spec/blob/master/ipfs-pinning-service.yaml).

## Identifiers

### cid
[Content Identifier (CID)](https://docs.ipfs.io/concepts/content-addressing/) points at the root of a DAG that is pinned recursively.

### requestid
Unique identifier of a pin request.

Expand All @@ -25,6 +25,7 @@ When a pin is created, the service responds with unique `requestid` that can be
Service implementation should use UUID, `hash(accessToken,Pin,PinStatus.created)`, or any other opaque identifier that provides equally strong protection against race conditions.

## Objects

### Pin object

![pin object](https://bafybeideck2fchyxna4wqwc2mo67yriokehw3yujboc5redjdaajrk2fjq.ipfs.dweb.link/pin.png)
Expand All @@ -46,7 +47,7 @@ It includes the original `pin` object, along with the current `status` and globa

### Creating a new pin object
The user sends a `Pin` object to `POST /pins` and receives a `PinStatus` response:
- `requestid` in `PinStatus` is the identifier of the pin operation, which can can be used for checking status, and removing the pin in the future
- `requestid` in `PinStatus` is the identifier of the pin operation, which can be used for checking status, and removing the pin in the future
- `status` in `PinStatus` indicates the current state of a pin

### Checking status of in-progress pinning
Expand All @@ -60,7 +61,6 @@ The user can replace an existing pin object via `POST /pins/{requestid}`. This i
### Removing a pin object
A pin object can be removed via `DELETE /pins/{requestid}`.


## Provider hints
Pinning of new data can be accelerated by providing a list of known data sources in `Pin.origins`, and connecting at least one of them to pinning service nodes at `PinStatus.delegates`.

Expand Down Expand Up @@ -99,8 +99,6 @@ Pin objects can be listed by executing `GET /pins` with optional parameters:

> **Note**: pagination by the `created` timestamp requires each value to be globally unique. Any future considerations to add support for bulk creation must account for this.


## Overview
This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [OpenAPI-spec](https://www.openapis.org/) from a remote server, you can easily generate an API client.

Expand Down Expand Up @@ -177,7 +175,6 @@ Class | Method | HTTP request | Description
*PinsApi* | [**PinsRequestidGet**](docs/PinsApi.md#pinsrequestidget) | **Get** /pins/{requestid} | Get pin object
*PinsApi* | [**PinsRequestidPost**](docs/PinsApi.md#pinsrequestidpost) | **Post** /pins/{requestid} | Replace pin object


## Documentation For Models

- [Failure](docs/Failure.md)
Expand All @@ -190,11 +187,8 @@ Class | Method | HTTP request | Description

## Documentation For Authorization



### accessToken


## Documentation for Utility Methods

Due to the fact that model structure members are all pointers, this package contains
Expand All @@ -212,6 +206,3 @@ Each of these functions takes a value of the given basic type and returns a poin
* `PtrTime`

## Author



4 changes: 3 additions & 1 deletion routing/providerquerymanager/providerquerymanager.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@ type ProviderQueryManager struct {

type Option func(*ProviderQueryManager) error

// WithMaxTimeout sets the limit on the amount of time to spend waiting for the
// maximum number of providers from a find request.
func WithMaxTimeout(timeout time.Duration) Option {
return func(mgr *ProviderQueryManager) error {
mgr.findProviderTimeout = timeout
Expand Down Expand Up @@ -316,7 +318,7 @@ func (pqm *ProviderQueryManager) findProviderWorker() {
findSem = make(chan struct{}, pqm.maxInProcessRequests)
}

// Read find provider requests until channel is closed. The channl is
// Read find provider requests until channel is closed. The channel is
// closed as soon as pqm.ctx is canceled, so there is no need to select on
// that context here.
for fpr := range pqm.providerRequestsProcessing.Out() {
Expand Down

0 comments on commit 7ab1575

Please sign in to comment.