diff --git a/CHANGELOG.md b/CHANGELOG.md index 13ad8331e62465bb0a232c9e8b440c4ba3f0eada..07e82fa44a8bca7adb458c347373e3feb3f1f827 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), ## [Unreleased] -### Deprecations / Removals +### Deprecations * In version 1.3.0, IPFS will no longer be supported as a datastore. Please migrate your data if you are using the IPFS support. diff --git a/cmd/loadtest/main.go b/cmd/loadtest/main.go deleted file mode 100644 index f6e6ceaaf4f0de1c31d7315f0c6afe7b733e2d19..0000000000000000000000000000000000000000 --- a/cmd/loadtest/main.go +++ /dev/null @@ -1,107 +0,0 @@ -package main - -import ( - "bytes" - "encoding/json" - "flag" - "fmt" - "image/color" - "io" - "io/ioutil" - "math" - "math/rand" - "net/http" - "sync" - "time" - - "github.com/fogleman/gg" - "github.com/turt2live/matrix-media-repo/api/r0" -) - -func main() { - accessToken := flag.String("accessToken", "", "The access token to use to make requests to the localhost media repo") - flag.Parse() - - uploadedMedia := make([]string, 0) - lock := sync.RWMutex{} - - // Downloaders (thumbnail generation) - numDownloaders := 45 - for x := 0; x < numDownloaders; x++ { - go func() { - for true { - if len(uploadedMedia) == 0 { - continue - } - i := int(math.Round(rand.Float64()*float64(len(uploadedMedia)))) - if i == len(uploadedMedia) { - i-- - } - mxc := uploadedMedia[i] - if mxc == "" { - continue - } - fmt.Println("Requesting media: ", mxc) - resp, _ := http.Get(fmt.Sprintf("http://localhost:8001/_matrix/media/r0/thumbnail/%s?width=320&height=240&method=scale&animated=false", mxc[len("mxc://"):])) - io.Copy(ioutil.Discard, resp.Body) // discard the body - - time.Sleep(time.Duration((rand.Float64() * 250) + 250) * time.Millisecond) - } - }() - } - - // Uploaders - numUploaders := 7 - for x := 0; x < numUploaders; x++ { - go func() { - for true { - fmt.Println("Generating media...") - - // Generate a random image first - width := int(math.Round(rand.Float64()*1024.0)) + 500 - height := int(math.Round(rand.Float64()*768.0) + 500) - - c := gg.NewContext(width, height) - c.Clear() - - for x := 0; x < width; x++ { - for y := 0; y < height; y++ { - col := color.RGBA{ - R: uint8(math.Round(rand.Float64() * 255)), - G: uint8(math.Round(rand.Float64() * 255)), - B: uint8(math.Round(rand.Float64() * 255)), - A: uint8(math.Round(rand.Float64() * 255)), - } - c.SetColor(col) - c.SetPixel(x, y) - } - } - - buf := &bytes.Buffer{} - c.EncodePNG(buf) - - // Now upload that image - fmt.Println("Uploading media...") - url := "http://localhost:8001/_matrix/media/r0/upload?filename=rand.png" - req, _ := http.NewRequest("POST", url, buf) - req.Header.Set("Content-Type", "image/png") - req.Header.Set("Authorization", "Bearer "+*accessToken) - resp, _ := http.DefaultClient.Do(req) - jsonResp := r0.MediaUploadedResponse{} - b, _ := ioutil.ReadAll(resp.Body) - json.Unmarshal(b, &jsonResp) - - // Add that uploaded image to the known uris - lock.Lock() - uploadedMedia = append(uploadedMedia, jsonResp.ContentUri) - fmt.Println("Added mxc uri: ", jsonResp.ContentUri) - lock.Unlock() - } - }() - } - - // wait forever (will need `kill -9` to kill this) - c := make(chan bool) - defer close(c) - <-c -} diff --git a/tests/performance/.gitignore b/tests/performance/.gitignore deleted file mode 100644 index 29dc14c7167ab69076775ca77834e8616f0bd1e8..0000000000000000000000000000000000000000 --- a/tests/performance/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -reports -node_modules diff --git a/tests/performance/example_reports/1561342783121-BeforeSingleflight-ColdCache.json b/tests/performance/example_reports/1561342783121-BeforeSingleflight-ColdCache.json deleted file mode 100644 index d8745ddd214274513fd00b572f2b97abcfc7e52d..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1561342783121-BeforeSingleflight-ColdCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 10007, - 10083, - 10100, - 10137, - 10402, - 10413, - 10427, - 10554, - 10555, - 10578, - 10640, - 10641, - 10775, - 10939, - 11089, - 11090, - 11097, - 11317, - 11460, - 11464, - 11466, - 11467, - 11520, - 11625, - 11741, - 11762, - 11788, - 11809, - 11815, - 11816, - 11867, - 11884, - 11921, - 11991, - 11997, - 12103, - 12109, - 12184, - 12526, - 12527, - 13039, - 13185, - 13191, - 13314, - 13343, - 13489, - 13499, - 13556, - 13557, - 4401, - 4523, - 4524, - 4575, - 4730, - 4862, - 4875, - 5027, - 5033, - 5034, - 5035, - 5042, - 5045, - 5045, - 5050, - 5053, - 5091, - 5096, - 5101, - 5143, - 5155, - 5292, - 5307, - 5309, - 5460, - 5464, - 5467, - 5469, - 5470, - 5475, - 5476, - 5480, - 5491, - 5520, - 5521, - 5530, - 5545, - 5564, - 5566, - 5578, - 5580, - 5618, - 5632, - 5640, - 5742, - 5742, - 5763, - 5765, - 5770, - 5771, - 5787, - 5788, - 5815, - 5834, - 5834, - 5855, - 5863, - 5867, - 5891, - 5894, - 5899, - 5931, - 5955, - 5964, - 6111, - 6114, - 6116, - 6117, - 6150, - 6295, - 6304, - 6316, - 6316, - 6319, - 6329, - 6332, - 6335, - 6345, - 6365, - 6381, - 6394, - 6413, - 6510, - 6517, - 6521, - 6529, - 6530, - 6532, - 6590, - 6637, - 6642, - 6647, - 6857, - 6885, - 6934, - 6962, - 6962, - 6969, - 6999, - 7340, - 7425, - 7473, - 7603, - 7649, - 7698, - 7715, - 7734, - 7738, - 7753, - 7758, - 7761, - 7836, - 7837, - 7892, - 7892, - 7915, - 7925, - 8208, - 8216, - 8217, - 8217, - 8219, - 8273, - 8275, - 8282, - 8456, - 8512, - 8513, - 8587, - 8791, - 8793, - 8794, - 8797, - 8801, - 8802, - 9023, - 9264, - 9367, - 9622, - 9994, - 9995, - 9998 - ], - "min": 4401, - "max": 13557, - "average": 7878.104712041885, - "median": 5763, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/example_reports/1561342955384-BeforeSingleflight-WarmCache.json b/tests/performance/example_reports/1561342955384-BeforeSingleflight-WarmCache.json deleted file mode 100644 index 683179973166abc61d7c9a832c4985c1030c3782..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1561342955384-BeforeSingleflight-WarmCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 1054, - 1055, - 1064, - 1071, - 1076, - 1077, - 1087, - 1091, - 1096, - 1108, - 1112, - 1133, - 1135, - 1141, - 1161, - 1165, - 1171, - 1191, - 1193, - 1208, - 1261, - 1290, - 1308, - 1315, - 1324, - 1333, - 1350, - 1372, - 1386, - 1390, - 1400, - 1406, - 1425, - 1436, - 1455, - 1460, - 1471, - 1502, - 1511, - 1513, - 1532, - 1546, - 1555, - 1562, - 1572, - 1577, - 1592, - 1597, - 1608, - 1618, - 1626, - 1627, - 1631, - 1638, - 1660, - 1670, - 1682, - 1689, - 1695, - 1703, - 1709, - 1717, - 1726, - 1727, - 1730, - 1751, - 1763, - 1764, - 1779, - 1779, - 1785, - 1795, - 1808, - 1818, - 1821, - 1827, - 1829, - 1830, - 1842, - 1850, - 1860, - 1875, - 1883, - 1892, - 1893, - 1905, - 1907, - 1917, - 1921, - 1932, - 1935, - 1949, - 1949, - 1952, - 1956, - 1957, - 1967, - 1994, - 2002, - 2004, - 2007, - 2011, - 2018, - 2037, - 2038, - 2041, - 2041, - 2061, - 2073, - 2093, - 2097, - 2105, - 2118, - 2129, - 2138, - 2146, - 2160, - 2163, - 2174, - 2175, - 2176, - 2184, - 2210, - 2213, - 2225, - 2232, - 2233, - 2246, - 2250, - 2253, - 2262, - 2265, - 2276, - 2288, - 2300, - 2318, - 2321, - 2324, - 2338, - 2356, - 2358, - 2365, - 2370, - 2373, - 2387, - 2387, - 2388, - 2389, - 2407, - 2423, - 2431, - 2441, - 2441, - 2442, - 2459, - 2469, - 2474, - 2492, - 2493, - 2495, - 2503, - 2513, - 2514, - 2514, - 2515, - 2515, - 2520, - 2531, - 2538, - 2541, - 2543, - 2550, - 2571, - 2574, - 2625, - 2650, - 457, - 564, - 660, - 693, - 758, - 774, - 777, - 796, - 797, - 838, - 881, - 902, - 927, - 957, - 999 - ], - "min": 457, - "max": 2650, - "average": 1806.5602094240837, - "median": 1957, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/example_reports/1561432114806-AfterSingleflight-ColdCache.json b/tests/performance/example_reports/1561432114806-AfterSingleflight-ColdCache.json deleted file mode 100644 index cb1eb9ec233c732fae1bd59711d4a2f42b7b43d2..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1561432114806-AfterSingleflight-ColdCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 10336, - 10337, - 10337, - 10433, - 10434, - 10434, - 10434, - 10435, - 10435, - 10435, - 10435, - 10436, - 10439, - 10440, - 10440, - 10463, - 10463, - 10464, - 10464, - 10464, - 10465, - 11894, - 11895, - 11896, - 12483, - 12483, - 12483, - 12484, - 12484, - 12485, - 3550, - 3551, - 3551, - 3826, - 3826, - 3827, - 3842, - 3843, - 3843, - 3844, - 3844, - 3846, - 3846, - 3847, - 3847, - 3847, - 3847, - 3847, - 3847, - 3848, - 3848, - 3849, - 3849, - 3849, - 3850, - 3851, - 3851, - 3852, - 3852, - 3852, - 3854, - 3944, - 3945, - 3945, - 3946, - 3947, - 3947, - 3947, - 3947, - 3948, - 3948, - 3948, - 3948, - 3948, - 3948, - 3948, - 3948, - 3949, - 3949, - 3949, - 3950, - 3951, - 3951, - 3951, - 3959, - 3960, - 3960, - 3961, - 5794, - 5794, - 5794, - 5826, - 5827, - 5827, - 5844, - 5845, - 5845, - 5851, - 5851, - 5851, - 6039, - 6040, - 6040, - 6116, - 6117, - 6117, - 6118, - 6119, - 6119, - 6120, - 6120, - 6120, - 6120, - 6121, - 6121, - 6121, - 6121, - 6121, - 6122, - 6122, - 6122, - 6122, - 6123, - 6123, - 6123, - 6124, - 6124, - 6124, - 6125, - 6126, - 6173, - 6175, - 6175, - 6238, - 6239, - 6239, - 6239, - 6239, - 6240, - 6251, - 6252, - 6252, - 6253, - 6253, - 6253, - 6280, - 6280, - 6281, - 6281, - 6281, - 6281, - 6386, - 6387, - 6500, - 6504, - 6529, - 6531, - 6531, - 6532, - 6532, - 6532, - 6532, - 6532, - 6532, - 6532, - 6533, - 6533, - 8100, - 8100, - 8100, - 8376, - 8377, - 8377, - 8534, - 8535, - 8535, - 8666, - 8666, - 8666, - 8666, - 8666, - 8667, - 8685, - 8685, - 8685, - 8745, - 8751, - 8751, - 8752, - 8753, - 8753 - ], - "min": 3550, - "max": 12485, - "average": 6538.3298429319375, - "median": 5845, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/example_reports/1561432138475-AfterSingleflight-WarmCache.json b/tests/performance/example_reports/1561432138475-AfterSingleflight-WarmCache.json deleted file mode 100644 index c3693ac692e09aea18f156b1c4014462905176f2..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1561432138475-AfterSingleflight-WarmCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 178, - 178, - 179, - 179, - 179, - 180, - 193, - 193, - 193, - 193, - 193, - 193, - 193, - 194, - 194, - 194, - 194, - 194, - 194, - 195, - 195, - 195, - 195, - 207, - 209, - 209, - 209, - 209, - 209, - 209, - 209, - 209, - 210, - 210, - 210, - 211, - 211, - 211, - 211, - 211, - 211, - 211, - 212, - 212, - 212, - 212, - 212, - 212, - 213, - 213, - 213, - 213, - 213, - 213, - 214, - 214, - 214, - 222, - 222, - 222, - 222, - 222, - 222, - 222, - 224, - 224, - 227, - 227, - 228, - 243, - 244, - 244, - 244, - 244, - 244, - 245, - 245, - 246, - 247, - 248, - 249, - 249, - 249, - 249, - 249, - 250, - 250, - 250, - 251, - 251, - 251, - 251, - 251, - 253, - 253, - 254, - 255, - 264, - 264, - 264, - 264, - 264, - 265, - 268, - 268, - 268, - 270, - 270, - 270, - 270, - 270, - 271, - 308, - 308, - 309, - 314, - 315, - 316, - 322, - 322, - 323, - 323, - 324, - 325, - 328, - 329, - 330, - 338, - 338, - 338, - 339, - 339, - 339, - 347, - 348, - 348, - 348, - 349, - 349, - 357, - 357, - 358, - 358, - 358, - 358, - 358, - 358, - 358, - 358, - 358, - 359, - 359, - 359, - 359, - 359, - 359, - 359, - 360, - 360, - 360, - 360, - 360, - 360, - 361, - 361, - 362, - 362, - 362, - 363, - 363, - 363, - 364, - 364, - 364, - 364, - 364, - 370, - 370, - 370, - 371, - 372, - 373, - 374, - 375, - 375, - 385, - 386, - 386, - 386, - 386, - 386 - ], - "min": 178, - "max": 386, - "average": 278.0418848167539, - "median": 254, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/example_reports/1561514534005-AfterCustomSingleflight-ColdCache.json b/tests/performance/example_reports/1561514534005-AfterCustomSingleflight-ColdCache.json deleted file mode 100644 index f3a0a488473f72186f9ddc51aba99727ac1d84a0..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1561514534005-AfterCustomSingleflight-ColdCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 3470, - 3472, - 3472, - 3472, - 3473, - 3473, - 3514, - 3515, - 3515, - 3597, - 3598, - 3598, - 3598, - 3598, - 3598, - 3689, - 3703, - 3704, - 3707, - 4540, - 4540, - 4540, - 4857, - 4857, - 4857, - 4858, - 4858, - 4858, - 4874, - 4875, - 4875, - 4971, - 4972, - 4972, - 5016, - 5017, - 5017, - 5018, - 5018, - 5018, - 5069, - 5069, - 5070, - 5070, - 5070, - 5070, - 5071, - 5071, - 5071, - 5071, - 5071, - 5071, - 5102, - 5103, - 5104, - 5214, - 5214, - 5214, - 5215, - 5215, - 5215, - 5217, - 5217, - 5218, - 5218, - 5219, - 5219, - 5219, - 5219, - 5219, - 5220, - 5220, - 5220, - 5221, - 5221, - 5222, - 5223, - 5224, - 5225, - 5225, - 5263, - 5263, - 5264, - 5264, - 5264, - 5264, - 5264, - 5264, - 5265, - 5265, - 5265, - 5265, - 5266, - 5266, - 5267, - 5267, - 5267, - 5267, - 5267, - 5268, - 5268, - 5268, - 5268, - 5268, - 5269, - 5269, - 5270, - 5399, - 5399, - 5399, - 5399, - 5400, - 5400, - 5401, - 5403, - 5403, - 5403, - 5404, - 5404, - 5404, - 5404, - 5405, - 5405, - 5406, - 5406, - 5406, - 5406, - 5406, - 5406, - 5407, - 5407, - 5407, - 5408, - 5408, - 5601, - 5601, - 5601, - 5648, - 5648, - 5649, - 5800, - 5800, - 5801, - 6021, - 6021, - 6021, - 6022, - 6022, - 6023, - 6583, - 6584, - 6590, - 6591, - 6591, - 6591, - 6848, - 6849, - 6849, - 6849, - 6849, - 6849, - 7202, - 7203, - 7207, - 7293, - 7293, - 7294, - 7365, - 7366, - 7366, - 7371, - 7371, - 7371, - 7449, - 7452, - 7452, - 7452, - 7452, - 7452, - 8064, - 8064, - 8064, - 8075, - 8075, - 8075, - 8701, - 8702, - 8703, - 8703, - 8703, - 8704 - ], - "min": 3470, - "max": 8704, - "average": 5580.293193717277, - "median": 5267, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/example_reports/1561514563170-AfterCustomSingleflight-WarmCache.json b/tests/performance/example_reports/1561514563170-AfterCustomSingleflight-WarmCache.json deleted file mode 100644 index 9325d214c7c13fc2099f75dcca20d79573c4a8f7..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1561514563170-AfterCustomSingleflight-WarmCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 206, - 206, - 206, - 206, - 206, - 206, - 210, - 210, - 211, - 211, - 211, - 211, - 211, - 211, - 211, - 211, - 211, - 212, - 212, - 213, - 213, - 213, - 214, - 214, - 214, - 214, - 214, - 214, - 214, - 215, - 215, - 215, - 215, - 222, - 222, - 222, - 233, - 234, - 234, - 234, - 235, - 235, - 241, - 242, - 243, - 256, - 256, - 256, - 258, - 259, - 259, - 259, - 259, - 260, - 266, - 266, - 266, - 266, - 268, - 268, - 268, - 269, - 269, - 269, - 271, - 271, - 271, - 271, - 271, - 273, - 273, - 274, - 274, - 280, - 281, - 281, - 295, - 295, - 295, - 296, - 296, - 301, - 304, - 304, - 304, - 304, - 304, - 305, - 305, - 305, - 306, - 306, - 306, - 306, - 306, - 307, - 307, - 307, - 307, - 307, - 307, - 307, - 307, - 307, - 308, - 308, - 310, - 310, - 311, - 312, - 312, - 313, - 313, - 313, - 314, - 314, - 315, - 315, - 316, - 316, - 316, - 316, - 317, - 317, - 317, - 317, - 317, - 317, - 317, - 317, - 317, - 317, - 318, - 318, - 318, - 318, - 318, - 319, - 319, - 319, - 319, - 319, - 320, - 321, - 321, - 344, - 344, - 345, - 359, - 359, - 359, - 360, - 362, - 362, - 363, - 363, - 363, - 364, - 364, - 364, - 364, - 365, - 365, - 366, - 367, - 368, - 369, - 370, - 370, - 370, - 371, - 371, - 373, - 373, - 374, - 375, - 375, - 375, - 382, - 382, - 382, - 382, - 385, - 386, - 386, - 386, - 386, - 387, - 388, - 388, - 390 - ], - "min": 206, - "max": 390, - "average": 296.13612565445027, - "median": 307, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/example_reports/1584652894896-Checkup-ColdCache.json b/tests/performance/example_reports/1584652894896-Checkup-ColdCache.json deleted file mode 100644 index 42283f0cf10a50596e08ed1a37adbea13975d360..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1584652894896-Checkup-ColdCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 1359, - 1360, - 1360, - 1361, - 1361, - 1361, - 1361, - 1362, - 1362, - 1431, - 1431, - 1432, - 1432, - 1432, - 1434, - 1435, - 1435, - 1435, - 1436, - 1436, - 1437, - 1439, - 1443, - 1443, - 1444, - 1444, - 1444, - 1460, - 1460, - 1461, - 1461, - 1461, - 1462, - 1462, - 1463, - 1464, - 1464, - 1464, - 1464, - 1465, - 1465, - 1465, - 1466, - 1467, - 1468, - 1468, - 1469, - 1470, - 1470, - 1471, - 1472, - 1472, - 1475, - 1476, - 1477, - 1478, - 1478, - 1486, - 1486, - 1487, - 1489, - 1490, - 1495, - 1496, - 1496, - 1496, - 1496, - 1497, - 1497, - 1497, - 1497, - 1498, - 1498, - 1498, - 1499, - 1499, - 1499, - 1499, - 1500, - 1511, - 1511, - 1512, - 1545, - 1545, - 1545, - 1545, - 1546, - 1546, - 1547, - 1547, - 1547, - 1549, - 1549, - 1550, - 1550, - 1550, - 1551, - 1560, - 1561, - 1561, - 1561, - 1562, - 1562, - 1563, - 1563, - 1563, - 1568, - 1568, - 1570, - 1570, - 1570, - 1570, - 1571, - 1571, - 1571, - 1571, - 1571, - 1571, - 1571, - 1572, - 1572, - 1572, - 1572, - 1573, - 1573, - 1573, - 1574, - 1575, - 1575, - 1576, - 1576, - 1577, - 1577, - 1577, - 1578, - 1578, - 1578, - 1578, - 1578, - 1579, - 1579, - 1580, - 1581, - 1581, - 1582, - 1602, - 1602, - 1603, - 1603, - 1604, - 1604, - 1604, - 1605, - 1605, - 1605, - 1605, - 1605, - 1606, - 1606, - 1607, - 1607, - 1607, - 1607, - 1607, - 1608, - 1608, - 1608, - 1608, - 1608, - 1609, - 1609, - 1609, - 1611, - 1650, - 1650, - 1650, - 1655, - 1656, - 1657, - 1657, - 1657, - 1657, - 1700, - 1700, - 1702, - 1787, - 1787, - 1787, - 1788, - 1788, - 1789 - ], - "min": 1359, - "max": 1789, - "average": 1538.8115183246073, - "median": 1550, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/example_reports/1584652946355-Checkup-WarmCache.json b/tests/performance/example_reports/1584652946355-Checkup-WarmCache.json deleted file mode 100644 index 51dc042994ca85e69ffc54c99495cff56c68db14..0000000000000000000000000000000000000000 --- a/tests/performance/example_reports/1584652946355-Checkup-WarmCache.json +++ /dev/null @@ -1,202 +0,0 @@ -{ - "failed": 0, - "corrupted": 0, - "requestTimes": [ - 194, - 194, - 194, - 194, - 195, - 195, - 230, - 231, - 231, - 231, - 232, - 232, - 232, - 232, - 233, - 233, - 233, - 233, - 234, - 234, - 234, - 235, - 235, - 235, - 272, - 275, - 276, - 288, - 290, - 290, - 295, - 295, - 295, - 295, - 296, - 296, - 296, - 296, - 297, - 303, - 305, - 306, - 307, - 307, - 309, - 309, - 310, - 310, - 310, - 310, - 310, - 311, - 311, - 312, - 312, - 312, - 312, - 312, - 313, - 313, - 314, - 314, - 314, - 315, - 315, - 316, - 316, - 317, - 317, - 317, - 317, - 318, - 318, - 319, - 319, - 319, - 319, - 319, - 320, - 320, - 320, - 320, - 320, - 321, - 321, - 321, - 322, - 322, - 322, - 322, - 322, - 322, - 323, - 323, - 323, - 324, - 324, - 324, - 324, - 324, - 324, - 324, - 324, - 324, - 324, - 325, - 325, - 325, - 325, - 325, - 325, - 325, - 326, - 326, - 326, - 326, - 327, - 327, - 327, - 327, - 328, - 331, - 332, - 333, - 335, - 336, - 336, - 338, - 338, - 339, - 344, - 344, - 344, - 346, - 346, - 346, - 346, - 347, - 347, - 347, - 347, - 347, - 348, - 348, - 349, - 349, - 349, - 352, - 355, - 355, - 355, - 364, - 364, - 364, - 364, - 364, - 364, - 364, - 364, - 364, - 365, - 365, - 365, - 368, - 369, - 369, - 369, - 369, - 370, - 391, - 392, - 392, - 393, - 393, - 393, - 393, - 393, - 394, - 396, - 398, - 399, - 399, - 399, - 399, - 406, - 406, - 406, - 427, - 427, - 428, - 432 - ], - "min": 194, - "max": 432, - "average": 322.5340314136126, - "median": 324, - "count": 191 -} \ No newline at end of file diff --git a/tests/performance/expected_thumbnails/t2bot.io_00845bfa7e453d392f86b53eadbdbfd3d10d3fcd.png b/tests/performance/expected_thumbnails/t2bot.io_00845bfa7e453d392f86b53eadbdbfd3d10d3fcd.png deleted file mode 100644 index e6868a16ed7b1bfe942881e522eb0114db656054..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_00845bfa7e453d392f86b53eadbdbfd3d10d3fcd.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_0850052a28cf72d91c77b52b74e67cc9fccd3607.png b/tests/performance/expected_thumbnails/t2bot.io_0850052a28cf72d91c77b52b74e67cc9fccd3607.png deleted file mode 100644 index d0ba73e478d48784d8ec5787c36e99340f00352d..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_0850052a28cf72d91c77b52b74e67cc9fccd3607.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_102d17f15f25e697d857c5d5003efcf27c36886f.png b/tests/performance/expected_thumbnails/t2bot.io_102d17f15f25e697d857c5d5003efcf27c36886f.png deleted file mode 100644 index 17de7b7d4e70d70439329c30b2b4a1bb87d8838d..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_102d17f15f25e697d857c5d5003efcf27c36886f.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_13754a79523fb6c96abdb06a52fd2b54788d1a2a.png b/tests/performance/expected_thumbnails/t2bot.io_13754a79523fb6c96abdb06a52fd2b54788d1a2a.png deleted file mode 100644 index 102560f3fb4e93a654b7c93049d5fe30b884d53e..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_13754a79523fb6c96abdb06a52fd2b54788d1a2a.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_144c17562179ad788652961dd5238e8796f6a0a5.png b/tests/performance/expected_thumbnails/t2bot.io_144c17562179ad788652961dd5238e8796f6a0a5.png deleted file mode 100644 index a79fbd4e813481553d0510163ceffd753a0b02c6..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_144c17562179ad788652961dd5238e8796f6a0a5.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_180a386b83717f75785c4f0501ae1551ff448a1b.png b/tests/performance/expected_thumbnails/t2bot.io_180a386b83717f75785c4f0501ae1551ff448a1b.png deleted file mode 100644 index c8e9d8e45551aa23c0da39256a2b0008f40361bc..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_180a386b83717f75785c4f0501ae1551ff448a1b.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_1e4925f241581d27d5dfff7d7b0bfaf62714b4c3.png b/tests/performance/expected_thumbnails/t2bot.io_1e4925f241581d27d5dfff7d7b0bfaf62714b4c3.png deleted file mode 100644 index 429e292cda1eba7400d034b52cc3a418d8e78d04..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_1e4925f241581d27d5dfff7d7b0bfaf62714b4c3.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_20777c9ccca38567559ef08764602ee5c2ab6927.png b/tests/performance/expected_thumbnails/t2bot.io_20777c9ccca38567559ef08764602ee5c2ab6927.png deleted file mode 100644 index f8bf5f1784ea209219af2ca1c5b1dc2c059c496a..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_20777c9ccca38567559ef08764602ee5c2ab6927.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_3fab93bdf0643c191721426aa930aab9aa61fc47.png b/tests/performance/expected_thumbnails/t2bot.io_3fab93bdf0643c191721426aa930aab9aa61fc47.png deleted file mode 100644 index f20dae3edf4a200b7721a861336a9422fb935be3..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_3fab93bdf0643c191721426aa930aab9aa61fc47.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_4b7b400b9863e4be09014b00cb430fb63b5b60ac.png b/tests/performance/expected_thumbnails/t2bot.io_4b7b400b9863e4be09014b00cb430fb63b5b60ac.png deleted file mode 100644 index 84e8e6d930620a95f16dad372f20f202ae1eb42d..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_4b7b400b9863e4be09014b00cb430fb63b5b60ac.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_560e8403349cfbbc977129fb58c7c12be667294e.png b/tests/performance/expected_thumbnails/t2bot.io_560e8403349cfbbc977129fb58c7c12be667294e.png deleted file mode 100644 index 627671d3fad6f7507d1e9cf783dd1371fd9c4148..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_560e8403349cfbbc977129fb58c7c12be667294e.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_7e449b5990a142803038d4639c646d7a826a776d.png b/tests/performance/expected_thumbnails/t2bot.io_7e449b5990a142803038d4639c646d7a826a776d.png deleted file mode 100644 index d94bb684a014c1050625e1a0b34a1fd046f04a56..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_7e449b5990a142803038d4639c646d7a826a776d.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_8039dfbaeb0f2aa3e04d1275291d090206f84728.png b/tests/performance/expected_thumbnails/t2bot.io_8039dfbaeb0f2aa3e04d1275291d090206f84728.png deleted file mode 100644 index deb08e68f9d18e394ce75489a5913189e8c406df..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_8039dfbaeb0f2aa3e04d1275291d090206f84728.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_84acd2d1464a8bbdabde408b5f962b59a7a9f8c7.png b/tests/performance/expected_thumbnails/t2bot.io_84acd2d1464a8bbdabde408b5f962b59a7a9f8c7.png deleted file mode 100644 index 61afc6ab45250473f4bc886b0cf32a024facd330..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_84acd2d1464a8bbdabde408b5f962b59a7a9f8c7.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_89c4e87cd44a81ea20aca1b81e10a68fb295bd9c.png b/tests/performance/expected_thumbnails/t2bot.io_89c4e87cd44a81ea20aca1b81e10a68fb295bd9c.png deleted file mode 100644 index e56dc424ff3b637b724a1193b2d6830d1e6c6078..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_89c4e87cd44a81ea20aca1b81e10a68fb295bd9c.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_8ab3523920932d69e5f32303761f504a148ca66b.png b/tests/performance/expected_thumbnails/t2bot.io_8ab3523920932d69e5f32303761f504a148ca66b.png deleted file mode 100644 index fbc740106daffeb8df091d0ca1f235d571a41eb6..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_8ab3523920932d69e5f32303761f504a148ca66b.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_a1fda5b8102268243c5651a683a473d858841c64.png b/tests/performance/expected_thumbnails/t2bot.io_a1fda5b8102268243c5651a683a473d858841c64.png deleted file mode 100644 index 4528b91b7544b9e05bcc9e39138aa2df479a99a3..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_a1fda5b8102268243c5651a683a473d858841c64.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_a2cda3f751ef8261e959743c95ed6a36ad73fe4d.png b/tests/performance/expected_thumbnails/t2bot.io_a2cda3f751ef8261e959743c95ed6a36ad73fe4d.png deleted file mode 100644 index bde48e110eb78612239d26c3d60688297c753b5c..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_a2cda3f751ef8261e959743c95ed6a36ad73fe4d.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_a479b93f20a6589b11449250cb7720f3582bc4ac.png b/tests/performance/expected_thumbnails/t2bot.io_a479b93f20a6589b11449250cb7720f3582bc4ac.png deleted file mode 100644 index 9c7f900e8b9e34293c65b521f4ae0c359da4b591..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_a479b93f20a6589b11449250cb7720f3582bc4ac.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_a4d233b40227e2eac716f797794c54303f067fad.png b/tests/performance/expected_thumbnails/t2bot.io_a4d233b40227e2eac716f797794c54303f067fad.png deleted file mode 100644 index 083d4e4727e435aa581f872094f15900116a1f67..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_a4d233b40227e2eac716f797794c54303f067fad.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_af87cb7b79d2b099ba0379764aca7d2cf3d55ea2.png b/tests/performance/expected_thumbnails/t2bot.io_af87cb7b79d2b099ba0379764aca7d2cf3d55ea2.png deleted file mode 100644 index 507d81b120e0dfc64bfb9b7d7360ed71c1f7acdc..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_af87cb7b79d2b099ba0379764aca7d2cf3d55ea2.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_b02309d6c0a63595e262b081222aec2d432fef9a.png b/tests/performance/expected_thumbnails/t2bot.io_b02309d6c0a63595e262b081222aec2d432fef9a.png deleted file mode 100644 index cee0e99435718e077dbf3a7602429373ea32f75c..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_b02309d6c0a63595e262b081222aec2d432fef9a.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_c1a498a4a00e0932f55c0ed32305216b40d5f22a.png b/tests/performance/expected_thumbnails/t2bot.io_c1a498a4a00e0932f55c0ed32305216b40d5f22a.png deleted file mode 100644 index 6678e0a2f9ab4892025fe5e7251ec86f51962c3c..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_c1a498a4a00e0932f55c0ed32305216b40d5f22a.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_cd2fa571ec432e5bcbea0b2d56a87494590af01a.png b/tests/performance/expected_thumbnails/t2bot.io_cd2fa571ec432e5bcbea0b2d56a87494590af01a.png deleted file mode 100644 index 993738fb99ed66ef0a7c9e9dad1e5811a038a48e..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_cd2fa571ec432e5bcbea0b2d56a87494590af01a.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_d65b755940c9cc0d850ff42591268186fc7065f9.png b/tests/performance/expected_thumbnails/t2bot.io_d65b755940c9cc0d850ff42591268186fc7065f9.png deleted file mode 100644 index 313d14f66a69534028a41b05a1bcc0a4f74833c4..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_d65b755940c9cc0d850ff42591268186fc7065f9.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_dbbc7ea87cc44060147d641afd587b0efc9a5cd6.png b/tests/performance/expected_thumbnails/t2bot.io_dbbc7ea87cc44060147d641afd587b0efc9a5cd6.png deleted file mode 100644 index bba0d065c183d45f6b3b66af1e7d7c2e0d3a6617..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_dbbc7ea87cc44060147d641afd587b0efc9a5cd6.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_e31525ee69b9aa3cfa34e09317eb4c9d354fa6e5.png b/tests/performance/expected_thumbnails/t2bot.io_e31525ee69b9aa3cfa34e09317eb4c9d354fa6e5.png deleted file mode 100644 index f0281361c378e60ce087b322b548c70efa5f7b17..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_e31525ee69b9aa3cfa34e09317eb4c9d354fa6e5.png and /dev/null differ diff --git a/tests/performance/expected_thumbnails/t2bot.io_f645a8bd38d26e622492ec36b98f28332c1a60d1.png b/tests/performance/expected_thumbnails/t2bot.io_f645a8bd38d26e622492ec36b98f28332c1a60d1.png deleted file mode 100644 index 3a6f315bff9bbd66f0f74f0d1c3da66f40816bd4..0000000000000000000000000000000000000000 Binary files a/tests/performance/expected_thumbnails/t2bot.io_f645a8bd38d26e622492ec36b98f28332c1a60d1.png and /dev/null differ diff --git a/tests/performance/generate-expectations.js b/tests/performance/generate-expectations.js deleted file mode 100644 index ac28ba4ad36bb8ea7b3aa3e9c6f79c6328fb362d..0000000000000000000000000000000000000000 --- a/tests/performance/generate-expectations.js +++ /dev/null @@ -1,19 +0,0 @@ -const request = require("request-promise"); -const thumbnails = require("./thumbnails.json"); -const fs = require("fs"); - -const target = "http://localhost:8001"; - -async function download(mxc) { - console.log("Downloading " + mxc); - const result = await request(`${target}/_matrix/media/r0/thumbnail/${mxc.substring("mxc://".length)}?width=800&height=600&method=crop&animated=false`, {encoding: null}); - fs.writeFileSync("expected_thumbnails/" + mxc.substring("mxc://".length).replace(/\//g, '_') + ".png", result); -} - -console.log("Downloading thumbnails..."); -const promises = []; -for (const thumbnailMxc of Object.keys(thumbnails)) { - promises.push(download(thumbnailMxc)); -} - -Promise.all(promises).then(() => console.log("Done!")); diff --git a/tests/performance/index.js b/tests/performance/index.js deleted file mode 100644 index 5fd964d43c59b1bd41b2e4383f55c802c93f12ef..0000000000000000000000000000000000000000 --- a/tests/performance/index.js +++ /dev/null @@ -1,64 +0,0 @@ -const request = require("request-promise"); -const thumbnails = require("./thumbnails.json"); -const fs = require("fs"); -const mkdirp = require("mkdirp"); - -const target = "http://localhost:8001"; - -const requestTimes = []; -let failed = 0; -let corrupted = 0; - -async function thumbnailDefaults(mxc) { - const start = (new Date()).getTime(); - - const result = Buffer.from(await request(`${target}/_matrix/media/r0/thumbnail/${mxc.substring("mxc://".length)}?width=800&height=600&method=crop&animated=false`, {encoding: null})); - const expectedResult = fs.readFileSync("expected_thumbnails/" + mxc.substring("mxc://".length).replace(/\//, '_') + ".png"); - - if (Buffer.compare(result, expectedResult) !== 0) { - console.warn("Unexpected corruption!"); - corrupted++; - } - - return (new Date()).getTime() - start; -} - -function handleThumbnail(mxc) { - console.log("Starting download of " + mxc); - return thumbnailDefaults(mxc).then(t => requestTimes.push(t)).catch(() => failed++); -} - -const promises = []; -for (const thumbnailMxc of Object.keys(thumbnails)) { - for (let i = 0; i < thumbnails[thumbnailMxc]; i++) { - promises.push(handleThumbnail(thumbnailMxc)); - } -} - -console.log("Waiting for results..."); -Promise.all(promises).then(() => { - requestTimes.sort(); - - let average = 0; - for (const i of requestTimes) average += i; - average = average / requestTimes.length; - - const obj = { - failed, - corrupted, - requestTimes, - min: Math.min(...requestTimes), - max: Math.max(...requestTimes), - average, - median: requestTimes[Math.floor(requestTimes.length / 2)], - count: requestTimes.length, - }; - - console.log("Saving report..."); - mkdirp.sync("reports"); - fs.writeFileSync(`reports/${(new Date()).getTime()}.json`, JSON.stringify(obj, null, 2)); - - delete obj.requestTimes; - console.log(obj); - console.log("Done!"); -}); diff --git a/tests/performance/package-lock.json b/tests/performance/package-lock.json deleted file mode 100644 index 94d638d9e5f1a974a5400f98601cd8757e664829..0000000000000000000000000000000000000000 --- a/tests/performance/package-lock.json +++ /dev/null @@ -1,378 +0,0 @@ -{ - "name": "performance", - "version": "1.0.0", - "lockfileVersion": 1, - "requires": true, - "dependencies": { - "ajv": { - "version": "6.12.6", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", - "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", - "requires": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - } - }, - "asn1": { - "version": "0.2.4", - "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", - "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", - "requires": { - "safer-buffer": "~2.1.0" - } - }, - "assert-plus": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", - "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=" - }, - "asynckit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=" - }, - "aws-sign2": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", - "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=" - }, - "aws4": { - "version": "1.9.1", - "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.9.1.tgz", - "integrity": "sha512-wMHVg2EOHaMRxbzgFJ9gtjOOCrI80OHLG14rxi28XwOW8ux6IiEbRCGGGqCtdAIg4FQCbW20k9RsT4y3gJlFug==" - }, - "bcrypt-pbkdf": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", - "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", - "requires": { - "tweetnacl": "^0.14.3" - } - }, - "bluebird": { - "version": "3.7.2", - "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", - "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==" - }, - "caseless": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", - "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=" - }, - "combined-stream": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", - "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", - "requires": { - "delayed-stream": "~1.0.0" - } - }, - "core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" - }, - "dashdash": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", - "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", - "requires": { - "assert-plus": "^1.0.0" - } - }, - "delayed-stream": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", - "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=" - }, - "ecc-jsbn": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", - "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", - "requires": { - "jsbn": "~0.1.0", - "safer-buffer": "^2.1.0" - } - }, - "extend": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.2.tgz", - "integrity": "sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==" - }, - "extsprintf": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", - "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=" - }, - "fast-deep-equal": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz", - "integrity": "sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA==" - }, - "fast-json-stable-stringify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==" - }, - "forever-agent": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", - "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=" - }, - "form-data": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", - "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", - "requires": { - "asynckit": "^0.4.0", - "combined-stream": "^1.0.6", - "mime-types": "^2.1.12" - } - }, - "getpass": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", - "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", - "requires": { - "assert-plus": "^1.0.0" - } - }, - "har-schema": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", - "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=" - }, - "har-validator": { - "version": "5.1.3", - "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.3.tgz", - "integrity": "sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g==", - "requires": { - "ajv": "^6.5.5", - "har-schema": "^2.0.0" - } - }, - "http-signature": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", - "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", - "requires": { - "assert-plus": "^1.0.0", - "jsprim": "^1.2.2", - "sshpk": "^1.7.0" - } - }, - "is-typedarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", - "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=" - }, - "isstream": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", - "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=" - }, - "jsbn": { - "version": "0.1.1", - "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", - "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=" - }, - "json-schema": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.4.0.tgz", - "integrity": "sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==" - }, - "json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==" - }, - "json-stringify-safe": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", - "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=" - }, - "jsprim": { - "version": "1.4.2", - "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.2.tgz", - "integrity": "sha512-P2bSOMAc/ciLz6DzgjVlGJP9+BrJWu5UDGK70C2iweC5QBIeFf0ZXRvGjEj2uYgrY2MkAAhsSWHDWlFtEroZWw==", - "requires": { - "assert-plus": "1.0.0", - "extsprintf": "1.3.0", - "json-schema": "0.4.0", - "verror": "1.10.0" - } - }, - "lodash": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" - }, - "mime-db": { - "version": "1.43.0", - "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.43.0.tgz", - "integrity": "sha512-+5dsGEEovYbT8UY9yD7eE4XTc4UwJ1jBYlgaQQF38ENsKR3wj/8q8RFZrF9WIZpB2V1ArTVFUva8sAul1NzRzQ==" - }, - "mime-types": { - "version": "2.1.26", - "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.26.tgz", - "integrity": "sha512-01paPWYgLrkqAyrlDorC1uDwl2p3qZT7yl806vW7DvDoxwXi46jsjFbg+WdwotBIk6/MbEhO/dh5aZ5sNj/dWQ==", - "requires": { - "mime-db": "1.43.0" - } - }, - "mkdirp": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.3.tgz", - "integrity": "sha512-6uCP4Qc0sWsgMLy1EOqqS/3rjDHOEnsStVr/4vtAIK2Y5i2kA7lFFejYrpIyiN9w0pYf4ckeCYT9f1r1P9KX5g==" - }, - "oauth-sign": { - "version": "0.9.0", - "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", - "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==" - }, - "performance-now": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", - "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=" - }, - "psl": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/psl/-/psl-1.7.0.tgz", - "integrity": "sha512-5NsSEDv8zY70ScRnOTn7bK7eanl2MvFrOrS/R6x+dBt5g1ghnj9Zv90kO8GwT8gxcu2ANyFprnFYB85IogIJOQ==" - }, - "punycode": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==" - }, - "qs": { - "version": "6.5.2", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", - "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==" - }, - "request": { - "version": "2.88.2", - "resolved": "https://registry.npmjs.org/request/-/request-2.88.2.tgz", - "integrity": "sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==", - "requires": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.3", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.5.0", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2" - } - }, - "request-promise": { - "version": "4.2.5", - "resolved": "https://registry.npmjs.org/request-promise/-/request-promise-4.2.5.tgz", - "integrity": "sha512-ZgnepCykFdmpq86fKGwqntyTiUrHycALuGggpyCZwMvGaZWgxW6yagT0FHkgo5LzYvOaCNvxYwWYIjevSH1EDg==", - "requires": { - "bluebird": "^3.5.0", - "request-promise-core": "1.1.3", - "stealthy-require": "^1.1.1", - "tough-cookie": "^2.3.3" - } - }, - "request-promise-core": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.3.tgz", - "integrity": "sha512-QIs2+ArIGQVp5ZYbWD5ZLCY29D5CfWizP8eWnm8FoGD1TX61veauETVQbrV60662V0oFBkrDOuaBI8XgtuyYAQ==", - "requires": { - "lodash": "^4.17.15" - } - }, - "safe-buffer": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", - "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==" - }, - "safer-buffer": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", - "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" - }, - "sshpk": { - "version": "1.16.1", - "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", - "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", - "requires": { - "asn1": "~0.2.3", - "assert-plus": "^1.0.0", - "bcrypt-pbkdf": "^1.0.0", - "dashdash": "^1.12.0", - "ecc-jsbn": "~0.1.1", - "getpass": "^0.1.1", - "jsbn": "~0.1.0", - "safer-buffer": "^2.0.2", - "tweetnacl": "~0.14.0" - } - }, - "stealthy-require": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/stealthy-require/-/stealthy-require-1.1.1.tgz", - "integrity": "sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks=" - }, - "tough-cookie": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz", - "integrity": "sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==", - "requires": { - "psl": "^1.1.28", - "punycode": "^2.1.1" - } - }, - "tunnel-agent": { - "version": "0.6.0", - "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", - "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", - "requires": { - "safe-buffer": "^5.0.1" - } - }, - "tweetnacl": { - "version": "0.14.5", - "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", - "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=" - }, - "uri-js": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", - "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", - "requires": { - "punycode": "^2.1.0" - } - }, - "uuid": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz", - "integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==" - }, - "verror": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", - "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", - "requires": { - "assert-plus": "^1.0.0", - "core-util-is": "1.0.2", - "extsprintf": "^1.2.0" - } - } - } -} diff --git a/tests/performance/package.json b/tests/performance/package.json deleted file mode 100644 index 553ab7dad142a9afcb99c1af49ee52c4e4678581..0000000000000000000000000000000000000000 --- a/tests/performance/package.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "name": "performance", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "test": "echo \"Error: no test specified\" && exit 1" - }, - "author": "", - "license": "MIT", - "dependencies": { - "mkdirp": "^1.0.3", - "request": "^2.88.2", - "request-promise": "^4.2.5" - } -} diff --git a/tests/performance/thumbnails.json b/tests/performance/thumbnails.json deleted file mode 100644 index 1ed8135a433cce33253111eb960c2e7809ba1b81..0000000000000000000000000000000000000000 --- a/tests/performance/thumbnails.json +++ /dev/null @@ -1,30 +0,0 @@ -{ - "mxc://t2bot.io/00845bfa7e453d392f86b53eadbdbfd3d10d3fcd": 4, - "mxc://t2bot.io/a2cda3f751ef8261e959743c95ed6a36ad73fe4d": 25, - "mxc://t2bot.io/0850052a28cf72d91c77b52b74e67cc9fccd3607": 27, - "mxc://t2bot.io/a1fda5b8102268243c5651a683a473d858841c64": 27, - "mxc://t2bot.io/dbbc7ea87cc44060147d641afd587b0efc9a5cd6": 12, - "mxc://t2bot.io/1e4925f241581d27d5dfff7d7b0bfaf62714b4c3": 3, - "mxc://t2bot.io/180a386b83717f75785c4f0501ae1551ff448a1b": 3, - "mxc://t2bot.io/4b7b400b9863e4be09014b00cb430fb63b5b60ac": 6, - "mxc://t2bot.io/c1a498a4a00e0932f55c0ed32305216b40d5f22a": 6, - "mxc://t2bot.io/d65b755940c9cc0d850ff42591268186fc7065f9": 3, - "mxc://t2bot.io/a479b93f20a6589b11449250cb7720f3582bc4ac": 3, - "mxc://t2bot.io/144c17562179ad788652961dd5238e8796f6a0a5": 3, - "mxc://t2bot.io/8ab3523920932d69e5f32303761f504a148ca66b": 3, - "mxc://t2bot.io/84acd2d1464a8bbdabde408b5f962b59a7a9f8c7": 3, - "mxc://t2bot.io/e31525ee69b9aa3cfa34e09317eb4c9d354fa6e5": 3, - "mxc://t2bot.io/560e8403349cfbbc977129fb58c7c12be667294e": 6, - "mxc://t2bot.io/cd2fa571ec432e5bcbea0b2d56a87494590af01a": 6, - "mxc://t2bot.io/b02309d6c0a63595e262b081222aec2d432fef9a": 3, - "mxc://t2bot.io/a4d233b40227e2eac716f797794c54303f067fad": 6, - "mxc://t2bot.io/7e449b5990a142803038d4639c646d7a826a776d": 6, - "mxc://t2bot.io/af87cb7b79d2b099ba0379764aca7d2cf3d55ea2": 3, - "mxc://t2bot.io/20777c9ccca38567559ef08764602ee5c2ab6927": 3, - "mxc://t2bot.io/f645a8bd38d26e622492ec36b98f28332c1a60d1": 3, - "mxc://t2bot.io/8039dfbaeb0f2aa3e04d1275291d090206f84728": 3, - "mxc://t2bot.io/89c4e87cd44a81ea20aca1b81e10a68fb295bd9c": 6, - "mxc://t2bot.io/13754a79523fb6c96abdb06a52fd2b54788d1a2a": 3, - "mxc://t2bot.io/102d17f15f25e697d857c5d5003efcf27c36886f": 6, - "mxc://t2bot.io/3fab93bdf0643c191721426aa930aab9aa61fc47": 6 -}