Current development on JAMWiki is primarily focused on maintenance rather than new features due to a lack of developer availability. If you are interested in working on JAMWiki please join the jamwiki-devel mailing list.

Comments:JAMWiki 0.5.0

Contents

JAMWiki 0.5.0[edit]

Archived from the Feedback page

Release plans[edit]

This is the list of issues that may be addressed for JAMWiki 0.5.0.

  • LDAP support as described on Roadmap#LDAP Support. Update - there has been a ton of work done so far, with more to go. The latest code is now on jamwiki.org - please let me know if there are any problems with any functionality related to users. Additional work is needed to validate LDAP settings from the admin page, and more testing is needed, but for the most part this works for me and further feedback is requested.
  • User blocking as described on Roadmap#User blocking.
  • Spam filter as described on Roadmap#Spam filter.
  • Parser caching as described on Roadmap#Parser caching. Update - ehcache has been integrated, and image and topic information is now cached. I'm hesitant to cache parsed topic information since some parameters can vary from page view to page view and knowing when to clear the cache can be a difficult problem. Still investigating.
  • User and group permissions as described on Roadmap#User/Group permissions. This includes the ability to assign roles to users such as translator, admin, sysadmin.
  • Talk pages for anonymous users as described on Roadmap#Anonymous user talk pages.
  • XML import/export as described on Roadmap#XML Import/Export. Update: see Tech:XML import. Experimental XML import support will be included in JAMWiki 0.5.0 beta5.
  • Support for the H2 database.
  • Add support for the Mediawiki <gallery> tag.
  • Display warning when uploading an image and an image of the same name already exists.
  • Provide a way to delete image files.
  • Alphabetical index for pagination as described in #Allpages pagination.
  • Pagination will link to a page with no elements when total % offset = 0.
  • Create a page to view and edit a user's current watchlist, as is done with Mediawiki. Please take a look @ this feedback.
  • Add support for substitution such as {{subst:template}}.
  • Fix parameter substitution for named / unnamed per the spec. Update: from the code I suspect this may work, but I've not tested.
  • Potentially add support for the msgnw option (does anyone use this?).
  • Support for Mediawiki magic words. Update: as of JAMWiki 0.4.0 beta 8 a large number of the magic words are supported. Most likely full magic word support will come in a later release.
  • Template inclusion breaks section edit links (numbering off). Update: for now I've disabled section editing on pages that use template inclusion. This isn't a long-term solution, but thus far I haven't come up with a good way to handle this issue.
  • Provide translations for default topics as described in Roadmap#Translations_for_Default_Topics.
  • DB2 database support. Update: code added, just need someone to verify that it's solid.
  • When two headings have the same name the TOC always links to the first one.
  • Bug Reports#Character problem
  • "Link to" for redirects does not show final link destination. Update: this functionality isn't hard to add but has performance implications.
  • Add a "User contributions" link from user pages.
  • Address case sensitivity issues for topic names and user names. Update: constraint added to the database to ensure user logins are unique in a case-insensitive way.
  • Parsing of images is slow, so look into caching some image information to prevent the need to re-read images each time they are used. Now running on jamwiki.org, will be included in beta 3. I see a 4x speedup on pages with multiple images using this code.
  • Allow the parser to be used independently per Roadmap#Non-embedded parser.
  • Fix issue with Non-English file names and Tomcat 4.1.
  • The __TOC__ tag should display a TOC no matter how many headings there are. Fixed, and supported also added for the __FORCETOC__ tag. Both are now running on jamwiki.org and will be included in beta2.
  • Do not allow a page to be moved if it is admin-only or read-only. Fixed and the code is on jamwiki.org, will be included in beta2.
  • Cannot update user account - error "login already in use" Fix in the source code repository, will move to jamwiki.org when beta 1 is released.
  • Translated category namespace may cause failure when adding/removing categories - see #Categories.
  • File upload issue (again) - see #Problem with Upload. There was a bug in the previous fix, hopefully this is working now.
  • Address case-sensitivity issues with category names. Categories should now be handled case-insensitive, so "Category:Test" is the same as "Category:test". Will be included in beta 3.
  • Create a page listing all images, or possibly only uncategorized images, similar to http://en.wikipedia.org/wiki/Special:Uncategorizedimages. Special:Imagelist and Special:Filelist created, to be included in beta5.
  • Creating a new topic that contains a category throws a NPE. Updating an existing category and adding a category works fine. Fixed on jamwiki.org - problem was cache related. Will be included in beta4.
  • Fix login in UpgradeServlet to work with LDAP.
  • See issues in Tech:Acegi integration.
  • Watchlist syntax highlighting on Special:RecentChanges not working with "remember me" and Acegi. Hopefully fixed now - Acegi seems to have revealed a pre-existing bug in the taglib that was just never triggered before. Fix will be included in beta9.
  • Unabalanced HTML tags (such as </div> or </td>) can wreak havoc on page layout - JAMWiki needs to do some accounting to make sure tags are properly balanced.
  • Image resizing seems to be broken - large images are simply resized using width and height tags in the HTML.

JAMWiki 0.5.0 beta 1[edit]

Here's the first beta for JAMWiki 0.5.0 (finally!):

WARNING: This beta is likely to have more rough edges than normal, and I may make a few more database schema changes and other modifications during the 0.5.0 release cycle that will make upgrading from this beta difficult. As a result, this code is for testing only! Do not install it without making backups first. That warning aside, this code is currently running on jamwiki.org and has been stable for me.

The big change in this release is a more configurable interface for handling user validation, including support for LDAP. Have a look at the org.jamwiki.UserHandler interface, and let me know if you have any comments. Other changes include updated translations (German, Polish & Chinese), a few minor bug fixes, and several cleanups. See the CHANGELOG or the Subversion repository for all the gory details.

Feedback is appreciated as always, especially from anyone who can test with LDAP - LDAP validation can be configured from your installation's Special:Admin page. For others who are willing to help with testing, any bug reports or issues with user login, registration, and account updating would be most appreciated. -- Ryan 16-Nov-2006 17:17 PST

JAMWiki 0.5.0 beta 2[edit]

Here's the second beta for JAMWiki 0.5.0:

Changes since the first beta:

  • Support added for the __FORCETOC__ tag.
  • __TOC__ will force a TOC to appear even if there are fewer than four headings.
  • New jamwiki-configuration.xml file created to hold configuration information for parsers, user handlers (LDAP/database/other), pseudo-topics and namespaces. Two old properties file have been deleted as a result of this change.
  • Read-only and admin-only page permissions are now considered when allowing a user to move a page.

This code is currently running on jamwiki.org and appears to be fairly solid, but as always there are probably a few bugs hiding in it. Feedback, particularly from anyone who can test the LDAP code, is appreciated.

Note that with the Thanksgiving holiday coming up and some other real-life stuff on the horizon development may slow a bit over the coming weeks. The biggest remaining priority for the 0.5.0 release is getting a basic caching implementation working. Time permitting I'd also like to include user permissions, some way to block users, and a spam filter, although I suspect that those items could slip to a later release. If anyone has any other requests that they feel are important for the next release please let me know so that I can bump them up on the priority list. -- Ryan 18-Nov-2006 17:14 PST

JAMWiki 0.5.0 beta 3[edit]

After a very long wait, here's the third beta for JAMWiki 0.5.0:

Changes in this version include:

  • Initial ehcache support. The Sandbox topic loads 4x faster for me using this code.
  • Axel's bliki parser is now an option from Special:Admin. This parser provides syntax highlighting and some other goodies.
  • Updated Chinese, Polish & German translations.
  • Upload error with IE is hopefully fixed.
  • Categories are processed case-insensitive.
  • A few cleanups and minor fixes.

I don't want the JAMWiki 0.5.0 release cycle to drag on forever so there may not be much more work that occurs before the final release, although I would like to get out one or two more betas that potentially add the ability to block users, includes a spam filter, adds additional caching, and potentially abstracts the DatabaseHandler class to allow easier creation of alternative data handling methods. Other individuals have also discussed code to allow XML import and Acegi integration, so those are also features which could possibly find their way into the 0.5.0 release. -- Ryan 27-Nov-2006 17:16 PST

Just a quick note to anyone trying to use the current Subversion code - I'm in the process of implementing a more generic DataHandler interface, which should allow more flexibility in adding database-specific code, as well as support for other databases or data persistence formats. If you are upgrading from a version prior to 0.5.0 any changes should be made as part of the upgrade process, but if you previously upgraded your JAMWiki instance to 0.5.0 you'll need to modify the "database-type" property in jamwiki.properties. The value of this property should be the appropriate data handler class from org.jamwiki.db for your database, for instance "org.jamwiki.db.PostgresDataHandler". -- Ryan 28-Nov-2006 01:08 PST

JAMWiki 0.5.0 beta 4[edit]

Here's the fourth beta for JAMWiki 0.5.0:

The big change in this beta is that there is now a new DataHandler interface, which is implemented by the database handling code. This interface is used by any class that reads or writes Wiki data - using an interface like this should hopefully add some flexibility for future data handler implementations. The other big change comes from Axel and adds the option to display a WYSIWYG toolbar when editing. In addition there have been a few cleanups and bug fixes.

For anyone upgrading from an earlier JAMWiki 0.5.0 beta please see the note above about setting the "database-type" property value. For new installs and upgrades from version prior to 0.5.0 the upgrade/install process should work automatically as always. There will probably be one more beta to implement a user blocking filter, and after that the release candidates for 0.5.0 will start. Feedback is appreciated as always. -- Ryan 28-Nov-2006 20:25 PST

JAMWiki 0.5.0 beta 5[edit]

Here's the fifth beta for JAMWiki 0.5.0:

The changes since beta4 are:

It looks like the final release of JAMWiki 0.5.0 is going to get delayed a bit so that Rainer's work on Acegi integration can be included. Hopefully we can begin merging that to the trunk soon, and I'd suspect there will be at least two more betas to work out any issues and update some features. The result should be better security for JAMWiki, and more flexibility with authentication and page protection. In the mean time any feedback for the current beta is appreciated as always. -- Ryan 30-Nov-2006 18:05 PST

JAMWiki 0.5.0 beta 6[edit]

Here's the sixth beta for JAMWiki 0.5.0:

This beta includes Rainer's work on Acegi integration. It still has a few rough edges, and this code is not yet running on jamwiki.org, but for anyone interested in testing with Acegi this is worth looking at and has been solid for me on my local machine.

This beta also includes a fix for a bug that could allow anyone to login without providing a correct password (bug has only been present since beta4), updated Polish translations, HTML access keys for the edit page, and checks during setup for proper JDK version. Feedback is appreciated as always. -- Ryan 02-Dec-2006 23:27 PST

JAMWiki 0.5.0 beta 7[edit]

Here's the latest beta for JAMWiki 0.5.0:

This should hopefully work better with upgrades, includes lots of new Acegi work from Rainer, and Dutch translations. -- Ryan 05-Dec-2006 22:30 PST

JAMWiki 0.5.0 beta 8[edit]

Here's the eigth beta for JAMWiki 0.5.0:

This code is the first new code that has been used on jamwiki.org since Acegi was merged, and it seems reasonably stable so far. The changes this time include:

  • Translation updates for German, Chinese, Polish and new Dutch translations.
  • Support for PMD static code analysis, and numerous minor fixes for issues found by this tool.
  • Acegi should now display messages on the login screen to indicate why a login is required.
  • A few cache fixes.

I've been busy with a new job, but hopefully the final 0.5.0 will be ready in the next week or so. I'd like to make better use of some of the Acegi functionality, particularly for LDAP, prior to a final release, but I also don't want the development cycle to drag on forever. As always, feedback about this beta is appreciated. -- Ryan 10-Dec-2006 22:04 PST

JAMWiki 0.5.0 beta 9[edit]

There are still a few minor issues that need to be resolved, but once those are done with JAMWiki 0.5.0 should be ready:

The new job is taking up a lot of my time, and I'm still trying to understand all of the new Acegi code, but I'd really like to finish up this release soon. Anyone who has bugfixes, cleanups or translations is welcome to submit them, but please hold off on adding any new features until we start the release process for 0.5.1.

New code in this beta includes:

  • The ability for users to select a default locale (see Tech:Preferred Language).
  • Acegi updates from Rainers.
  • Updated translations for Dutch, Hungarian, German, and add new Ukranian translations.
  • A fix for the watchlist issue in beta 8.
  • New ANT build options from Rainers.
  • Option to open "Print" pages in a new window.
  • Bliki update from Axel.

Feedback is appreciated as always. -- Ryan 17-Dec-2006 23:25 PST

JAMWiki 0.5.0 release candidate 1[edit]

After far too long, here's the first release candidate for JAMWiki 0.5.0:

I tested a fresh install, as well as upgrades, using Postgres, MySql, and using the "internal database" option (HSql). Reports from users using other databases would be much appreciated. Translation updates are welcome, and minor bugfixes or cleanups are also OK, but there shouldn't be any other major changes prior to the final release, which should (hopefully!) happen before the end of the year. -- Ryan 26-Dec-2006 22:24 PST

JAMWiki 0.5.0 release candidate 2[edit]

I was hoping that JAMWiki 0.5.0 would be ready by now, but I found a few late issues that need a bit of time for testing, so here's a second release candidate:

This new release adds a lot of new Javadoc, fixes for upgrading with Oracle, and most noticeably some bugfixes that could have caused errors during page moves, deletion, or undeletion. I'll let this new code run on jamwiki.org for a couple of days, and if there aren't any surprises then JAMWiki 0.5.0 will be out by mid-week. Feedback is appreciated as always, especially by those who can provide reports about success or failure while upgrading using MS SQL, DB2, and other databases. -- Ryan 01-Jan-2007 17:41 PST

The final JAMWiki 0.5.0 release should go out tonight - if anyone has translation updates please submit them by 8:00 PM PST. In addition, if anyone has found any serious bugs please let me know - at the moment there aren't any outstanding showstopper bugs that I'm aware of. -- 03-Jan-2007 09:07 PST

Translator[edit]

Archived from the Feedback page

Hi,

I would like to contribute in the translation to the dutch language. Since it is preferred to use the translation tool, I would like to have acces to it. --Angel 04-Dec-2006 01:21 PST

Great! I've given you permission, so you should now be able to access Special:Translation - please let me know if you encounter any problems. Please also let me know what name to use to give you credit in the CREDITS file - most people simply use their real name followed by their login, such as "Ryan Holliday (wrh2)". Thanks for helping out! -- Ryan 04-Dec-2006 07:58 PST
Thanks for the translations! I've added them to the source code repository for JAMWiki 0.5.0, and you should now see Dutch labels on jamwiki.org as well. -- Ryan 05-Dec-2006 08:33 PST

No problem, I haven't finished yet but I'm getting there. For the name in the credits file you can enter Tarik Menbhi & Wim Borghs since my co-worker and I are working on it.

Problem with Upload[edit]

Archived from the Feedback page

I get this error message:

Ein unbekannter Systemfehler ist aufgetreten. Die Fehlermeldung lautet: java.io.FileNotFoundException: c:\progz\tom1\webapps\ROOT\wiki-files\2006\11\C:\test-21225149.gif (The filename, directory name, or volume label syntax is incorrect).

Is my configuration the problem ? I'm running jamwiki-0.5.0-beta2 on Win2000/Java5/tomcat5.0 I configured my uploaddirectory like this: c:\progz\tom1\webapps\ROOT\wiki-files\

I'm running into the same problem with version 0.4.3.

Thanx gomil

The problem is the uploaded file name - a small subset of browsers will pre-pend the full file name, in your case the "C:\". I was under the impression that the Commons Fileupload libraries would handle that, but apparently they don't. I'll get a fix into JAMWiki 0.5.0 - sorry for the trouble! -- Ryan 21-Nov-2006 14:52 PST
Thanx for the quick answer! I tried uploading with three different versions of InternetExplorer and allways get the above error ;( - Firefox works fine ;))) -- gomil 23-Nov-2006 10:03 GMT+1
OK, I found the bug, and you're right that it appears to be IE only. I've fixed it (hopefully!) on jamwiki.org and will include the fix for the next JAMWiki release. Thanks! -- Ryan 27-Nov-2006 15:58 PST

I have made new resources file based on JAMWiki 0.4.3[edit]

Archived from the Feedback page

that is newest resources file about JAMWiki. and i have upload it to jamwiki.org, you can find it on [1].

hfl 11-Nov-2006 05:57 PST

Thanks! I've added it to the source repository. I'd like to add you to the credits file, so please let me know what name you prefer - most people use their real name combined with their login, such as "Ryan Holliday (wrh2)". Thanks again! -- Ryan 11-Nov-2006 09:42 PST
hi, My Name is Feilong Huang (hfl). i'd like jamwiki.hfl 15-Nov-2006 06:37 PST
Thanks! I've added you to the CREDITS file and also added your latest translations to the source code repository. -- Ryan 15-Nov-2006 10:52 PST

Java cache - feedback requested[edit]

Archived from the Feedback page

One of the major development items for JAMWiki 0.5.0 is some sort of caching implementation to avoid the overhead of having to parse all page requests, and also to replace the current custom caching code. Per Axel's request I'm mainly looking at ehcache at this point, but if anyone has experience with other Java caching implementations please provide any feedback that is relevant. For what it's worth, features that I'm interested in include:

  • Small size. Ehcache is about 200kb and has no dependencies when using JDK 1.4 or greater.
  • Supports distributed caching. Eventually JAMWiki needs to be able to run on multiple servers, and the caching solution should support that.
  • Easy to use and flexible. I'd like to be able to have a cache that is configurable and allows for caching of all sorts of objects, from parsed documents to Java objects such as topics.

Any comments are appreciated as this is an area that I don't have a lot of experience in - projects I've worked on have generally built custom caching solutions. Also, I expect that the 0.5.0 development cycle will probably be 3-4 weeks, but I'd like to get some kind of caching implementation started early in that cycle in order to work out bugs and make sure things have time to be refined. -- Ryan 09-Nov-2006 23:07 PST

You may want to look at JCS. I haven't used it personally, but understand it's good. It's a bit bigger at 400kb. Here's a performance comparison between JCS and EH. -- scroco 14-Nov-2006 14:28 PST
Thanks - the fact that they are implementing something that is a JSR is a benefit. Once the LDAP work is done I'll look into JCS more closely. -- Ryan 14-Nov-2006 15:29 PST
I've been reading up a bit more on these two caching implementations - apparently EhCache started out as JCS, and the projects forked a few years ago. EhCache was stripped down and has since undergone significant additional development. It's used as the default caching implementation for Hibernate and also has support in Spring. JCS has more features, is probably faster, and is supposedly more mature. Both projects look like they'd be sufficient for JAMWiki, so I'm leaning towards EhCache due to its smaller size and Spring support. Further feedback is welcome if anyone has any other comments. -- Ryan 16-Nov-2006 23:40 PST
Another library worth to look at might be OSCache. -- Rainer 22-Nov-2006 05:09 PST
Thanks for the pointer - at about 125kb it's even smaller than ehcache. At this point I've already got ehcache integrated, but I suspect that it will be easy enough to allow the caching implementation to be a pluggable component, so that anyone who wants to can use their favorite caching solution. I'm not sure if that's going to get done for JAMWiki 0.5.0, but it should be easy enough to implement for a future release. -- Ryan 27-Nov-2006 16:36 PST
Check out | JBoss Cache. It supports clustering using replication or invalidation. 02-Jan-2006 17:32 CET

Newbie question: no table of contents[edit]

Archived from the Feedback page

I create a new page and add some headings. No toc appears on the top of the page. Also the __TOC__ command does'nt work. Is there any option to switch it on?

Two things to make sure of: you need to have at least four headings for a table of contents to appear (I should make that configurable), and you need to make sure that the "Use table of contents" option on Special:Admin is checked. If both of those are done and it still isn't working please let me know what the content of your page is so I can try to debug. -- Ryan 10-Nov-2006 10:43 PST
More then four headings and it works! Thanks a lot! - User:Ralf

Print[edit]

Archived from the Feedback page

Is it possible to open the printable view in a new browser window? This is recommendable if JAMWiki is embedded in a portal. And in my opinion it's good practice or at least acceptable for standalone use, too. -- Rainer 13-Dec-2006 07:34 PST

MediaWiki opens print pages in the same window, so rather than force a default I've added the ability to open printable page links in a new window as an option. There's an "open printable page links in a new window" checkbox on the admin screen. The code isn't yet on jamwiki.org yet. Let me know if that works for you or if you have any alternative suggestions. -- Ryan 13-Dec-2006 22:24 PST
Works great! Thanks, Ryan! -- Rainer 13-Dec-2006 23:46 PST

Image (or uploaded file) Listing[edit]

Archived from the Feedback page

There seems to be no way to list uploaded files... MediaWiki has a Special:Uncategorizedimages page that shows all images that don't have a Category (and the others you can find them through the respective Categories). The way things are currently here, if an uploaded file URL with no links is forgotten, it will remain so. -- João 28-Nov-2006 13:53 GMT

This should be easy to add - I'll add a to-do item. Thanks! -- Ryan 28-Nov-2006 10:30 PST
Special:Imagelist has been created and is live on jamwiki.org, and will be included in JAMWiki 0.5.0 beta5. Let me know if this meets your needs, and thanks for the feedback! -- Ryan 29-Nov-2006 02:55 PST
...in addition there is now also Special:Filelist that lists all non-image files. -- Ryan 29-Nov-2006 03:11 PST
Perfect! :) As for the Image/File division I'm not so enthusiastic, but I'll talk about it in Non-Image file upload naming. -- João 30-Nov-2006 15:20 GMT

0.4.3 to 0.5.0 Beta 6 upgrade issue[edit]

Archived from the Feedback page

I am probably just doing something wrong, but this is absolutely repeatable:

  1. Shut down web server (Tomcat 5.5.17).
  2. Delete generated java work/Catalina/localhost/wiki
  3. Replace .war file with new version
  4. Start webserver to explode war, Shutdown
  5. Copy existing jamwiki.properties into WEB-INF/classes
  6. Start webserver, point browser at wiki, get the following screen:

screenshot.jpg

  1. Enter admin/password
  2. Answer Ok to dialog box
  3. Receive response code 500!!

sysout log file contains the following traceback:

javax.servlet.jsp.JspException
	at org.jamwiki.tags.LinkTag.doEndTag(LinkTag.java:70)
	at org.apache.jsp.WEB_002dINF.jsp.wiki_jsp._jspx_meth_jamwiki_link_0(wiki_jsp.java:574)
	at org.apache.jsp.WEB_002dINF.jsp.wiki_jsp._jspx_meth_c_if_1(wiki_jsp.java:523)
	at org.apache.jsp.WEB_002dINF.jsp.wiki_jsp._jspService(wiki_jsp.java:163)
	at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
trimmed
	at java.lang.Thread.run(Unknown Source)
You're probably doing everything right - setup & upgrade are usually the last two things I test before a release because they are so problematic and break so often. One quick request though - if you're using Tomcat, can you make sure that the Tomcat work directory is cleaned? I've occasionally gotten JSP errors during upgrades due to cached Tomcat files. The Tomcat cache on my machine is in /Tomcat 5.5/work/Catalina/localhost, and all files in that directory can be deleted - your setup may be similar.
If I have time tonight I'll try to duplicate this error, and if I find anything I'll put a new beta out with a fix. Thanks for the bug report! -- Ryan 05-Dec-2006 20:07 PST
I was able to duplicate the error - apparently the database-type value in the jamwiki.properties didn't get properly updated. Hopefully beta7 works out. -- Ryan 05-Dec-2006 22:33 PST
I had punted and ported things over manually ;). Right now I am evaluating and playing, attempting to setup a structure for the information that will meet our needs, so there wasn't much content. Other than that the beta seems very stable. I did run into one other thing...

nomead 07-Dec-2006 06:21 PST

Watchlist code[edit]

Archived from the Feedback page

Because my installation does not use the JAMWiki login/registration system, the Utilites.currentWatchlist method doesn't work for me. I rewrote it a bit to work regardless of how a user is logged in.

    public static Watchlist currentWatchlist(HttpServletRequest request) throws Exception {
        Watchlist watchlist = (Watchlist)request.getSession().getAttribute(
            JAMWikiServlet.PARAMETER_WATCHLIST
        );
        if (watchlist == null) {
            WikiUser user = currentUser(request);
            if (user != null) {
                String virtualWiki = ServletUtil.getVirtualWikiFromURI(request);
                watchlist = WikiBase.getHandler().getWatchlist(virtualWiki, user.getUserId());
                request.getSession().setAttribute(
                    JAMWikiServlet.PARAMETER_WATCHLIST, watchlist
                );
            }
        }
        if (watchlist == null) watchlist = new Watchlist();
        return watchlist;
    }

Feel free to incorporate this if you think it's a good approach. -- scroco 14-Nov-2006 12:02 PST

Looks good to me, I'll update the code in the source repository.
On a related note, in order to support LDAP I'm in the process of splitting out all of the login/authentication code from the DatabaseHandler into its own interface. In effect that makes the jam_wiki_user_info table optional - user/password information can be stored there, or in LDAP, or somewhere else. The code is kind of in a state of flux at this point, but the changes that are in progress are:
  • Split WikiUser into WikiUser and WikiUserInfo, where WikiUserInfo contains email, first name, and last name. WikiUser will contain the wiki-specific values currently stored in the jam_wiki_user table.
  • Create a UserHandler interface to handle login/authentication and user info retrieval:
    • authenticate(login, password) - is the login/password valid.
    • lookupWikiUserInfo(login) - retrieve a WikiUserInfo object containing email, first name, last name.
    • canUpdate() - indicate whether the WikiUserInfo fields are update-able. For a read-only user-authentication system this would return false, and JAMWiki would not provide options to change passwords, email, etc.
Hopefully once this is done then anyone could implement their own login/registration by simply creating their own UserHandler instance. Since (as far as I know) you're the only person to use a custom login/registration system, please let me know if you have any suggestions. Once I've worked out further details I'll push out JAMWiki 0.5.0 beta1, which should contain working code to demonstrate where this work is heading. -- Ryan 14-Nov-2006 12:55 PST

That all sounds fine to me. I'll keep my eye on it as I integrate those new releases. As food for thought, I'll tell you what I did to make it work for me.

I turned WikiUser into an interface. Then created a DefaultWikiUser class (which is pretty much the existing WikiUser) and my own CustomWikiUser class. I created a new environment variable where you specify which WikiUser implentation you want to use, and then rewrote various methods to check for the user implementation and perform the appropriate actions, most notably the Utilities.currentUser method.

I also removed the login/out servlets and jsps from my build, and redirected the "sign on" and "sign off" links in the user-menu to my existing login/logout pages.

The way you're doing it sounds good (certainly more robust than my hack), and when I get to that build, I'll rework my installation to try it out that way and I'll let you know what I find.

I should warn you, that this wiki project is my "back burner" project most of the time, so when other, more important things come up, I'm forced to drop this for certain amounts of time. So I can't make promises as to timeliness of my feedback. -- scroco 14-Nov-2006 13:46 PST

I'm on my way out the door, so I'll need to digest your full post later, although it sounds like we're taking a similar approach. Re: the "back burner" comment, it's completely understood that everyone who contributes, be it the translators, database implementation maintainers, or others, have an ebb and flow. Some appear once, others appear sporadically over time, and some such as yourself seem to check in on a regular basis; all are very much appreciated. For my part, I've been lucky in that my real-world commitments have given me a lot of free time to pursue this project; that may actually change in the next week or so, in which case I'll be putting JAMWiki on my back-burner for a bit. In any case, I very much appreciate the semi-regular feedback and other help you've provided. -- Ryan 14-Nov-2006 14:13 PST

Upload problem[edit]

Archived from the Feedback page

I installed the system (very nice btw) and have been playing and ran across the following: uploaderror.jpg

when attempting to upload a file on my system in exactly the same way as I did this image here. I was able to upload on your server in the sandbox and (obviously) here, but got this message when attempting the upload from the same place on my client to my server (client and server are different machines).

There are no messages that seem relevant in the log file.

Any ideas?
Thanks!

nomead

ah - I take that back. When I attempted to upload the image here I got new behavior - I got the same message from the upload page, but the image did in fact get uploaded (it is visible here!).
Curiouser & Curiouser. I'll keep looking, but any insight welcome.

nomead

I suspect that you've hit #Problem with Upload, which will be fixed with JAMWiki 0.5.0, but that problem should also be fixed on jamwiki.org so I'll need to see why you might have gotten an error message here. In the mean time, to fix previous JAMWiki versions you can recompile with a fix (download the jamwiki-0.4.3-src.zip file and build using the instructions on Building from Source) by adding one line to the upload() method in src/java/org/jamwiki/servlets/UploadServlet.java:
// file name can have encoding issues, so manually convert
fileName = item.getName();
if (fileName == null) {
	throw new WikiException(new WikiMessage("upload.error.filename"));
}
// FIX - add the following line to fix IE issues with file names
fileName = UploadServlet.sanitizeFilename(fileName);
// END FIX
url = UploadServlet.buildUniqueFileName(fileName);
String subdirectory = UploadServlet.buildFileSubdirectory();
Sorry for the trouble, but thanks for a very detailed bug report! -- Ryan 03-Dec-2006 18:32 PST

Excellent! Thanks for the quick response, I'll check it out.

Topic un/delete[edit]

Archived from the Feedback page

If you delete a topic, then re-create the topic from scratch with the same name as the one you just deleted, then delete that topic. When you undelete the topic, it reverts back to the first version of the topic instead of the second version.

(I was going to show you an example using the page Giraffe, but I don't have the permissions to delete it) -- scroco 07-Sep-2006 15:43 PDT

I've added you as an admin on jamwiki.org, but please don't change any of the Special:Admin settings ;) One of the items on the to-do list is to create more specific roles, so that someone could be given access to the translation pages or the delete page without also having the ability to change the database settings.
Delete and undelete has proven to be fairly complex, so there may be a few of these sorts of issues. I'll take a look and see if the code & process could be simplified somewhat to address this sort of problem - let me know if you have any ideas for how best to handle this kind of thing. -- Ryan 08-Sep-2006 11:04 PDT

Actually, it's not working here the same way it works in my instance. I deleted Giraffe, then created it new. But now when I go to the Manage page, it gives me the option to un-delete instead of delete. -- scroco 08-Sep-2006 13:16 PDT

I think I've finally fixed this issue while investigating a different problem. The issue was due to the fact that the lookupTopic() method grabbed the first result it could find with a matching topic name and virtual wiki, despite the fact that for deleted topics there might be more than one matching record. I've added an ordering clause to the retrieval, so this issue should be resolved for JAMWiki 0.5.0. -- Ryan 01-Jan-2007 17:13 PST

JAMWiki 0.5.0 - thanks![edit]

Archived from the Feedback page

JAMWiki 0.5.0 was released tonight after a really long development cycle, and I just wanted to leave a note of thanks to everyone who contributed. By my count there were ten different people who added translations and code, at least that many others who contributed feedback and bug reports, and untold numbers of anonymous people who have downloaded the software. So thanks to everyone involved! -- Ryan 03-Jan-2007 22:34 PST