Activities of "liangshiwei"

You can share the project with me shiwei.liang@volosoft.com, I will check it asap.

Hi,

He is also a commercial customer not a support, you can see that he has no label of support team

Hi,

Let's discuss it here in https://support.abp.io/QA/Questions/5225/Error-Running-AuthServer-Project

I will refund your ticket and close this.

Hi,

Sorry for late.

Let me know your email address and I'll give you access to the repository for this solution that produces this error.

My email is shiwei.liang@volosoft.com, please share the project with me.

ok, I will check it.

Hi,

Please create a new question; thanks.

BTW, you can check this: https://support.abp.io/QA/Questions/5211

You can try this:

[ExposeServices(typeof(IConversationAppService))]
public class MyConversationAppService : ConversationAppService
{
    private readonly MyMessagingManager _myMessagingManager;
    private readonly IChatUserLookupService _chatUserLookupService;
    public MyConversationAppService(
        MessagingManager messagingManager,
        IChatUserLookupService chatUserLookupService,
        IConversationRepository conversationRepository,
        IRealTimeChatMessageSender realTimeChatMessageSender,
        IAuthorizationService authorizationService,
        MyMessagingManager myMessagingManager) : base(messagingManager, chatUserLookupService, conversationRepository, realTimeChatMessageSender, authorizationService)
    {
        _chatUserLookupService = chatUserLookupService;
        _myMessagingManager = myMessagingManager;
    }

    public override async Task<ChatConversationDto> GetConversationAsync(GetConversationInput input)
    {

        var targetUser = await _chatUserLookupService.FindByIdAsync(input.TargetUserId);
        if (targetUser == null)
        {
            throw new BusinessException("Volo.Chat:010003");
        }

        var chatConversation = new ChatConversationDto
        {
            TargetUserInfo = new ChatTargetUserInfo
            {
                UserId = targetUser.Id,
                Name = targetUser.Name,
                Surname = targetUser.Surname,
                Username = targetUser.UserName,
            },
            Messages = new List<ChatMessageDto>()
        };

        var messages = await _myMessagingManager.ReadMessagesAsync(targetUser.Id, input.SkipCount, input.MaxResultCount);

        chatConversation.Messages.AddRange(
            messages.Select(x => new ChatMessageDto
            {
                Message = x.Message.Text,
                MessageDate = x.Message.CreationTime,
                ReadDate = x.Message.ReadTime ?? DateTime.MaxValue,
                IsRead = x.Message.IsAllRead,
                Side = x.UserMessage.Side
            })
        );


        return chatConversation;
    }
}

[ExposeServices(typeof(MessagingManager), typeof(MyMessagingManager))]
public class MyMessagingManager : MessagingManager
{
    private readonly IUnitOfWorkManager _unitOfWorkManager;
    private readonly IUserMessageRepository _userMessageRepository;
    private readonly IConversationRepository _conversationRepository;
    private readonly IMessageRepository _messageRepository;

    public MyMessagingManager(
        IMessageRepository messageRepository,
        IUserMessageRepository userMessageRepository,
        IChatUserLookupService chatUserLookupService,
        IConversationRepository conversationRepository,
        ICurrentUser currentUser,
        IUnitOfWorkManager unitOfWorkManager)
        : base(messageRepository, userMessageRepository, chatUserLookupService, conversationRepository, currentUser)
    {
        _messageRepository = messageRepository;
        _userMessageRepository = userMessageRepository;
        _conversationRepository = conversationRepository;
        _unitOfWorkManager = unitOfWorkManager;
    }


    public new async Task<List<MessageWithDetails>> ReadMessagesAsync(Guid targetUserId, int skipCount, int maxResultCount)
    {
        var messages = await _userMessageRepository.GetMessagesAsync(CurrentUser.GetId(), targetUserId, skipCount, maxResultCount);

        //TODO: Optimize
        var readMessages = new List<Message>();
        foreach (var message in messages.Where(m => !m.UserMessage.IsRead).ToArray())
        {
            message.UserMessage.MarkAsRead(Clock.Now);
            await _userMessageRepository.UpdateAsync(message.UserMessage);

            message.Message.MarkAsAllRead(Clock.Now);
            readMessages.Add(message.Message);
        }

        var conversationPair = await _conversationRepository.FindPairAsync(CurrentUser.GetId(), targetUserId);
        if (conversationPair != null)
        {
            conversationPair.SenderConversation.ResetUnreadMessageCount();

            await _conversationRepository.UpdateAsync(conversationPair.SenderConversation);
            await _conversationRepository.UpdateAsync(conversationPair.TargetConversation);
        }

        try
        {
            using (var uow = _unitOfWorkManager.Begin(requiresNew: true, isTransactional: _unitOfWorkManager.Current?.Options.IsTransactional ?? false))
            {
                foreach (var message in readMessages)
                {
                    await _messageRepository.UpdateAsync(message);
                }
                await uow.CompleteAsync();
            }
        }
        catch (AbpDbConcurrencyException e)
        {
            // The messages are change by another request. So, we can ignore this exception.
        }

        return messages;
    }
}

Hi,

It looks like a problem, we will check and fix it.

Hi,

Ok so I create an application via the UI in ABP and I can use :connect/token to get a token. I did find in the logs other /connect apis like /connect/authorize ? Is there documentation on the connect apis or are they part of the OpenIddict documentation ?

Both openiddict and identityserver implement OpenID connect.

You can see all available endpoints at Discovery endpoint.

From a first look, Do you think this library can work in tandem with the exposed ABP /connect apis ? If you could provide any additional inputs on how to integrate this package with ABP/OpenIddict would be greatly appreciated.

Of course, it looks works.

Hi,

Could you share the project with me? I will check it. shiwei.liang@volosoft.com

Showing 3741 to 3750 of 6693 entries
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.1.0-preview. Updated on December 17, 2025, 07:08
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.