|
|
 |
 |
 |
manilaSuite.rpcHandlers.message.listPictures
On bigger Manila websites, listing all messages in a category can "run away with the CPU" and bring the server to its knees. This is one a of a series of changes that alleviates this problem by adding a call to sys.systemTask in the tight loop.
Amended Script
| on listPictures (username, password, siteName) |
| |
«Get a struct containing info about all the pictures. |
| |
bundle //make sure this person is a member of the site |
| |
local (adrDiscuss = manilaSuite.rpcUtils.getDiscussAddress (siteName)) |
| |
local (adrMessages = @adrDiscuss^.messages) |
| |
local (adrSite = manilaSuite.rpcUtils.getSiteAddress (siteName)) |
| |
local (picturesCategory = manilaSuite.discuss.getPicturesCategory (adrSite)) |
| |
local (adrmsg, messagedata) |
| |
new (tableType, @messagedata) |
| |
for adrmsg in adrMessages |
Relative to Frontier version 9.7b10
|