在asp.net中存储临时数据的位置c# [英] Where to store temporary data in asp.net c#

查看:187
本文介绍了在asp.net中存储临时数据的位置c#的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我想在c#中建一个聊天室。一个代码项目文章建议我暂时将聊天存储在ArrayList中。我的问题是,不会为每2个客户端制作一个ArrayList会降低我服务器的响应速度吗?是否有任何特殊要求,我的服务器配置必须满足,如ram必须是那个大小及以上?或者如果我将来不需要它们,我必须用什么来存储2个用户的聊天?

任何建议都将受到高度赞赏。

谢谢,
Akky











@Humayun:是的,我希望它有点像hipchat,因为我想暂时存储它然后发送给用户,如果他/她要求但是这个聊天功能可用,直到用户退出应用程序。

谢谢,

Akky

Hello everyone,
I am trying to make a chat room in c#. A codeproject article adviced me to store the chats in ArrayList temporarily. My question is that wouldn't making an ArrayList for every 2 client slow down the responding speed of my server? Will there be any special requirement that my server config must fulfill like ram must be of that size and above? Or what must I use to store the chats of 2 users if I don't need them in future?
Any suggestion would be highly appreciated.
Thanks,
Akky





@Humayun : Yes, I want it to somewhat like hipchat as I want to store it first temporarily and then send to user if he/she demands but this feature of getting chat is available till the time user exits the application.
Thanks,
Akky

推荐答案

尽管可以在这个主题上找到很多文章,即聊天asp.net中的房间。



但是以下内容帮助我创建了一个聊天应用程序。



以下链接通过将消息存储在SQL表中,直到接收者接收到它来实现您所需的逻辑。



有关更多细节和实现,请下载zip项目并阅读完整的文章。



Chat-Application-in-ASP-NET-Using-AJAX-Pop-up



注意:应用程序在VB中,但可以通过任何在线转换器在C#中转换。





希望它会有所帮助您。 :)
Even though many of the articles can be found on this topic i.e. chat rooms in asp.net.

But the following has helped me a lot in creation of a chat application.

the following link implements your desired logic, by storing messages in a SQL table only untill the receiver receives it.

For further detail and implementation download the zip project and read the complete article.

Chat-Application-in-ASP-NET-Using-AJAX-Pop-up

NOTE: the application is in VB but can be converted in C# by any online converter.


Hope it will help you. :)


它取决于您要构建的聊天室类型。因为有很多方法可以存储您的消息。像雅虎在他们的服务器上存储他们的消息。它们不会在会话或数组上存储任何消息。在hipchat上,他们将消息发送给会员,如果会员离线,则消息将转到电子邮件。因此,首先要确定要构建的聊天室类型。

谢谢!
Its depends on what type of chat room you want to build. Because there are many way to store your message. Like yahoo store their message on their server. they don't store any message on session or array. On hipchat they send the message to the member and if member offline then message go to the email. So, First decide what type of chat room you want to build.
thanks!


这篇关于在asp.net中存储临时数据的位置c#的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆