Commit Graph

8745 Commits

Author SHA1 Message Date
Egon Elbre
9e0fff5e22 satellite/gcbf: fix data race in TestGCBFUseRangedLoop
Satellites[0].GCBF is already started when testplanet boots up,
so calling Run separately ends up causing a data race.

Instead create a new instance, that should avoid this issue.

Fixes https://github.com/storj/storj/issues/6435

Change-Id: I6603ef63da7a6ab8bdb952cf5aaca17eb0392e2c
2023-11-01 19:07:20 +02:00
Egon Elbre
0a4a1098d8 go.mod: bump common (and maybe fix quic)
Change-Id: Ib37213ab6d26d2b6adc727e913e3df3e12e9ee9d
2023-11-01 14:42:15 +02:00
Egon Elbre
38ad5a1318 private/testplanet: add STORJ_TEST_DISABLEQUIC environment flag
Currently Windows seems to dislike creating udp servers in a very
fast fashion. Add an environment flag that allows to disable quic,
which is the main culprit.

Individual tests can still override that setting.

Change-Id: I3b30c4aa7fcb148b2894335394fdfae6eaa372bb
2023-11-01 11:39:03 +00:00
Wilfred Asomani
b3e908f72f satellite/{console,web}: add browser card view config flag
This change adds config flag to toggle whether the browser card view
can be used.

Issue: #6427

Change-Id: I19986ffe9a778b8752549a4d54b318fff0386479
2023-10-31 20:19:57 +00:00
Egon Elbre
f2eb6942c5 satellite/metabase: make the precommit constraint code nicer
This condenses the precommit constraint into a single function, which
allows to cleanup a bunch of logic elsewhere. Also, avoid delete in the
first place when we are not allowed to remove the uncommited object.

This also fixes submitting the metrics and now it submits the correct
metrics.

Change-Id: If91dfa3b19bce5b24ff2a19d7c34b57a200db1dd
2023-10-31 18:10:09 +00:00
Egon Elbre
e5e55ef266 satellite/metabase: move delete object unversioned code
Change-Id: Iec92c91c174b990fa44b210db415da7a4eb650c4
2023-10-31 17:14:16 +00:00
Egon Elbre
46f7e5b7fa all: don't depend on infectious library directly
Change-Id: I0bcc719cc25e1d7ad36a16f65d40220eccba6556
2023-10-31 16:00:47 +02:00
dlamarmorgan
77cac8b465 satellite/metabase: add tests ListObjects
Change-Id: Ia84b560251245fe0050426537751958f2c85e9e1
2023-10-30 20:33:08 +00:00
Wilfred Asomani
513c3cc632 satellite/admin: list users pending deletion
This change adds an endpoint to the admin API and UI to get a list of
users pending deletion and have no unpaid invoice.

Issue: #6410

Change-Id: I906dbf9eee9e7469e45f0c622a891867bf0cc201
2023-10-30 19:11:16 +00:00
Jeremy Wharton
405491e8d0 web/satellite{/vuetify-poc}: implement CSV file previewing
This change allows .csv files to be previewed in the file browser.

Resolves #6426

Change-Id: Ib93ebb417b8f69231ed2b36b8258ad91c6a1ba4b
2023-10-30 17:35:48 +00:00
Jeremy Wharton
42e1b088c2 satellite/admin/back-office/ui: use composition API
This change migrates Vue components of the new satellite admin web app
from the options API to the composition API.

Change-Id: Ie8c9bcd468f1c0fe0abc9ef0a3724563db096ba9
2023-10-30 16:50:30 +00:00
Wilfred Asomani
8f59535f95 web/satellite: use stripe payment element
This change uses the recommended stripe payment element to collect card
information instead of the legacy card element currently in use.

Issue: #6436

Change-Id: If931d47430940e0932c845b6eee3e0e23c294fbb
2023-10-30 15:37:30 +00:00
Michal Niewrzal
67f32bd519 satellite/metainfo: use protbuf ObjectVersion with GetObject request
We need to update metainfo GetObject endpoint to use ObjectVersion
([]byte) field instead of old Version field (int32).

Change-Id: I61663ec8d9f5c731f91346a285048477fb493730
2023-10-30 14:49:18 +00:00
Wilfred Asomani
f7a95e0077 satellite/{payment,console}: add endpoint to add card by pmID
This change introduces a new endpoint that allows adding credit cards
by payment method ID (pmID). The payment method would've already been
created by the frontend using the stripe payment element for example.

Issue: #6436

Change-Id: If9a3f4c98171e36623607968d1a12f29fa7627e9
2023-10-30 13:58:55 +00:00
Vitalii
32e67e5fab web/satellite: update low token balance banner copy
Updated the copy for low token balance to correspond with a new use-case.

Change-Id: I1e08a039849c2950cdc4b8dc3b4c9f470461b0dd
2023-10-30 12:49:10 +02:00
Egon Elbre
1fa918c255 satellite/metabase: simplify UpdateObjectLastCommitted
Change-Id: Ifec596ab1868baa03688e717adec7d2ab45eafa9
2023-10-28 04:43:43 +00:00
Egon Elbre
55bddb6ce1 satellite/metabase: don't use empty stream id for delete markers
Using a an empty stream id makes it more difficult to target a specific
delete marker. Similarly, we don't want to confuse actual stream id-s
with normal ones. So, we'll create stream id-s where the first few bytes
are 0xFF, but the rest is random.

Change-Id: Ia7fffb0da9a071be2935df99c0846027ee2e03c3
2023-10-28 04:43:32 +00:00
dlamarmorgan
aeec4bd213 satellite/metabase: add tests to UpdateMetadata for versioning
Change-Id: I4503f92b19212e7c4cf1907edd7e529ff75cca3e
2023-10-28 04:43:04 +00:00
paul cannon
8be7414a52 cmd/tools/segment-verify: fix global race in TestCommandLineTool.
This should stop the failures when TestCommandLineTool is run with
parallel test execution enabled.

Change-Id: Id80d5eacb78fcec886be786ae8b182517b17fbc6
2023-10-27 19:51:24 +00:00
Ethan Adams
e65345336f satellite/placement: Add test for new "datacenter" placement tag
Change-Id: Ic9a79bb46256fbe8b1159de2bbf787b4a63c5c8f
2023-10-27 18:15:32 +00:00
Wilfred Asomani
667b7c6f79 web/satellite/vuetify-poc: fix file preview
This change fixes an issue where clicking on a file from the upload
snackbar would not preview it.

Issue: #6433

Change-Id: I30b0b6098e058d1069b87f99425fac5d6e421fea
2023-10-27 17:18:52 +00:00
Vitalii
539253f646 web/satellite: don't make billing API requests if billing is disabled
Removed billing API calls on all project dashboard if billing is disabled.

Change-Id: Ia3407c811e599f40670b97e1c2ad9a8f661c0e2a
2023-10-27 18:53:14 +03:00
Jeremy Wharton
4f07994bfb Jenkinsfile.premerge: style check satellite admin back office files
This change runs our style checker for assets related to the new
satellite admin web app in the pre-merge build. Additionally, the
testing and style checking for web assets has been parallelized.

Change-Id: I0835673435f7ed8a4704c9373fcf5bb8eb5e7d0a
2023-10-27 09:39:26 -05:00
Jeremy Wharton
8ebf285081 satellite/admin/back-office/ui: lint files
This change lints files for the new satellite admin web app. An
ESLint config has been added for it that is identical to the one used
for linting satellite web app files.

Change-Id: I66f72fb880d5cbc80b6c080294e4a830b3d28143
2023-10-27 11:23:58 +00:00
Egon Elbre
27724835da satellite/metabase: use database order in ObjectStream.Less
Change-Id: I3d5e00263d78d9128fae6d39a3bc7f0c542039b6
2023-10-27 07:38:51 +00:00
Egon Elbre
a4edbdd005 satellite/metabase: use commit order for objects
This changes metabase behavior such that the latest object
will be the committed object which may result in a new version
assigned to the objects.

Change-Id: I7a731d7db4696caba75fff65107a248569b6111f
2023-10-27 07:38:25 +00:00
Jeremy Wharton
eff1719977 satellite/admin/back-office/ui: speed up build command
This change speeds up the build of the new satellite admin web app
using the same method that 8b0d25c used to speed up the build of the
new satellite web app.

New build time:   23.394s
Old build time: 1m40.930s

Change-Id: Ic6fcfdfc73b78bc26bddc421c608076b23532967
2023-10-26 23:47:18 -05:00
Cameron
1aadc0974d web/satellite: project limit increase request
create modal to allow pro users to request project limit increase when
trying to create a project if they have reached the project limit.

github issue: https://github.com/storj/storj/issues/6298

Change-Id: I1799028e742c55197fa5d944c242053cf4dc3a2c
2023-10-26 14:24:52 -04:00
Egon Elbre
c8e4f0099c satellite/metabase: add Prefix status for non-recursive listing
Currently it's awkward to use any of the existing statuses for the
objects in non-recursive listing. Hence, let's add a new one.

Change-Id: I8485e0f858e69998b097e757091991538ca697fa
2023-10-26 15:37:24 +00:00
Vitalii
8b6c60f26b cmd/satellite: copy wasm files into app/static/wasm subfolder
Fixed docker command to copy files to app/static/wasm subfolder instead of app/static itself.

Change-Id: I50e605b9224d2c643cd5f6ae62a3610ed2a06752
2023-10-26 14:12:35 +00:00
Michal Niewrzal
20dfcedd97 satellite/metainfo: return full object on commit
We never extended metainfo protocol to return committed object
detailed into and this change is doing it now. Main motivation to
do this now is need for providing object version after upload.

Change-Id: Ib59bdfd9485e4a0091ac02458cc63427cb7159de
2023-10-26 09:46:18 +00:00
Michal Niewrzal
f5d717735b satellite/repair: fix checker and repairer logging
This is fixing two small issues with logging:
* repair checker was logging empty last net values as clumped pieces
but in main logic we stopped classifying it this way
* repairer summary log was showing incorrect number of pieces removed
from segment because list contains duplicated entries

There was no real issue here.

Change-Id: Ifc6a83637d621d628598200cad00cce44fa4cbf9
2023-10-25 22:55:53 +00:00
Wilfred Asomani
3ba452b301 web/satellite: fix signup logo alignment
This change fixes the alignment of the Storj logo on the registration
page on Safari.

Issue: #6429

Change-Id: I70a5c28a939c6a8975eb23ea1f409643b6da334a
2023-10-25 22:13:52 +00:00
Jeremy Wharton
ff16d2fa02 web/satellite: implement .txt preview
This change allows .txt files to be previewed in the legacy UI's
file browser.

References #6426

Change-Id: If0267695f07e6ea1738377527827c1e386fb668f
2023-10-25 21:32:22 +00:00
Vitalii
4ba2703783 satellite/{console, web}: remove AllProjectDashboard feature flag
Removed AllProjectDashboard feature flag.
Removed unused Vue components.
Fixed wrong redirect on reload if pricing packages are disabled.
Fixed wrong redirect on reload if billing features are enabled.

Issue:
https://github.com/storj/storj/issues/6434

Change-Id: I9081a6f737c45fb48da5b23c016a42e23021c4ce
2023-10-25 20:49:47 +00:00
Jeremy Wharton
f319af5a35 web/satellite/vuetify-poc: implement .txt preview
This change allows .txt files to be previewed in the Vuetify UI's
file browser.

References #6426

Change-Id: Ib84ca562d47a413af17890af160542da65425016
2023-10-25 20:06:26 +00:00
Vitalii
40e43826a9 web/satellite: extend low token balance banner use-case
Updated condition on when this banner should be shown.
Also, added this banner to project dashboard and billing pages.

Issue:
https://github.com/storj/storj/issues/6356
https://github.com/storj/storj/issues/6368

Change-Id: I2f8f587a3c75508df0a9a6e84e1684b3c3904aa7
2023-10-25 19:14:14 +00:00
Michal Niewrzal
4cbdc0342a cmd/tools/segment-verify: add CreatedBefore and CreatedAfter flags
We would like to verify only segments from specific periods of time.

https://github.com/storj/storj/issues/6431

Change-Id: I42610962022bdf6ee36815fe1c157d67792147b8
2023-10-25 18:06:46 +00:00
Márton Elek
bca46736bb satellite/contact: send evenkit entry only with existing fields
Change-Id: Ifdd6c14de5f99c3c9bb8b1e9e2dce8c1e1c3b1ed
2023-10-25 16:16:20 +00:00
Michal Niewrzal
6c2e66fa9e satellite/metabase: small addition to GetObject* tests
Change-Id: I057a432750bbe12b30127c91592747a86d7ca23c
2023-10-25 17:48:30 +03:00
Egon Elbre
504d5c5651 satellite/metabase: add version tests for GetLatestObjectLastSegment
Change-Id: Ia7ed1f6b23bcdc9e83fec288cbf3571b382d5e13
2023-10-25 17:39:57 +03:00
Egon Elbre
a7e1378f89 satellite/metabase: return more information from delete last committed
Change-Id: I2626a100e0c3c41631c9a29b0bf5a7afccc60957
2023-10-25 17:38:57 +03:00
Egon Elbre
97c98d72e4 satellite/metabase: adjust code for iteration
Change-Id: Id3d4efe228a6f2d3642a639ef66a30e178ca001a
2023-10-25 13:44:36 +00:00
Michal Niewrzal
988ebbaf8d satellite/metainfo: support deleting specific object version
Protobuf definition is ready to support deleting specific version of
object so we just need to wire requested version into metainfo
BeginDeleteObject endpoint.

Dependencies bumped to get latest metainfo protobuf definition.

https://github.com/storj/storj/issues/6221

Change-Id: Ifc3cc0b49d9acdf4f7e57e7184b0f2ae045f9113
2023-10-25 12:47:31 +00:00
Ivan Fraixedes
9338f3f088
private/apigen: Add a TypeScript client mock generator
Implement a TypeScript client mock generator to generate mocks with
static data specified in the API definition.

Change-Id: I11419f4bbf72576fcd829f9d4acd8471034ca571
2023-10-25 14:43:01 +02:00
Ivan Fraixedes
882c9d64e4
private/apigen: Create class for API errors (TypeScript)
Create a class that inherits the Javascript Error class to use it when
throwing errors on the TypeScript client when the ok property of the
Fetch API Response object is false, which means that the server
responded with a status code less than 200 or greater than 299.

The APIError class contains apart of the message, the response status
code which may be useful for the caller to decide what to do, for
example, it may decide to retry the call on certain response status
errors.

Change-Id: Ic48466b40cbf134a27d5c92a4af9f93232e84fca
2023-10-25 14:43:00 +02:00
paul cannon
39c2bb9e4b cmd/tools/segment-verify: add test for whole command line tool
Clarify and expand some tests, and add a large test that tries to cover
the whole segment-verify stack.

Trying to reproduce a problem we saw in production where the Found count
in the output csv increases with each entry, eventually reaching the
thousands, instead of representing the actual number of pieces found for
each entry.

Change-Id: I65e342fad7dc1c350830fd0c8ce75a87a01d495c
2023-10-25 10:21:53 +00:00
Egon Elbre
6939c7ec25 satellite/metabase: simplify delete code
Change-Id: Iaa89421423bce836bfb23ccd17adbf90b79599ef
2023-10-25 10:17:04 +00:00
Egon Elbre
ca9ab74df8 satellite/metabase/metabasetest: condense creation logic
Change-Id: I7f82c34fe5aab2a49e4c8feeacddc8fa0f8809e5
2023-10-25 10:14:47 +00:00
Egon Elbre
25c4e4eec1 satellite/metabase: move CollectBucketTallies
Change-Id: Ia7a4bac91b02c006513f3cf9b9266053d60e90e4
2023-10-25 10:13:43 +00:00