ServiceStack REST API Versioning practical questions
Our team is looking for a convenient way to implement versioning in our ServiceStack API implementation. I've read the articles: - https://stackoverflow.com/questions/12400071/servicestack-restful-res...
- Modified
- 29 Aug at 12:34
ASP.NET 6 CORS problems after adding IMiddleware for authorizing users
Recently, in a project I'm working on, I added a Role creation system. There are many actions in the system and we decided to let the user create their own roles. I added an implementation of IMiddlew...
- Modified
- 25 Jan at 11:21
Why do ServiceStack examples usually have a function definition of "object Any"
I notice most if not all ServiceStack example have services of this form: `public object Any(Request request) { }` Even if the function is always returning an integer. Why declare the function as `pub...
- Modified
- 19 Jan at 05:7
ServiceStack Timeout - ASP.NET executionTimeout
I'm using ServiceStack's JsonServiceClient but I've seen that despite setting the client timeout, the HTTP call still goes wrong after a certain period of time. I fixed this by setting the executionTi...
- Modified
- 12 Jan at 17:31
How to set up Basic Authentication with sessionId in ASP.NET Core MVC?
I have an ASP.NET Core MVC application in the front-end and I have a back-end service which is built with ServiceStack. This service has BasicAuth, which requires to send encrypted username+password a...
- Modified
- 9 Jan at 20:43
StackTrace inside an Exception in .Net Xamarin
Inside my .Net Xamarin app, I don't get a stack trace with this code: ``` new Exception().StackTrace ``` Why not, and how can I get it? If I call the following code, I get a `stackTrace` with one fr...
- Modified
- 3 Jan at 08:2
Non-existent table when RegisterTable | PocoDynaamo c#
I am trying to use PocoDynamo query for my dynamoDb. When I used POCO, I have non-existent table error. ``` var db = new PocoDynamo(dynamoDBClient); db.RegisterTable<Table>(); ``` I have faced this ...
- Modified
- 30 Dec at 10:44
Columns Physical Order in OrmLite
regards everybody: I have a data model for example: ``` [Alias("log")] public class Log { [AutoIncrement] [PrimaryKey] [Alias("id")] public int Id { get; set; }...
- Modified
- 23 Dec at 00:46
Why does db.select<T> is so slow when the model inherits from AuditBase?
I can observe that fetching all records from a small table (100 records) can take 1600 miliseconds, even using a ":memory:" SQLite database. This happens when the model inherits from `AuditBase`; oth...
- Modified
- 20 Dec at 05:18
How to override password verification in ServiceStack?
I have some people who login through standard ServiceStack authentication and some people whose passwords need to be compared to Active Directory. They use the same `CredentialsAuthProvider` and I wan...
- Modified
- 10 Dec at 08:9
How to call ServiceStack AutoQuery from AspNetCore HostedService
So I understands that ServiceStack is a different framework to AspNetcore, let's say a loyalty system where a user choose some criteria in filtering some customers using ServiceStack Autoquery, system...
- Modified
- 5 Dec at 02:27
Can I export service constants via "x typescript" command?
I have a search service and I would like the "default search query" constant to be exported to typescript for use in some clients. I have the following line in my .cs DTO `public string DefaultQuery {...
- Modified
- 27 Nov at 21:35
ServiceStack: Generate OpenAPI spec without creating the Service implementation classes
ServiceStack has support for OpenAPI and can generate an OpenAPI spec. However, for APIs/endpoints to be generated in the spec, it is not enough to specify the API details using the Route attributes a...
- Modified
- 28 Nov at 09:41
How to make Servicestack serialize an implicit string overload the way I want it to?
I have a small class which I am using to make sure the strings sent and received by a service remain URL safe without additional encoding (see below). Ideally I would like to just apply this type to m...
- Modified
- 22 Nov at 23:3
Filtering AutoQuery Results to Only Display Table Rows that Match Data in the Users Session
I'm working on a project that want's to control data access in a multi-tenant system. I've got a table set up which has a row on it that says what tenant the object applies to. Let's call this propert...
- Modified
- 21 Nov at 23:2
What are the advantages of using `lock` over `SemaphoreSlim`?
I'm late to the party, but I recently learned about [`SemaphoreSlim`][1]: I used to use [`lock`][2] for synchronous locking, and a `busy` boolean for asynchronous locking. Now I just use `SemaphoreSli...
- Modified
- 5 May at 16:46
Why is the Enumerable.Any(Func<TSource, bool> predicate) slow compared to a foreach with an if statement when searching a List<T>
Something has piqued my curiosity recently.. is the `Enumerable.Any(Func<TSource, bool> predicate)` method than manual foreach, I've been messing with some benchmarks and thought of this. I'm check...
Use AuthFeature but disable SessionFeature?
I have a ServiceStack service that is always sent a JWT every request, so it seems to me that I do not need a persistent session whatsoever. How can I disable the SessionFeature yet keep the JwtAuthPr...
- Modified
- 18 Nov at 01:33
Why does Microsoft have both Avalonia UI and .NET MAUI?
.Net Conf is currently underway and I learnt about something called Avalonia UI. (I use .NET MAUI) After doing some research, Avalonia UI was primarily a desktop UI framework that now supports Android...
- Modified
- 5 May at 14:55
Could not load file or assembly 'System.Runtime, Version=7.0.0.0...' - After installing .NET Core 7 'dotnet watch run' not working
After the .Net 7.0 update, when I use `dotnet watch run` I get this error: > Unhandled exception. System.IO.FileNotFoundException: Could not load file or assembly 'System.Runtime, Version=7.0.0.0, Cul...
- Modified
- 21 Nov at 11:6
SDK Resolver Failure - Net 7 - Net 6
Just downloaded and installed SDK Net 7.0.100 and it broke existing applications and they won't load any more in VS 2022 or Rider. Copied the follwing error: ``` error : SDK Resolver Failure: "The SD...
- Modified
- 16 Nov at 09:10
Why does sending via a UdpClient cause subsequent receiving to fail?
I'm trying to create a UDP server which can send messages to all the clients that send messages to it. The real situation is a little more complex, but it's simplest to imagine it as a chat server: ev...
How to obtain progress feedback on long running async API calls in ServiceStack
We make several long-running, async, API calls using the Jsonclient to a ServiceStack host. These calls perform a number of closely linked tasks. I would like to obtain some feedback as to the curre...
- Modified
- 29 Oct at 02:56
How do you access the user's bearer token in a ServiceStack service?
I have a ServiceStack service which is receiving a bearer token, the bearer token then needs to be passed onto Microsoft Graph for additional API calls from the server side What is the best way to acc...
- Modified
- 27 Oct at 22:21
How does a Span survive garbage collection?
I'm pretty convinced that creating a Span from an array doesn't fix (in the sense of the `fixed` keyword) the underlying array, otherwise there wouldn't be a need for `Span.GetPinnableReference` and s...
- Modified
- 12 May at 04:18