git.iko.soy/typeable/minio-hs
on master help sign in
Remove port :9000 for play.min.io (#130)
commit3291f8673c41bf768398f90bf90e59141d914cec authorHarshavardhana <harsha@minio.io> dateWed 24 Jul 2019, 10:07 (7 years ago) parent0bcb1c9
18 files changed+200−200
README.md+3−3 docs/API.md+179−179 examples/BucketExists.hs+1−1 examples/CopyObject.hs+1−1 examples/FileUploader.hs+1−1 examples/GetObject.hs+1−1 examples/HeadObject.hs+1−1 examples/ListBuckets.hs+1−1 examples/ListIncompleteUploads.hs+1−1 examples/ListObjects.hs+1−1 examples/MakeBucket.hs+1−1 examples/PresignedGetObject.hs+1−1 examples/PresignedPostPolicy.hs+1−1 examples/PresignedPutObject.hs+1−1 examples/PutObject.hs+1−1 examples/RemoveBucket.hs+1−1 examples/RemoveIncompleteUpload.hs+1−1 src/Network/Minio/Data.hs+3−3
README.md+3−3
@@ -25,7 +25,7 @@ stack test
2525```
2626
2727A section of the tests use the remote MinIO Play server at
28−`https://play.min.io:9000` by default. For library development,
28+`https://play.min.io` by default. For library development,
2929using this remote server maybe slow. To run the tests against a
3030locally running MinIO live server at `http://localhost:9000`, just set
3131the environment `MINIO_LOCAL` to any value (and unset it to switch
@@ -47,7 +47,7 @@ stack haddock
4747-- stack --resolver lts-11.1 runghc --package minio-hs --package optparse-applicative --package filepath
4848
4949--
50−-- MinIO Haskell SDK, (C) 2017, 2018 MinIO, Inc.
50+-- MinIO Haskell SDK, (C) 2017-2019 MinIO, Inc.
5151--
5252-- Licensed under the Apache License, Version 2.0 (the "License");
5353-- you may not use this file except in compliance with the License.
@@ -76,7 +76,7 @@ import UnliftIO (throwIO, try)
7676import Prelude
7777
7878-- | The following example uses minio's play server at
79−-- https://play.min.io:9000. The endpoint and associated
79+-- https://play.min.io. The endpoint and associated
8080-- credentials are provided via the libary constant,
8181--
8282-- > minioPlayCI :: ConnectInfo
docs/API.md+179−179
@@ -20,15 +20,15 @@ awsCI { connectAccesskey = "your-access-key"
2020
2121```
2222
23−|Bucket operations|Object Operations|Presigned Operations|
24−|:---|:---|:---|
25−|[`listBuckets`](#listBuckets) |[`getObject`](#getObject)|[`presignedGetObjectUrl`](#presignedGetObjectUrl)|
26−|[`makeBucket`](#makeBucket)|[`putObject`](#putObject)|[`presignedPutObjectUrl`](#presignedPutObjectUrl)|
27−|[`removeBucket`](#removeBucket)|[`fGetObject`](#fGetObject)|[`presignedPostPolicy`](#presignedPostPolicy)|
28−|[`listObjects`](#listObjects)|[`fPutObject`](#fPutObject)||
29−|[`listObjectsV1`](#listObjectsV1)|[`copyObject`](#copyObject)||
30−|[`listIncompleteUploads`](#listIncompleteUploads)|[`removeObject`](#removeObject)||
31−|[`bucketExists`](#bucketExists)|[`selectObjectContent`](#selectObjectContent)||
23+| Bucket operations | Object Operations | Presigned Operations |
24+|:--------------------------------------------------|:----------------------------------------------|:--------------------------------------------------|
25+| [`listBuckets`](#listBuckets) | [`getObject`](#getObject) | [`presignedGetObjectUrl`](#presignedGetObjectUrl) |
26+| [`makeBucket`](#makeBucket) | [`putObject`](#putObject) | [`presignedPutObjectUrl`](#presignedPutObjectUrl) |
27+| [`removeBucket`](#removeBucket) | [`fGetObject`](#fGetObject) | [`presignedPostPolicy`](#presignedPostPolicy) |
28+| [`listObjects`](#listObjects) | [`fPutObject`](#fPutObject) | |
29+| [`listObjectsV1`](#listObjectsV1) | [`copyObject`](#copyObject) | |
30+| [`listIncompleteUploads`](#listIncompleteUploads) | [`removeObject`](#removeObject) | |
31+| [`bucketExists`](#bucketExists) | [`selectObjectContent`](#selectObjectContent) | |
3232
3333## 1. Connecting and running operations on the storage service
3434
@@ -69,16 +69,16 @@ enable/disable the automatic region discovery behaviour.
6969
7070The parameters in the expression `awsWithRegion region autoDiscover` are:
7171
72−|Parameter|Type|Description|
73−|:---|:---|:---|
74−| `region` | _Region_ (alias for `Text`) | The region to connect to by default for all requests. |
75−| `autoDiscover` | _Bool_ | If `True`, region discovery will be enabled. If `False`, discovery is disabled, and all requests go the given region only.|
72+| Parameter | Type | Description |
73+|:---------------|:----------------------------|:---------------------------------------------------------------------------------------------------------------------------|
74+| `region` | _Region_ (alias for `Text`) | The region to connect to by default for all requests. |
75+| `autoDiscover` | _Bool_ | If `True`, region discovery will be enabled. If `False`, discovery is disabled, and all requests go the given region only. |
7676
7777#### minioPlayCI :: ConnectInfo
7878
7979This constructor provides connection and authentication information to
8080connect to the public MinIO Play server at
81−`https://play.min.io:9000/`.
81+`https://play.min.io/`.
8282
8383#### minioCI :: Text -> Int -> Bool -> ConnectInfo
8484
@@ -86,25 +86,25 @@ Use to connect to a MinIO server.
8686
8787The parameters in the expression `minioCI host port isSecure` are:
8888
89−|Parameter|Type|Description|
90−|:---|:---|:---|
91−| `host` | _Text_ | Hostname of the MinIO or other S3-API compatible server |
92−| `port` | _Int_ | Port number to connect to|
93−| `isSecure` | _Bool_ | Does the server use HTTPS? |
89+| Parameter | Type | Description |
90+|:-----------|:-------|:--------------------------------------------------------|
91+| `host` | _Text_ | Hostname of the MinIO or other S3-API compatible server |
92+| `port` | _Int_ | Port number to connect to |
93+| `isSecure` | _Bool_ | Does the server use HTTPS? |
9494
9595#### The ConnectInfo fields and Default instance
9696
9797The following table shows the fields in the `ConnectInfo` record-type:
9898
99−| Field | Type | Description |
100−|:---|:---|:---|
101−| `connectHost` | _Text_ | Host name of the server. Defaults to `localhost`. |
102−| `connectPort` | _Int_ | Port number on which the server listens. Defaults to `9000`. |
103−| `connectAccessKey` | _Text_ | Access key to use in authentication. Defaults to `minio`. |
104−| `connectSecretkey` | _Text_ | Secret key to use in authentication. Defaults to `minio123`. |
105−| `connectIsSecure` | _Bool_ | Specifies if the server used TLS. Defaults to `False` |
106−| `connectRegion` | _Region_ (alias for `Text`) | Specifies the region to use. Defaults to 'us-east-1' |
107−| `connectAutoDiscoverRegion` | _Bool_ | Specifies if the library should automatically discover the region of a bucket. Defaults to `True`|
99+| Field | Type | Description |
100+|:----------------------------|:----------------------------|:--------------------------------------------------------------------------------------------------|
101+| `connectHost` | _Text_ | Host name of the server. Defaults to `localhost`. |
102+| `connectPort` | _Int_ | Port number on which the server listens. Defaults to `9000`. |
103+| `connectAccessKey` | _Text_ | Access key to use in authentication. Defaults to `minio`. |
104+| `connectSecretkey` | _Text_ | Secret key to use in authentication. Defaults to `minio123`. |
105+| `connectIsSecure` | _Bool_ | Specifies if the server used TLS. Defaults to `False` |
106+| `connectRegion` | _Region_ (alias for `Text`) | Specifies the region to use. Defaults to 'us-east-1' |
107+| `connectAutoDiscoverRegion` | _Bool_ | Specifies if the library should automatically discover the region of a bucket. Defaults to `True` |
108108
109109The `def` value of type `ConnectInfo` has all the above default
110110values.
@@ -148,17 +148,17 @@ Lists buckets.
148148
149149__Return Value__
150150
151−|Return type |Description |
152−|:---|:---|
153−| _Minio [BucketInfo]_| List of buckets |
151+| Return type | Description |
152+|:---------------------|:----------------|
153+| _Minio [BucketInfo]_ | List of buckets |
154154
155155
156156__BucketInfo record type__
157157
158−|Field |Type |Description |
159−|:---|:---| :---|
160−| `biName` | _Bucket_ (alias of `Text`) | Name of the bucket |
161−| `biCreationDate` | _UTCTime_ | Creation time of the bucket |
158+| Field | Type | Description |
159+|:-----------------|:---------------------------|:----------------------------|
160+| `biName` | _Bucket_ (alias of `Text`) | Name of the bucket |
161+| `biCreationDate` | _UTCTime_ | Creation time of the bucket |
162162
163163
164164<a name="makeBucket"></a>
@@ -171,10 +171,10 @@ __Parameters__
171171
172172In the expression `makeBucket bucketName region` the arguments are:
173173
174−| Param | Type | Description |
175−|---|---|---|
176−|`bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
177−| `region` | _Maybe Region_ | Region where the bucket is to be created. If not specified, default to the region in `ConnectInfo`.|
174+| Param | Type | Description |
175+|--------------|-----------------------------|-----------------------------------------------------------------------------------------------------|
176+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
177+| `region` | _Maybe Region_ | Region where the bucket is to be created. If not specified, default to the region in `ConnectInfo`. |
178178
179179__Example__
180180
@@ -200,9 +200,9 @@ __Parameters__
200200
201201In the expression `removeBucket bucketName` the arguments are:
202202
203−| Param | Type | Description |
204−|---|---|---|
205−|`bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
203+| Param | Type | Description |
204+|--------------|-----------------------------|--------------------|
205+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
206206
207207
208208__Example__
@@ -233,26 +233,26 @@ __Parameters__
233233In the expression `listObjects bucketName prefix recursive` the
234234arguments are:
235235
236−|Param |Type |Description |
237−|:---|:---| :---|
238−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
239−| `prefix` | _Maybe Text_ | Optional prefix that listed objects should have |
240−| `recursive` | _Bool_ |`True` indicates recursive style listing and `False` indicates directory style listing delimited by '/'. |
236+| Param | Type | Description |
237+|:-------------|:----------------------------|:---------------------------------------------------------------------------------------------------------|
238+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
239+| `prefix` | _Maybe Text_ | Optional prefix that listed objects should have |
240+| `recursive` | _Bool_ | `True` indicates recursive style listing and `False` indicates directory style listing delimited by '/'. |
241241
242242__Return Value__
243243
244−|Return type |Description |
245−|:---|:---|
246−| _C.ConduitM () ObjectInfo Minio ()_ | A Conduit Producer of `ObjectInfo` values corresponding to each object. |
244+| Return type | Description |
245+|:------------------------------------|:------------------------------------------------------------------------|
246+| _C.ConduitM () ObjectInfo Minio ()_ | A Conduit Producer of `ObjectInfo` values corresponding to each object. |
247247
248248__ObjectInfo record type__
249249
250−|Field |Type |Description |
251−|:---|:---| :---|
252−|`oiObject` | _Object_ (alias for `Text`) | Name of object |
253−|`oiModTime` | _UTCTime_ | Last modified time of the object |
254−|`oiETag` | _ETag_ (alias for `Text`) | ETag of the object |
255−|`oiSize` | _Int64_ | Size of the object in bytes |
250+| Field | Type | Description |
251+|:------------|:----------------------------|:---------------------------------|
252+| `oiObject` | _Object_ (alias for `Text`) | Name of object |
253+| `oiModTime` | _UTCTime_ | Last modified time of the object |
254+| `oiETag` | _ETag_ (alias for `Text`) | ETag of the object |
255+| `oiSize` | _Int64_ | Size of the object in bytes |
256256
257257__Example__
258258
@@ -265,7 +265,7 @@ import Prelude
265265
266266
267267-- | The following example uses MinIO play server at
268−-- https://play.min.io:9000. The endpoint and associated
268+-- https://play.min.io. The endpoint and associated
269269-- credentials are provided via the libary constant,
270270--
271271-- > minioPlayCI :: ConnectInfo
@@ -294,26 +294,26 @@ __Parameters__
294294In the expression `listObjectsV1 bucketName prefix recursive` the
295295arguments are:
296296
297−|Param |Type |Description |
298−|:---|:---| :---|
299−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
300−| `prefix` | _Maybe Text_ | Optional prefix that listed objects should have |
301−| `recursive` | _Bool_ |`True` indicates recursive style listing and `False` indicates directory style listing delimited by '/'. |
297+| Param | Type | Description |
298+|:-------------|:----------------------------|:---------------------------------------------------------------------------------------------------------|
299+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
300+| `prefix` | _Maybe Text_ | Optional prefix that listed objects should have |
301+| `recursive` | _Bool_ | `True` indicates recursive style listing and `False` indicates directory style listing delimited by '/'. |
302302
303303__Return Value__
304304
305−|Return type |Description |
306−|:---|:---|
307−| _C.ConduitM () ObjectInfo Minio ()_ | A Conduit Producer of `ObjectInfo` values corresponding to each object. |
305+| Return type | Description |
306+|:------------------------------------|:------------------------------------------------------------------------|
307+| _C.ConduitM () ObjectInfo Minio ()_ | A Conduit Producer of `ObjectInfo` values corresponding to each object. |
308308
309309__ObjectInfo record type__
310310
311−|Field |Type |Description |
312−|:---|:---| :---|
313−|`oiObject` | _Object_ (alias for `Text`) | Name of object |
314−|`oiModTime` | _UTCTime_ | Last modified time of the object |
315−|`oiETag` | _ETag_ (alias for `Text`) | ETag of the object |
316−|`oiSize` | _Int64_ | Size of the object in bytes |
311+| Field | Type | Description |
312+|:------------|:----------------------------|:---------------------------------|
313+| `oiObject` | _Object_ (alias for `Text`) | Name of object |
314+| `oiModTime` | _UTCTime_ | Last modified time of the object |
315+| `oiETag` | _ETag_ (alias for `Text`) | ETag of the object |
316+| `oiSize` | _Int64_ | Size of the object in bytes |
317317
318318__Example__
319319
@@ -326,7 +326,7 @@ import Prelude
326326
327327
328328-- | The following example uses MinIO play server at
329−-- https://play.min.io:9000. The endpoint and associated
329+-- https://play.min.io. The endpoint and associated
330330-- credentials are provided via the libary constant,
331331--
332332-- > minioPlayCI :: ConnectInfo
@@ -354,11 +354,11 @@ __Parameters__
354354In the expression `listIncompleteUploads bucketName prefix recursive`
355355the parameters are:
356356
357−|Param |Type |Description |
358−|:---|:---| :---|
359−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
360−| `prefix` | _Maybe Text_ | Optional prefix that listed objects should have. |
361−| `recursive` | _Bool_ |`True` indicates recursive style listing and `Talse` indicates directory style listing delimited by '/'. |
357+| Param | Type | Description |
358+|:-------------|:----------------------------|:---------------------------------------------------------------------------------------------------------|
359+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
360+| `prefix` | _Maybe Text_ | Optional prefix that listed objects should have. |
361+| `recursive` | _Bool_ | `True` indicates recursive style listing and `Talse` indicates directory style listing delimited by '/'. |
362362
363363__Return Value__
364364
@@ -368,11 +368,11 @@ __Return Value__
368368
369369__UploadInfo record type__
370370
371−|Field |Type |Description |
372−|:---|:---| :---|
373−|`uiKey` | _Object_ |Name of incompletely uploaded object |
374−|`uiUploadId` | _String_ |Upload ID of incompletely uploaded object |
375−|`uiSize` | _Int64_ |Size of incompletely uploaded object |
371+| Field | Type | Description |
372+|:-------------|:---------|:------------------------------------------|
373+| `uiKey` | _Object_ | Name of incompletely uploaded object |
374+| `uiUploadId` | _String_ | Upload ID of incompletely uploaded object |
375+| `uiSize` | _Int64_ | Size of incompletely uploaded object |
376376
377377__Example__
378378
@@ -384,7 +384,7 @@ import Conduit
384384import Prelude
385385
386386-- | The following example uses MinIO play server at
387−-- https://play.min.io:9000. The endpoint and associated
387+-- https://play.min.io. The endpoint and associated
388388-- credentials are provided via the libary constant,
389389--
390390-- > minioPlayCI :: ConnectInfo
@@ -415,29 +415,29 @@ __Parameters__
415415In the expression `getObject bucketName objectName opts` the parameters
416416are:
417417
418−|Param |Type |Description |
419−|:---|:---| :---|
420−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
421−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
422−| `opts` | _GetObjectOptions_ | Options for GET requests specifying additional options like If-Match, Range |
418+| Param | Type | Description |
419+|:-------------|:----------------------------|:----------------------------------------------------------------------------|
420+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
421+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
422+| `opts` | _GetObjectOptions_ | Options for GET requests specifying additional options like If-Match, Range |
423423
424424__GetObjectOptions record type__
425425
426−|Field |Type |Description |
427−|:---|:---| :---|
428−| `gooRange` | `Maybe ByteRanges` | Represents the byte range of object. E.g ByteRangeFromTo 0 9 represents first ten bytes of the object|
429−| `gooIfMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object should match |
430−| `gooIfNoneMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object shouldn't match |
431−| `gooIfUnmodifiedSince` | `Maybe UTCTime` | (Optional) Time since object wasn't modified |
432−| `gooIfModifiedSince` | `Maybe UTCTime` | (Optional) Time since object was modified |
426+| Field | Type | Description |
427+|:-----------------------|:--------------------------------|:------------------------------------------------------------------------------------------------------|
428+| `gooRange` | `Maybe ByteRanges` | Represents the byte range of object. E.g ByteRangeFromTo 0 9 represents first ten bytes of the object |
429+| `gooIfMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object should match |
430+| `gooIfNoneMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object shouldn't match |
431+| `gooIfUnmodifiedSince` | `Maybe UTCTime` | (Optional) Time since object wasn't modified |
432+| `gooIfModifiedSince` | `Maybe UTCTime` | (Optional) Time since object was modified |
433433
434434__Return Value__
435435
436436The return value can be incrementally read to process the contents of
437437the object.
438−|Return type |Description |
439−|:---|:---|
440−| _Minio (C.ConduitM () ByteString Minio ())_ | A Conduit source of `ByteString` values. |
438+| Return type | Description |
439+|:--------------------------------------------|:-----------------------------------------|
440+| _Minio (C.ConduitM () ByteString Minio ())_ | A Conduit source of `ByteString` values. |
441441
442442__Example__
443443
@@ -451,7 +451,7 @@ import qualified Data.Conduit.Binary as CB
451451import Prelude
452452
453453-- | The following example uses MinIO play server at
454−-- https://play.min.io:9000. The endpoint and associated
454+-- https://play.min.io. The endpoint and associated
455455-- credentials are provided via the libary constant,
456456--
457457-- > minioPlayCI :: ConnectInfo
@@ -482,13 +482,13 @@ __Parameters__
482482In the expression `putObject bucketName objectName inputSrc` the parameters
483483are:
484484
485−|Param |Type |Description |
486−|:---|:---| :---|
487−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
488−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
489−| `inputSrc` | _C.ConduitM () ByteString Minio ()_ | A Conduit producer of `ByteString` values |
490−| `size` | _Int64_ | Provide stream size (optional) |
491−| `opts` | _PutObjectOptions_ | Optional parameters to provide additional metadata for the object |
485+| Param | Type | Description |
486+|:-------------|:------------------------------------|:------------------------------------------------------------------|
487+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
488+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
489+| `inputSrc` | _C.ConduitM () ByteString Minio ()_ | A Conduit producer of `ByteString` values |
490+| `size` | _Int64_ | Provide stream size (optional) |
491+| `opts` | _PutObjectOptions_ | Optional parameters to provide additional metadata for the object |
492492
493493__Example__
494494
@@ -501,7 +501,7 @@ import qualified Data.Conduit.Combinators as CC
501501import Prelude
502502
503503-- | The following example uses MinIO play server at
504−-- https://play.min.io:9000. The endpoint and associated
504+-- https://play.min.io. The endpoint and associated
505505-- credentials are provided via the libary constant,
506506--
507507-- > minioPlayCI :: ConnectInfo
@@ -533,23 +533,23 @@ __Parameters__
533533In the expression `fGetObject bucketName objectName inputFile` the parameters
534534are:
535535
536−|Param |Type |Description |
537−|:---|:---| :---|
538−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
539−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
540−| `inputFile` | _FilePath_ | Path to the file to be uploaded |
541−| `opts` | _GetObjectOptions_ | Options for GET requests specifying additional options like If-Match, Range |
536+| Param | Type | Description |
537+|:-------------|:----------------------------|:----------------------------------------------------------------------------|
538+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
539+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
540+| `inputFile` | _FilePath_ | Path to the file to be uploaded |
541+| `opts` | _GetObjectOptions_ | Options for GET requests specifying additional options like If-Match, Range |
542542
543543
544544__GetObjectOptions record type__
545545
546−|Field |Type |Description |
547−|:---|:---| :---|
548−| `gooRange` | `Maybe ByteRanges` | Represents the byte range of object. E.g ByteRangeFromTo 0 9 represents first ten bytes of the object|
549−| `gooIfMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object should match |
550−| `gooIfNoneMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object shouldn't match |
551−| `gooIfUnmodifiedSince` | `Maybe UTCTime` | (Optional) Time since object wasn't modified |
552−| `gooIfModifiedSince` | `Maybe UTCTime` | (Optional) Time since object was modified |
546+| Field | Type | Description |
547+|:-----------------------|:--------------------------------|:------------------------------------------------------------------------------------------------------|
548+| `gooRange` | `Maybe ByteRanges` | Represents the byte range of object. E.g ByteRangeFromTo 0 9 represents first ten bytes of the object |
549+| `gooIfMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object should match |
550+| `gooIfNoneMatch` | `Maybe ETag` (alias for `Text`) | (Optional) ETag of object shouldn't match |
551+| `gooIfUnmodifiedSince` | `Maybe UTCTime` | (Optional) Time since object wasn't modified |
552+| `gooIfModifiedSince` | `Maybe UTCTime` | (Optional) Time since object was modified |
553553
554554``` haskell
555555
@@ -561,7 +561,7 @@ import Data.Conduit.Binary (sinkLbs)
561561import Prelude
562562
563563-- | The following example uses MinIO play server at
564−-- https://play.min.io:9000. The endpoint and associated
564+-- https://play.min.io. The endpoint and associated
565565-- credentials are provided via the libary constant,
566566--
567567-- > minioPlayCI :: ConnectInfo
@@ -592,11 +592,11 @@ __Parameters__
592592In the expression `fPutObject bucketName objectName inputFile` the parameters
593593are:
594594
595−|Param |Type |Description |
596−|:---|:---| :---|
597−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
598−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
599−| `inputFile` | _FilePath_ | Path to the file to be uploaded |
595+| Param | Type | Description |
596+|:-------------|:----------------------------|:--------------------------------|
597+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
598+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
599+| `inputFile` | _FilePath_ | Path to the file to be uploaded |
600600
601601__Example__
602602
@@ -629,28 +629,28 @@ __Parameters__
629629In the expression `copyObject dstInfo srcInfo` the parameters
630630are:
631631
632−|Param |Type |Description |
633−|:---|:---| :---|
632+| Param | Type | Description |
633+|:----------|:------------------|:----------------------------------------------------------|
634634| `dstInfo` | _DestinationInfo_ | A value representing properties of the destination object |
635−| `srcInfo` | _SourceInfo_ | A value representing properties of the source object |
635+| `srcInfo` | _SourceInfo_ | A value representing properties of the source object |
636636
637637
638638__SourceInfo record type__
639639
640−|Field |Type |Description |
641−|:---|:---| :---|
642−| `srcBucket` | `Bucket` | Name of source bucket |
643−| `srcObject` | `Object` | Name of source object |
644−| `srcRange` | `Maybe (Int64, Int64)` | (Optional) Represents the byte range of source object. (0, 9) represents first ten bytes of source object|
645−| `srcIfMatch` | `Maybe Text` | (Optional) ETag source object should match |
646−| `srcIfNoneMatch` | `Maybe Text` | (Optional) ETag source object shouldn't match |
647−| `srcIfUnmodifiedSince` | `Maybe UTCTime` | (Optional) Time since source object wasn't modified |
648−| `srcIfModifiedSince` | `Maybe UTCTime` | (Optional) Time since source object was modified |
640+| Field | Type | Description |
641+|:-----------------------|:-----------------------|:----------------------------------------------------------------------------------------------------------|
642+| `srcBucket` | `Bucket` | Name of source bucket |
643+| `srcObject` | `Object` | Name of source object |
644+| `srcRange` | `Maybe (Int64, Int64)` | (Optional) Represents the byte range of source object. (0, 9) represents first ten bytes of source object |
645+| `srcIfMatch` | `Maybe Text` | (Optional) ETag source object should match |
646+| `srcIfNoneMatch` | `Maybe Text` | (Optional) ETag source object shouldn't match |
647+| `srcIfUnmodifiedSince` | `Maybe UTCTime` | (Optional) Time since source object wasn't modified |
648+| `srcIfModifiedSince` | `Maybe UTCTime` | (Optional) Time since source object was modified |
649649
650650__Destination record type__
651651
652−|Field |Type |Description |
653−|:---|:---| :---|
652+| Field | Type | Description |
653+|:------------|:---------|:-----------------------------------------------------|
654654| `dstBucket` | `Bucket` | Name of destination bucket in server-side copyObject |
655655| `dstObject` | `Object` | Name of destination object in server-side copyObject |
656656
@@ -684,10 +684,10 @@ __Parameters__
684684In the expression `removeObject bucketName objectName` the parameters
685685are:
686686
687−|Param |Type |Description |
688−|:---|:---| :---|
689−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
690−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
687+| Param | Type | Description |
688+|:-------------|:----------------------------|:-------------------|
689+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
690+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
691691
692692__Example__
693693
@@ -718,10 +718,10 @@ __Parameters__
718718In the expression `removeIncompleteUpload bucketName objectName` the parameters
719719are:
720720
721−|Param |Type |Description |
722−|:---|:---| :---|
723−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
724−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
721+| Param | Type | Description |
722+|:-------------|:----------------------------|:-------------------|
723+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
724+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
725725
726726__Example__
727727
@@ -752,11 +752,11 @@ __Parameters__
752752In the expression `selectObjectContent bucketName objectName selReq`
753753the parameters are:
754754
755−|Param |Type |Description |
756−|:---|:---| :---|
757−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
758−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
759−| `selReq` | _SelectRequest_ | Select request parameters |
755+| Param | Type | Description |
756+|:-------------|:----------------------------|:--------------------------|
757+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
758+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
759+| `selReq` | _SelectRequest_ | Select request parameters |
760760
761761__SelectRequest record__
762762
@@ -804,9 +804,9 @@ __Parameters__
804804
805805In the expression `bucketExists bucketName` the parameters are:
806806
807−|Param |Type |Description |
808−|:---|:---| :---|
809−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
807+| Param | Type | Description |
808+|:-------------|:----------------------------|:-------------------|
809+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
810810
811811
812812## 4. Presigned operations
@@ -828,22 +828,22 @@ __Parameters__
828828In the expression `presignedGetObjectUrl bucketName objectName expiry queryParams headers`
829829the parameters are:
830830
831−|Param |Type |Description |
832−|:---|:---| :---|
833−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
834−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
835−| `expiry` | _UrlExpiry_ (alias for `Int`) | Url expiry time in seconds |
836−| `queryParams` | _Query_ (from package `http-types:Network.HTTP.Types`) | Query parameters to add to the URL |
837−| `headers` | _RequestHeaders_ (from package `http-types:Network.HTTP.Types` | Request headers that would be used with the URL |
831+| Param | Type | Description |
832+|:--------------|:---------------------------------------------------------------|:------------------------------------------------|
833+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
834+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
835+| `expiry` | _UrlExpiry_ (alias for `Int`) | Url expiry time in seconds |
836+| `queryParams` | _Query_ (from package `http-types:Network.HTTP.Types`) | Query parameters to add to the URL |
837+| `headers` | _RequestHeaders_ (from package `http-types:Network.HTTP.Types` | Request headers that would be used with the URL |
838838
839839__Return Value__
840840
841841Returns the generated URL - it will include authentication
842842information.
843843
844−|Return type |Description |
845−|:---|:---|
846−| _ByteString_ | Generated presigned URL |
844+| Return type | Description |
845+|:-------------|:------------------------|
846+| _ByteString_ | Generated presigned URL |
847847
848848__Example__
849849
@@ -886,21 +886,21 @@ __Parameters__
886886In the expression `presignedPutObjectUrl bucketName objectName expiry headers`
887887the parameters are:
888888
889−|Param |Type |Description |
890−|:---|:---| :---|
891−| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
892−| `objectName` | _Object_ (alias for `Text`) | Name of the object |
893−| `expiry` | _UrlExpiry_ (alias for `Int`) | Url expiry time in seconds |
894−| `headers` | _RequestHeaders_ (from package `http-types:Network.HTTP.Types` | Request headers that would be used with the URL |
889+| Param | Type | Description |
890+|:-------------|:---------------------------------------------------------------|:------------------------------------------------|
891+| `bucketName` | _Bucket_ (alias for `Text`) | Name of the bucket |
892+| `objectName` | _Object_ (alias for `Text`) | Name of the object |
893+| `expiry` | _UrlExpiry_ (alias for `Int`) | Url expiry time in seconds |
894+| `headers` | _RequestHeaders_ (from package `http-types:Network.HTTP.Types` | Request headers that would be used with the URL |
895895
896896__Return Value__
897897
898898Returns the generated URL - it will include authentication
899899information.
900900
901−|Return type |Description |
902−|:---|:---|
903−| _ByteString_ | Generated presigned URL |
901+| Return type | Description |
902+|:-------------|:------------------------|
903+| _ByteString_ | Generated presigned URL |
904904
905905__Example__
906906
@@ -940,10 +940,10 @@ The `PostPolicy` argument is created using the `newPostPolicy` function:
940940
941941In the expression `newPostPolicy expirationTime conditions` the parameters are:
942942
943−|Param | Type| Description |
944−|:---|:---|:---|
945−| `expirationTime` | _UTCTime_ (from package `time:Data.Time.UTCTime`) | The expiration time for the policy |
946−| `conditions` | _[PostPolicyConditions]_ | List of conditions to be added to the policy |
943+| Param | Type | Description |
944+|:-----------------|:--------------------------------------------------|:---------------------------------------------|
945+| `expirationTime` | _UTCTime_ (from package `time:Data.Time.UTCTime`) | The expiration time for the policy |
946+| `conditions` | _[PostPolicyConditions]_ | List of conditions to be added to the policy |
947947
948948The policy conditions are created using various helper functions -
949949please refer to the Haddocks for details.
examples/BucketExists.hs+1−1
@@ -24,7 +24,7 @@ import Control.Monad.IO.Class (liftIO)
2424import Prelude
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/CopyObject.hs+1−1
@@ -24,7 +24,7 @@ import Control.Monad.Catch (catchIf)
2424import Prelude
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/FileUploader.hs+1−1
@@ -31,7 +31,7 @@ import UnliftIO (throwIO, try)
3131import Prelude
3232
3333-- | The following example uses minio's play server at
34−-- https://play.min.io:9000. The endpoint and associated
34+-- https://play.min.io. The endpoint and associated
3535-- credentials are provided via the libary constant,
3636--
3737-- > minioPlayCI :: ConnectInfo
examples/GetObject.hs+1−1
@@ -26,7 +26,7 @@ import qualified Data.Conduit.Binary as CB
2626import Prelude
2727
2828-- | The following example uses minio's play server at
29−-- https://play.min.io:9000. The endpoint and associated
29+-- https://play.min.io. The endpoint and associated
3030-- credentials are provided via the libary constant,
3131--
3232-- > minioPlayCI :: ConnectInfo
examples/HeadObject.hs+1−1
@@ -24,7 +24,7 @@ import Network.Minio.S3API
2424import Prelude
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/ListBuckets.hs+1−1
@@ -24,7 +24,7 @@ import Control.Monad.IO.Class (liftIO)
2424import Prelude
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/ListIncompleteUploads.hs+1−1
@@ -24,7 +24,7 @@ import Conduit
2424import Prelude
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/ListObjects.hs+1−1
@@ -25,7 +25,7 @@ import Prelude
2525
2626
2727-- | The following example uses minio's play server at
28−-- https://play.min.io:9000. The endpoint and associated
28+-- https://play.min.io. The endpoint and associated
2929-- credentials are provided via the libary constant,
3030--
3131-- > minioPlayCI :: ConnectInfo
examples/MakeBucket.hs+1−1
@@ -24,7 +24,7 @@ import Network.Minio
2424import Prelude
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/PresignedGetObject.hs+1−1
@@ -27,7 +27,7 @@ import qualified Data.Conduit.Combinators as CC
2727import qualified Data.Text.Encoding as E
2828
2929-- | The following example uses minio's play server at
30−-- https://play.min.io:9000. The endpoint and associated
30+-- https://play.min.io. The endpoint and associated
3131-- credentials are provided via the libary constant,
3232--
3333-- > minioPlayCI :: ConnectInfo
examples/PresignedPostPolicy.hs+1−1
@@ -27,7 +27,7 @@ import qualified Data.Text.Encoding as Enc
2727import qualified Data.Time as Time
2828
2929-- | The following example uses minio's play server at
30−-- https://play.min.io:9000. The endpoint and associated
30+-- https://play.min.io. The endpoint and associated
3131-- credentials are provided via the libary constant,
3232--
3333-- > minioPlayCI :: ConnectInfo
examples/PresignedPutObject.hs+1−1
@@ -24,7 +24,7 @@ import qualified Data.ByteString.Char8 as B
2424import Data.CaseInsensitive (original)
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/PutObject.hs+1−1
@@ -25,7 +25,7 @@ import qualified Data.Conduit.Combinators as CC
2525import Prelude
2626
2727-- | The following example uses minio's play server at
28−-- https://play.min.io:9000. The endpoint and associated
28+-- https://play.min.io. The endpoint and associated
2929-- credentials are provided via the libary constant,
3030--
3131-- > minioPlayCI :: ConnectInfo
examples/RemoveBucket.hs+1−1
@@ -24,7 +24,7 @@ import Network.Minio
2424import Prelude
2525
2626-- | The following example uses minio's play server at
27−-- https://play.min.io:9000. The endpoint and associated
27+-- https://play.min.io. The endpoint and associated
2828-- credentials are provided via the libary constant,
2929--
3030-- > minioPlayCI :: ConnectInfo
examples/RemoveIncompleteUpload.hs+1−1
@@ -23,7 +23,7 @@ import Network.Minio
2323import Prelude
2424
2525-- | The following example uses minio's play server at
26−-- https://play.min.io:9000. The endpoint and associated
26+-- https://play.min.io. The endpoint and associated
2727-- credentials are provided via the libary constant,
2828--
2929-- > minioPlayCI :: ConnectInfo
src/Network/Minio/Data.hs+3−3
@@ -96,7 +96,7 @@ awsRegionMap = Map.fromList [
9696-- enable the @OverloadedStrings@ language extension and use the
9797-- `IsString` instance to provide a URL, for example:
9898--
99−-- > let c :: ConnectInfo = "https://play.min.io:9000"
99+-- > let c :: ConnectInfo = "https://play.min.io"
100100data ConnectInfo =
101101 ConnectInfo { connectHost :: Text
102102 , connectPort :: Int
@@ -231,13 +231,13 @@ awsCI :: ConnectInfo
231231awsCI = "https://s3.amazonaws.com"
232232
233233
234−-- | <https://play.min.io:9000 MinIO Play Server>
234+-- | <https://play.min.io MinIO Play Server>
235235-- ConnectInfo. Credentials are already filled in.
236236minioPlayCI :: ConnectInfo
237237minioPlayCI = let playCreds = Credentials "Q3AM3UQ867SPQQA43P2F" "zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG"
238238 in setCreds playCreds
239239 $ setRegion "us-east-1"
240− "https://play.min.io:9000"
240+ "https://play.min.io"
241241
242242-- |
243243-- Represents a bucket in the object store