This module is great but it will not work if block caching is inactive, which it is when modules defining content access restrictions are enabled, which in essence forces all blocks to be cached until cached data is manually cleared under admin>>performance.
Comments
Comment #1
dwees commentedI haven't test this module with caching enabled or disabled. What happens when it is disabled? I'd like more information.
Dave
Comment #2
dwees commentedComment #3
miahawk commentedI'm using content access mods (ACL) which disables the option to enable or disable block caching, so the only way I have to refresh blocks is to do it manually.
This causes a problem for the chatblock, because it will not refresh so that other chatters can be read.
I'm assuming, although I can't verify, that disabling block caching allows the chatblock to function properly.
I'm not aware of any way to clear the cache for a particular block only, or to prevent it from caching, so I might be out of luck on this one unless the chat module can be run as a page.
Comment #4
dwees commentedThis seems like the opposite behavior to what you initially said in your bug report so let me clarify:
If you enable block caching (or have it enabled for you by a 3rd module like a content access module) then the Chatblock fails because it's providing real time dynamic content, and of course doesn't want to be cached.
If this is the case then this is a won't fix, and I'll explain my reasoning.
Block caching is intended to be used by high traffic sites. If your site is high traffic, and you use Chatblock, then you can expect your site to have an exceedingly high level of traffic because of the way Chatblock works. Each message sent back and forth is currently processed by the full Drupal engine. This isn't a very good way of doing a chat, but this is a development class module and I wrote it initially to see if I understood how to create a person to site to person chat module. It had the advantage of letting me reuse a lot of code provided by Drupal core (see filter_xss, check_plain, db_query, etc...).
If you enable this module for a small enough set of users, then you shouldn't have any issues with the overload on your server, these users will just be consuming a few more resources than everyone else. However you then want to be able to disable block caching for this user role, which is an issue with your content access module, not with this module.
However this should be mentioned in the download description for this module, so I will include it there.
Comment #5
miahawk commentedNo, it's not the opposite. I completely understand enabling or disabling block caching, and would love to be able to disable it because none of my blocks refresh and it's a pain to deal with and I have to figure out a way to flush the cached blocks, but for now I have to use ACL, which makes block caching inactive, so that it can neither be enabled or disabled, so it looks like there is an incompatibility between your module and ACL which cannot be resolved.
Comment #6
miahawk commentedthere's more info here, under cache_block: http://drupal.org/node/288488
it says if it's inactive, that block caching is disabled, but that's not what actually happening. blocks are being cached indefinitely.
Comment #7
dwees commentedAah well, if that's the case, then unfortunately you will need to raise an issue with the Drupal 6 project, and I need to put some warning text in the README.txt for this module. Thanks for clarifying. Re-opening this to remind myself that if I ever get more time to work on this module, that there is some more information I need to include.
Dave
Comment #8
miahawk commentedok, thanks. your module is really nice and simple which is why I like it so much. I tried to reinstall it so I could try to give an accurate report of the issue for the core project (and verify it's still there in 6.4) but couldn't get it to run for some reason. I'll try again when I have more time. I hadn't run across any other reports of block caching issues except for tagadelic, which I'm also seeing, and was hoping to find a way to force a flush of the cached blocks so I could use this mod. unfortunately I have not the skills :(
Comment #9
dwees commentedOkay so hopefully I've fixed this. I've switched the cache option on the block so that it is set at BLOCK_NO_CACHE which suggests that the block should not be cached, which means it should function normally.
Fix should be available to download in about 12 hours or so, or you can get it from CVS now.
Dave
Comment #10
miahawk commentedHi, I installed to test and for some reason I'm not getting the chatbox... the block loads in the page, but the block is blank. According to Firebug, the script is loaded and posting back on schedule... but I can't see it :(
Got any ideas for me? I'd love to test this.
Also, it looks like you removed the base_url from the admin/settings/chatblock but the readme still says to set it.
Thanks!
Comment #11
dwees commentedGood catch on the README.
You are using Firefox 3?
Dave
Comment #12
dwees commentedOkay, so I've just downloaded my module, and installed it into a test Drupal 6 site. It works as expected with no error messages in Firefox 3. Therefore I will need to know more information before I can figure out what is going wrong with your set up.
1. What browsers have you tested this in?
2. Have you tried it in a default theme (I do my testing in Garland).
3. Have you tried installing it by itself with no other modules?
I've even gone to the admin/settings/performance page and tried all sorts of different combinations of options with no effect on the performance of my Chatblock.
Dave
Comment #13
miahawk commentedI got up this morning and it was working! not sure what was up, but the textfield/send button had appeared.
tested in FF3 and safari, it works great! refreshing as it's supposed to, and it seems very fast. naturally I haven't yet tested it with multiple users but I will be sometime this month and will report back on my experience if you like.
THANK YOU for writing this mod.
I have a couple of feature requests I will log separately :)
Comment #14
dwees commentedExcellent. Just watch out, it is a full Drupal bootstrap, so it is really only useful for a limited number of people to use. Marking this as fixed then.
Dave