|
I don't know the answer to the question about creating large numbers of user space objects. Given a large enough iSeries server, as a site like amazon.com would require, it would probably work well. With a site like that, I would probably have a background job(s) removing user spaces, perhaps by elapsed time since last accessed, etc. In addition, CGI programs could remove a session's user space whenever the user logically ends the session (in an order entry case, completing an order or indicating it should be abandoned). For other cases, the background job(s) would handle deletion. User indexes have limitations: maximum size: 4 GB; maximum entry length: 2000 bytes; maximum key length: 120 bytes. A user index can have either fixed or varying length entries. One would have to program for bumping into the 4 GB size limitation, which would be about 2 million 2,000 byte entries. Obviously, shorter entries would allow more entries to fit. One would also have to program for removing obsolete entries. By "associated space," I assume you mean multiple user index entries would reference a single user space, each reserving a unique range of bytes in the the user space. Since user spaces are limited to 16 MB, multiple user spaces would likely be required for each user index. I'm sure a combination of user indexes and user spaces (or user indexes alone with small amounts of data stored with the entry) would work. The programming would be more complex than that required for user spaces alone (once a user space exists, it is as simple as retrieving a pointer to the user space). My view, admittedly with no research behind it, is stick with user spaces alone unless designing for an Amazon like site. Then, do a lot of research and experimentation before deciding how to code it. Mel Rothman, CGIDEV2 Author IBM eServer Custom Technology Center (eCTC), Rochester, Minnesota http://www-1.ibm.com/servers/eserver/iseries/service/ctc/ http://www.easy400.ibm.it/en "Bob Cozzi (RPGIV)" wrote: > > Mel, > > I'd be interested in your view on using the following technique instead > of purely a user space. > > Consider an amazon.com or eBay.com website, literally millions of > visitors per day, with payment a few hundred thousand to a million > unique purchases per day (peak days). > > Would creating hundreds of thousands or millions of Users Spaces objects > would be okay? I don't know the answer to that question. > > Using a database file with millions of records presents its own issues. > > So, what if instead of using a user space, you used a User Index with an > associated space? The "key" to the index would be the session ID, with > the data stored either (a) in the key as well if it was just a few bytes > of data, or (b) stored in the associated space via an offset within the > index. > > What do you think? > > Bob Cozzi > cozzi@rpgiv.com > Visit the on-line Midrange Developer forum at: http://www.rpgiv.com > snip...
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.