Figure 8-6 presents the concepts you need for working with application dịch - Figure 8-6 presents the concepts you need for working with application Việt làm thế nào để nói

Figure 8-6 presents the concepts yo

Figure 8-6 presents the concepts you need for working with application state and caching. To start, an application is made up of all the pages, code, and other files that are located under a single directory in an IIS web server.
The first time a user requests a page that resides in an application’s directory, ASP.NET initializes the application. During that process, ASP.NET creates an application object from the HttpApplication class, an application state object from the HttpApplicationState class, and a cache object from the Cache class. You can use the application state object or the cache object to store data in server memory that can be accessed by any page that’s part of the application.
These objects exist until the application ends, which normally doesn’t happen until IIS shuts down. However, the application is also restarted each time you rebuild the application or edit the application’s web.config file.
So which application-level storage should you use? Generally, you’ll want to use the cache object, because it’s more flexible. This is because you can set expiration dates for items stored in the cache, and because the server is allowed to scavenge the cache when memory is running low. Because of this, you can store just about anything you want in the cache without worrying about negatively affecting the server, as long as you remember that the items may not be there when you come back for them. So, always, check for null values in your code before trying to use something you’ve retrieved from cache.
Caching is typically used to store application-specific data that changes infrequently. For example, you might use the cache to store discount terms and tax rates for an ordering system, or a list of the 50 states. Although you could retrieve this type of information from a database each time it’s needed, it can be retrieved more quickly from cache. As a result, using cached data can improve your application’s performance.
In contrast, items stored in application state stay in memory until they are specifically removed or until the application ends. This can have a negative effect on a server’s performance if a lot of data is stored. For this reason, it’s best to use application state for small items of data, such as keeping track of the users that are logged on to an application that provides a chat room or a forum
0/5000
Từ: -
Sang: -
Kết quả (Việt) 1: [Sao chép]
Sao chép!
Figure 8-6 presents the concepts you need for working with application state and caching. To start, an application is made up of all the pages, code, and other files that are located under a single directory in an IIS web server.The first time a user requests a page that resides in an application’s directory, ASP.NET initializes the application. During that process, ASP.NET creates an application object from the HttpApplication class, an application state object from the HttpApplicationState class, and a cache object from the Cache class. You can use the application state object or the cache object to store data in server memory that can be accessed by any page that’s part of the application.These objects exist until the application ends, which normally doesn’t happen until IIS shuts down. However, the application is also restarted each time you rebuild the application or edit the application’s web.config file.So which application-level storage should you use? Generally, you’ll want to use the cache object, because it’s more flexible. This is because you can set expiration dates for items stored in the cache, and because the server is allowed to scavenge the cache when memory is running low. Because of this, you can store just about anything you want in the cache without worrying about negatively affecting the server, as long as you remember that the items may not be there when you come back for them. So, always, check for null values in your code before trying to use something you’ve retrieved from cache.Caching is typically used to store application-specific data that changes infrequently. For example, you might use the cache to store discount terms and tax rates for an ordering system, or a list of the 50 states. Although you could retrieve this type of information from a database each time it’s needed, it can be retrieved more quickly from cache. As a result, using cached data can improve your application’s performance.
In contrast, items stored in application state stay in memory until they are specifically removed or until the application ends. This can have a negative effect on a server’s performance if a lot of data is stored. For this reason, it’s best to use application state for small items of data, such as keeping track of the users that are logged on to an application that provides a chat room or a forum
đang được dịch, vui lòng đợi..
Kết quả (Việt) 2:[Sao chép]
Sao chép!
Hình 8-6 trình bày các khái niệm bạn cần để làm việc với nhà nước ứng dụng và bộ nhớ đệm. Để bắt đầu, một ứng dụng được tạo thành từ tất cả các trang, code, và các file khác đang nằm dưới một thư mục duy nhất trong một máy chủ web IIS.
Lần đầu tiên người dùng yêu cầu một trang nằm trong thư mục của một ứng dụng, khởi ASP.NET các ứng dụng. Trong quá trình đó, ASP.NET tạo ra một đối tượng ứng dụng từ lớp HttpApplication, một đối tượng nhà nước áp dụng từ lớp HttpApplicationState, và một đối tượng bộ nhớ cache từ các lớp Cache. Bạn có thể sử dụng các đối tượng nhà nước ứng dụng hoặc các đối tượng bộ nhớ cache để lưu trữ dữ liệu trong bộ nhớ máy chủ có thể được truy cập bởi bất kỳ trang nào đó là một phần của ứng dụng.
Các đối tượng này tồn tại cho đến khi ứng dụng kết thúc, mà thông thường không xảy ra cho đến khi IIS tắt. Tuy nhiên, các ứng dụng cũng được khởi động lại mỗi khi bạn xây dựng lại các ứng dụng hoặc chỉnh sửa file web.config của ứng dụng.
Vì vậy mà ở cấp ứng dụng lưu trữ, bạn nên sử dụng? Nói chung, bạn sẽ muốn sử dụng các đối tượng bộ nhớ cache, vì nó linh hoạt hơn. Điều này là bởi vì bạn có thể thiết lập ngày hết hạn cho các mặt hàng được lưu trữ trong bộ nhớ cache, và bởi vì các máy chủ được cho phép để quét dọn bộ nhớ cache khi bộ nhớ đang ở mức thấp. Bởi vì điều này, bạn có thể lưu trữ chỉ là về bất cứ điều gì bạn muốn trong bộ nhớ cache mà không lo lắng về ảnh hưởng tiêu cực đến các máy chủ, miễn là bạn nhớ rằng các sản phẩm có thể không có được khi bạn trở lại cho họ. Vì vậy, luôn luôn, kiểm tra giá trị null trong mã của bạn trước khi cố gắng sử dụng một cái gì đó mà bạn đã lấy từ bộ nhớ cache.
Caching thường được sử dụng để lưu trữ dữ liệu ứng dụng cụ thể mà thay đổi thường xuyên. Ví dụ, bạn có thể sử dụng bộ nhớ đệm để lưu trữ các điều khoản chiết khấu và thuế suất đối với một hệ thống đặt hàng, hoặc một danh sách của 50 tiểu bang. Mặc dù bạn có thể lấy các loại thông tin này từ một cơ sở dữ liệu mỗi khi cần thiết, nó có thể được lấy ra nhanh chóng hơn từ bộ nhớ cache. Kết quả là, sử dụng dữ liệu được lưu trữ có thể cải thiện hiệu suất ứng dụng của bạn.
Ngược lại, các mục được lưu trữ trong ứng dụng của nhà nước ở trong bộ nhớ cho đến khi họ được cụ thể loại bỏ hoặc cho đến khi ứng dụng kết thúc. Điều này có thể có tác động tiêu cực đến hiệu suất của máy chủ nếu rất nhiều dữ liệu được lưu trữ. Vì lý do này, nó là tốt nhất để sử dụng nhà nước áp dụng cho các hạng mục nhỏ dữ liệu, chẳng hạn như theo dõi của người dùng đăng nhập vào một ứng dụng cung cấp một phòng chat hoặc diễn đàn
đang được dịch, vui lòng đợi..
 
Các ngôn ngữ khác
Hỗ trợ công cụ dịch thuật: Albania, Amharic, Anh, Armenia, Azerbaijan, Ba Lan, Ba Tư, Bantu, Basque, Belarus, Bengal, Bosnia, Bulgaria, Bồ Đào Nha, Catalan, Cebuano, Chichewa, Corsi, Creole (Haiti), Croatia, Do Thái, Estonia, Filipino, Frisia, Gael Scotland, Galicia, George, Gujarat, Hausa, Hawaii, Hindi, Hmong, Hungary, Hy Lạp, Hà Lan, Hà Lan (Nam Phi), Hàn, Iceland, Igbo, Ireland, Java, Kannada, Kazakh, Khmer, Kinyarwanda, Klingon, Kurd, Kyrgyz, Latinh, Latvia, Litva, Luxembourg, Lào, Macedonia, Malagasy, Malayalam, Malta, Maori, Marathi, Myanmar, Mã Lai, Mông Cổ, Na Uy, Nepal, Nga, Nhật, Odia (Oriya), Pashto, Pháp, Phát hiện ngôn ngữ, Phần Lan, Punjab, Quốc tế ngữ, Rumani, Samoa, Serbia, Sesotho, Shona, Sindhi, Sinhala, Slovak, Slovenia, Somali, Sunda, Swahili, Séc, Tajik, Tamil, Tatar, Telugu, Thái, Thổ Nhĩ Kỳ, Thụy Điển, Tiếng Indonesia, Tiếng Ý, Trung, Trung (Phồn thể), Turkmen, Tây Ban Nha, Ukraina, Urdu, Uyghur, Uzbek, Việt, Xứ Wales, Yiddish, Yoruba, Zulu, Đan Mạch, Đức, Ả Rập, dịch ngôn ngữ.

Copyright ©2024 I Love Translation. All reserved.

E-mail: