fasadin
fasadin
CC#
Created by fasadin on 5/13/2024 in #help
MassTransit unit test does not hit breakpoint in consumer
it looks like some mocked Consumer it's reading message and cosuming it. But how?
2 replies
CC#
Created by WAASUL on 2/10/2024 in #help
✅ Suggestion on file upload?
mobile app it's calling cloud host (azure) to do that he needs token. You can create seperate container and then give it access to correct path (for each user so other users won't be able to see / write other files) Then you might have some background job that moves is to correct place (if you want to have some confirmation done, that can be also there, for moderation purposes)
45 replies
CC#
Created by WAASUL on 2/10/2024 in #help
✅ Suggestion on file upload?
short lived token of course
45 replies
CC#
Created by WAASUL on 2/10/2024 in #help
✅ Suggestion on file upload?
then you can have some job that moves from there files to correct places
45 replies
CC#
Created by WAASUL on 2/10/2024 in #help
✅ Suggestion on file upload?
you can give token to decidated space to user. Let him upload to cloud
45 replies
CC#
Created by Iron on 2/1/2024 in #help
Should i use C# for this idea??
from business requirement that you gave, it does not matter, each solution will give you what you want. So choose stack depending on your personal preferences.
13 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
for anyone that would be interested I've endup with something like this
var profile = await new UserBuilder(_client)
.CreateUser()
.Then(userBuilder => userBuilder.VerifyUser())
.Then(userBuilder => userBuilder.Build())
.Then(user => Utils.HttpUtil.AuthenticateHttpClient(_client, user.Token))
.Then(client => new ProfileBuilder(client).ChangePreferredLanguage(language))
.Then(profileBuilder => profileBuilder.Build());
var profile = await new UserBuilder(_client)
.CreateUser()
.Then(userBuilder => userBuilder.VerifyUser())
.Then(userBuilder => userBuilder.Build())
.Then(user => Utils.HttpUtil.AuthenticateHttpClient(_client, user.Token))
.Then(client => new ProfileBuilder(client).ChangePreferredLanguage(language))
.Then(profileBuilder => profileBuilder.Build());
it's not ideal, but it's ok
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
for me it looks like you are not good with helping. If anyone challenges your advice (because in this case it's opinion, and not a real argument) then you are "offended" and leave what ever it is btw check Language.Ext nuget package, maybe that will help you a bit widen your horizons
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
ah, so when we expand example to be more difficult that does not fit your point, then you no longer have answer, so only you can say "whatever" and leave.
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
so creating N extra variables is not vervose and useless code, but one extra method for chaining is? 😄
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
even if that would mean to create 10-20 extra variables that have no purpose? oh, interesting
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
- in your example a and b have different types, in my example the have the same type - what if you have 10 other methods? Then you are going to have 10 other variables? Is it still readable and nice? Can it be solve with one method? (I think it can)
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
lol, so you defending your lack of knowledge with some bullshit that I am doing something against language 😄 next time if you don’t know something. Don’t respond, as you are clearly not capable of helping if it’s beyond your skill level Probably you didn’t even used templates if you are writing nonsense about writing millions of methods. Sad 😞
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
and it would be as first example
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
yes, but caller would does not see it
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
yes I understand, but there has to be workaround. You wrote yourself that he has no methods for it. So I can write extension method for Task<Foo> 😉
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
not for me, it’s ugly. If I have 10 more methods that I can chain then I will assign foo multiple times just to call next method
34 replies
CC#
Created by fasadin on 1/1/2024 in #help
Chaining async methods. Method not found
its similiar problem to this https://stackoverflow.com/questions/25302178/using-async-tasks-with-the-builder-pattern but having Then it's not a solution for me 😦
34 replies
CC#
Created by fasadin on 12/2/2023 in #help
Clean architecture, how to register dbcontext
thanks 🙂
27 replies
CC#
Created by fasadin on 12/2/2023 in #help
Clean architecture, how to register dbcontext
it would have to be entry point, but that's not easy as presentation layer it's most logical to be entry point
27 replies