Commit Graph

341 Commits

Author SHA1 Message Date
Outzzz
d20fa79897 get inventory with language (#3409)
* get inventory with language

* get inventory with language

* edit

* edit
2025-04-14 09:15:11 +02:00
Łukasz Domeradzki
61f876480a General code cleanups 2025-03-31 00:06:05 +02:00
Łukasz Domeradzki
65c7a60c92 Switch to scalar for swagger-ui generation (#3391) 2025-03-18 19:47:43 +01:00
Łukasz Domeradzki
3f079a8fea Add new ASF API endpoint for inventory summary, add inventory command
Wow, new features in ASF?!
2025-02-16 17:26:51 +01:00
Łukasz Domeradzki
2f658a3d4e Closes #3376 2025-02-12 16:11:10 +01:00
Łukasz Domeradzki
f33fda8313 Misc 2025-02-09 21:15:24 +01:00
Łukasz Domeradzki
62ce58e148 Closes #3378 2025-02-09 21:14:05 +01:00
Sebastian Göls
c71fe556a3 Fix typo (#3382) 2025-02-04 09:08:24 +01:00
Łukasz Domeradzki
7e6a79dac2 Misc rename 2025-01-20 12:32:09 +01:00
Łukasz Domeradzki
ac01cca55e Go back to swagger in regards to #3376, add cmdline switch to force openapi 2025-01-20 11:49:35 +01:00
Łukasz Domeradzki
9e207025c5 Happy new year 2025-01-05 02:40:56 +01:00
Łukasz Domeradzki
3f98337459 Closes #3343 2025-01-05 02:32:05 +01:00
Łukasz Domeradzki
ba68d1010f Add optional filtering for plugins GET endpoint 2024-12-25 14:34:18 +01:00
Łukasz Domeradzki
acd081775d Misc Rider enhancements 2024-12-14 17:51:03 +01:00
Łukasz Domeradzki
540408a3d0 Fix kestrel deadlock in update procedure when using update command 2024-11-10 15:36:41 +01:00
Łukasz Domeradzki
7c481de811 Closes #3327 2024-11-06 17:40:05 +01:00
Łukasz Domeradzki
6dddaa5992 Fix kestrel deadlock in update procedure
This time for good
2024-10-27 18:48:26 +01:00
Łukasz Domeradzki
f2b8897ed1 Misc 2024-10-13 18:36:50 +02:00
Łukasz Domeradzki
f48caa08e9 Misc 2024-10-12 21:05:00 +02:00
Łukasz Domeradzki
f32fafdf15 Resolve eternal TODO with ASF API update routine 2024-10-12 21:03:11 +02:00
Łukasz Domeradzki
f534997e0e Close log endpoints upon graceful shutdown request
Previously we've kept websocket connection open for as long as caller requested it. During graceful shutdown, ASP.NET normally waits for all pending requests to finish, while no longer accepting new ones - this is a very good approach. In our case however, since we didn't do anything with that event before, the graceful shutdown was timing out after 30 seconds before eventually forcefully killing any still-ongoing requests, websocket connection in our case.

Hook into application lifetime in order to be notified when the graceful shutdown happens. This way we can create linked cancellation token for request abort and graceful shutdown and close the websocket connection when any of those two happens.
2024-10-04 17:58:56 +02:00
Łukasz Domeradzki
55d49f87ff Closes #3299 2024-09-30 22:02:09 +02:00
Łukasz Domeradzki
7b65c1aeb7 Add support for telling plugins if runtime is trimmed 2024-09-16 17:58:35 +02:00
Łukasz Domeradzki
773698a0d4 Closes #3264
THANKS @ezhevita
2024-08-05 02:37:50 +02:00
Łukasz Domeradzki
0d8f7b854d Misc 2024-07-10 00:21:56 +02:00
Łukasz Domeradzki
b9beb6ec16 Fix ASF trying to create www folder if it doesn't exist yet
It seems that ASP.NET is trying to create initialized WebRootPath if it doesn't exist yet. This might be unwanted, as user might want to explicitly disable www directory while still having interest in IPC. On top of that, ASF will outright crash if creating such directory will be impossible, e.g. because of insufficient permission.

It makes sense for us to check first if the directory exists - if not, we can omit it entirely, so ASP.NET will default to NullFileProvider and simply respond 404 to everything unhandled from the code perspective.

@SuperSandro2000 will resolve https://github.com/NixOS/nixpkgs/issues/312242 without a need of disabling IPC. In other words, you can use IPC with no www folder attached in order to still have ASF API and /swagger available. ASF will no longer crash in this scenario, it also won't try to create a directory on read-only filesystem.
2024-07-10 00:18:44 +02:00
Łukasz Domeradzki
b27dd345af Misc 2024-07-09 23:02:29 +02:00
Łukasz Domeradzki
f776e7947c Misc corrections of ASF API structures 2024-05-19 20:07:52 +02:00
Łukasz Domeradzki
416ec920cb Add AddLicense to ASF API 2024-05-19 20:07:41 +02:00
Łukasz Domeradzki
d6b5e3981c Misc swagger UI enhancements 2024-05-15 15:59:09 +02:00
Łukasz Domeradzki
6014b3bdc6 Add missing LicenseID inheritance from current 2024-05-10 13:27:49 +02:00
Sebastian Göls
81789c717f Misc. security improvements (#3200)
* Add x-security-critical to swagger schema and do not serialize LicenseID on IPC

* Apply feedback

* Misc.
2024-05-10 13:22:26 +02:00
Łukasz Domeradzki
8670cea7a3 Misc 2024-04-21 18:09:21 +02:00
Łukasz Domeradzki
0f30a0ef3d Fix IWebInterface with root WebPath 2024-04-20 23:37:57 +02:00
Łukasz Domeradzki
e550cc0f43 Misc 2024-04-16 10:39:03 +02:00
Łukasz Domeradzki
5894226e93 Add optional health checks to ASF API 2024-04-16 10:37:32 +02:00
Łukasz Domeradzki
14b0b332c5 Fix 2024-04-10 01:52:11 +02:00
Łukasz Domeradzki
42dec2de39 Misc
Thanks @xPaw
2024-04-09 16:33:54 +02:00
Łukasz Domeradzki
1841cde776 Misc code enhancements 2024-04-04 02:15:16 +02:00
Łukasz Domeradzki
f98fd85fe9 Misc 2024-03-25 23:03:49 +01:00
Sebastian Göls
f9f6e207d4 Add official monitoring plugin (#3160)
* Add Monitoring plugin

* Prepare pipeline

* Fix Rider stupidity

* Fix Windows build

* Remove translation files

* Apply feedback

* Add steam id as additional tag to metrics

* Apply feedback

* Add runtime metrics

* Fix my brain not braining

* Use extension methods to add instrumentation and Add monitoring for outbound HTTP traffic

* Upgrade OpenTelemetry.Extensions.Hosting to prerelease due to runtime exception

* Remove config and add file that was supposed to be committed yesterday to fix the runtime exception

* Revert changes to publish.yml

* Remove localization

* Apply feedback

* Apply feedback

* Fix version number

* Revert use of property in Kestrel (even tho it's an outside caller to the source class)
2024-03-25 22:58:03 +01:00
Sebastian Göls
0c4e4e709f Add POST /Api/Plugins/Update (#3173) 2024-03-25 22:57:47 +01:00
Archi
4c2a786e54 Add downgrade possibility in update command 2024-03-20 04:16:22 +01:00
Archi
b86f83a634 Misc 2024-03-17 02:54:28 +01:00
Archi
ff55e09783 Apply guid json converter only where we need it 2024-03-17 02:44:49 +01:00
Archi
48a14136a9 Update all file headers, again 2024-03-17 02:35:40 +01:00
Archi
f98a159799 File header update 2024-03-17 00:06:13 +01:00
Łukasz Domeradzki
aedede3ba4 Implement plugin updates with IPluginUpdates interface (#3151)
* Initial implementation of plugin updates

* Update PluginsCore.cs

* Update IPluginUpdates.cs

* Update PluginsCore.cs

* Make it work

* Misc

* Revert "Misc"

This reverts commit bccd1bb2b8.

* Proper fix

* Make plugin updates independent of GitHub

* Final touches

* Misc

* Allow plugin creators for more flexibility in picking from GitHub releases

* Misc rename

* Make changelog internal again

This is ASF implementation detail, make body available instead and let people implement changelogs themselves

* Misc

* Add missing localization

* Add a way to disable plugin updates

* Update PluginsCore.cs

* Update PluginsCore.cs

* Misc

* Update IGitHubPluginUpdates.cs

* Update IGitHubPluginUpdates.cs

* Update IGitHubPluginUpdates.cs

* Update IGitHubPluginUpdates.cs

* Make zip selection ignore case

* Update ArchiSteamFarm/Core/Utilities.cs

Co-authored-by: Vita Chumakova <me@ezhevita.dev>

* Misc error notify

* Add commands and finally call it a day

* Misc progress percentages text

* Misc

* Flip DefaultPluginsUpdateMode as per the voting

* Misc

---------

Co-authored-by: Vita Chumakova <me@ezhevita.dev>
2024-03-16 23:56:57 +01:00
Archi
e9f9663714 Fix https crash for kestrel core 2024-03-09 21:54:14 +01:00
Archi
1fd6c8a477 Minimize dependencies for starting IPC server
Previously WebApplication didn't offer any advantages over generic Host, but with release of .NET 8 there is now slim and empty builders, which limit amount of initialized dependencies and allow us to skip some unnecessary features in default pipeline.
2024-03-09 18:24:15 +01:00