The Main.RecentChanges page is failing on myxwiki (apparently all subwikis) and I was able to get some information out of it.
The problem can be isolated to the query in this snippet, it works on my local wiki installation with postgres but fails on the incubator.
{{velocity}}
$xwiki.searchDocuments(", XWikiRCSNodeInfo as ni where doc.id=ni.id.docId and ni.id.version2=1 group by doc.space, doc.name order by max(ni.date) desc", 1, 0)
{{/velocity}}
This is the generated hql query I got from the logs on my local machine where the query succeeds.
select distinct doc.space, doc.name, max(ni.date) from com.xpn.xwiki.doc.XWikiDocument as doc , com.xpn.xwiki.doc.rcs.XWikiRCSNodeInfo as ni where (doc.hidden <> true or doc.hidden is null) and doc.id=ni.id.docId and ni.id.version2=1 group by doc.space, doc.name order by max(ni.date) desc
here is the query from the error message from trying to run the above snippet (or the RecentChanges page)
select distinct doc.space, doc.name, max(ni.date) from XWikiDocument as doc , XWikiRCSNodeInfo as ni where (doc.hidden <> true or doc.hidden is null) and doc.id=ni.id.docId and ni.id.version2=1 group by doc.space, doc.name order by max(ni.date) desc
They appear to be functionally identical, maybe the query is different from 2.1 and is disagreeing with the mysql version on myxwiki, or perhaps something is just misconfigured. It doesn't seem like the db is corrupt since it happens on multiple subwikis.
The bottom part of the stack trace.
Caused by: com.xpn.xwiki.XWikiException: Error number 3223 in 3: Exception while searching documents with SQL [select distinct doc.space, doc.name, max(ni.date) from XWikiDocument as doc , XWikiRCSNodeInfo as ni where (doc.hidden <> true or doc.hidden is null) and doc.id=ni.id.docId and ni.id.version2=1 group by doc.space, doc.name order by max(ni.date) desc]
Wrapped Exception: could not execute query
at com.xpn.xwiki.store.XWikiHibernateStore.searchGenericInternal(XWikiHibernateStore.java:2470)
at com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentReferencesInternal(XWikiHibernateStore.java:2426)
at com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentsNamesInternal(XWikiHibernateStore.java:2413)
at com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentsNames(XWikiHibernateStore.java:2190)
at com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentsNames(XWikiHibernateStore.java:2169)
at com.xpn.xwiki.store.XWikiCacheStore.searchDocumentsNames(XWikiCacheStore.java:373)
at com.xpn.xwiki.api.XWiki.searchDocuments(XWiki.java:491)
at sun.reflect.GeneratedMethodAccessor279.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:389)
at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:378)
at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:270)
... 80 more
Can't be too careful.
Caleb
On 03/02/2010 08:20 PM, Thomas Mortagne wrote:
> On Tue, Mar 2, 2010 at 18:25, Sergiu Dumitriu<sergiu(a)xwiki.com> wrote:
>> On 03/02/2010 05:01 PM, Joel Forsberg wrote:
>>>
>>> Greetings
>>>
>>> On my wiki using swedish characters for xwiki page titles give ugly but
>>> working entries in all panels, e.g. "Backlinks" "Recent modifications" and "My
>>> recent modifications"
>>>
>>> An example is having:
>>> "Startsidor för våra intresseområden"
>>> ...instead of the correct:
>>> "Startsidor för våra intresseområden"
>>>
>>> Another example is putting thiss wiki code on top of a page:
>>> = header that<look ugly> here =
>>>
>>> The script responsible for for the texts in the panels is as follow:
>>>
>>> <span class="panelitem">
>>> <a href="$rdoc.getURL('view')">
>>> $xwiki.getXMLEncoded($rdoc.displayTitle)
>>> </a></span>
>>>
>>> I've noticed that changing the third line into only $rdoc.displayTitle will
>>> produce a nice looking entry, and $rdoc is set via
>>>
>>> #set($rdoc = $xwiki.getDocument($docname).getTranslatedDocument())
>>>
>>> Now, can anyone see a purpose of using getXMLEncoded() for this? As far as I
>>> have seen, it only breaks things.
>>
>> This is not caused by getXMLEncoded, it merely makes the problem
>> visible. This method must be used in order to prevent other problems:
>> Invalid XML, broken layout, XSS...
>>
>> The problem is that the code inside getDisplayTitle wrongly uses a XML
>> escaping option.
>
> No, this is valid because the job of $rdoc.displayTitle is to produce
> xhtml content and theses are valid XML escapes.
Where does it say that it should produce xhtml content?
Assuming that it should produce xhtml, the behavior is inconsistent. If
the title is placed in the document.title field, then it returns
characters; if it is placed in the first heading, it returns escapes. If
we use wiki syntax in the document.title, we get back wiki syntax; if we
use wiki syntax in the first heading, we get back HTML. That is totally
inconsistent and confusing.
This is an API design problem that should be discussed further on the
dev list.
Going back to this specific problem, I think that it should be solved by
using the plaintext output syntax, since inside a panel we're not
interested in formatting or other markup inside the title, just the
textual content.
> So you don't need to
> use getXMLEncoded because any xml content is already properly escaped
> (in xwiki/2.0 syntax).
I need to use getXMLEncoded because the title doesn't always come from
the content.
> When you want a plain text version of the title you should use
> $rdoc.getRenderedTitle("plain/1.0").
--
Sergiu Dumitriu
http://purl.org/net/sergiu/
On 4 Mar 2010, at 13:58, Stephen Dawkins wrote:
> Hi
>
> Unfortunetly there's a bug/limitation[1] in the Firefox implementation
> of that method that means you can't use a self-signed certificate to
> sign the text.
>
> I've already knocked up a patch to fix it, but it seems no one is
> particularly interested in getting it included.
I voted for it. Anyone interested should vote for it too.
While you are at it also vote for
https://bugzilla.mozilla.org/show_bug.cgi?id=396441
>
> [1] https://bugzilla.mozilla.org/show_bug.cgi?id=403909
>
> Regards
> Stephen
>
> On 04/03/2010 09:58, Story Henry wrote:
>> On another mailing list Caleb pointed out the following:
>>
>> On 4 Mar 2010, at 00:29, Caleb James DeLisle wrote:
>>
>>> Firefox and Opera Javascript have a method crypto.signText() which apparently will support
>>> signing of form data on the client side which has a wide array of use cases including
>>> signing XWikiDocuments in so they can be imported and exported while retaining their author field.
>>> see: http://docs.sun.com/source/816-6152-10/sgntxt.htm
>>
>> This does indeed sound like it could be another very useful application of foaf+ssl.
>>
>> Henry
>>
>> _______________________________________________
>> foaf-protocols mailing list
>> foaf-protocols(a)lists.foaf-project.org
>> http://lists.foaf-project.org/mailman/listinfo/foaf-protocols
Hi,
I have built a little keygen application for Xwiki now. It is available here:
http://github.com/bblfish/keygenapp
You can download it with
$ git clone git@github.com:bblfish/keygenapp.git
then you should be able to build it with
$ mvn clean package
$ mvn dependency:copy-dependencies
You will then just need to copy two jar files over to
webapps/xwiki/WEB-INF/lib/
* target/xwiki-foafssl-component-0.2.jar
* target/dependency/bcprov-jdk16-141.jar
Because I am not yet sure how to get the XAR plugin to work, I have not automated the build yet for that piece. Please let me know how I should fix this. Essentially there are two files that need to be installed
$ ls -l1 src/main/resources/XWiki/*.xml
src/main/resources/XWiki/foafssl_RSAPubKey.xml
src/main/resources/XWiki/foafssl_create_cert.xml
the first one there is just a class, the second one is a script that will allow you to get a certificate in one click.
In order to then have that be visible to your homepage you need to replace the content of the
XWikiUserProfileSheet with the content of
src/main/resources/XWiki/XWikiUserProfileSheet.html
You will then be able to try to login to a few other services (there is a link provided on the page). I will work next on allowing Xwiki to be logged into too with foaf+ssl (as well as on fixing any bugs you let me know of)
Henry
Social Web Architect
http://bblfish.net/
Dear dev guys
I'm Giuseppe Vallarelli an Italian computer science student from Bari
(headache on irc-channel), and i would contribute to XWiki project.
I'm a new to opensource development and web application development field,
but i'm a rapid learner and a passionate person :), in my
spare time i've spent some time learning test driven development using JUnit
4.x but i'm not an expert neither in tdd nor in development
i think that to really learn about something one person should practice a
lot and overcomes obstacles :).
I'm very grateful to Sdumitriu, Vincent Massol and CalebJamesDeLisl for help
me with the build of XWiki from sources.
How can i contribute to XWiki? I would like to contribute with development,
mabye submitting patch, but the problem is that i've never submitted
a patch. I need some guidance :). I've never managed a big project like
XWiki.
Giuseppe headache Vallarelli
P.s. Of course i would like to partecipate to GSoC 2010 with XWiki nice
development team :-)
N.b. I apologize for my imperfect english, i will imporve my writing skills
with time.
Hi devs,
I've found and fixed an important bug in XE 2.2.1:
http://jira.xwiki.org/jira/browse/XWIKI-4965
I propose to release XE 2.2.2 ASAP (i.e when Thomas is available since he's the release manager of XE 2.2.x).
In addition to this bug there are several other important fixes too:
Bug
• [XWIKI-4555] - XWikiHibernateStore#countDocuments does not always return the same number as would be the size of #searchDocuments for the same query
• [XWIKI-4590] - View Statistics increment too fast because of AJAX features in bottom page tags and ratings
• [XWIKI-4925] - When XWiki is initialized via a XMLRPC request, it is in a wrong state and redirect-to-login URLs will be wrong
• [XWIKI-4931] - Links are badly saved on IE7
• [XWIKI-4954] - XWikiDocument#clone should use set/getParent instead of set/getParentReference
• [XWIKI-4965] - Objects can no longer be retrieved relative to their document
Here's my +1
Thanks
-Vincent
JV, there's a real bug out there, why have you removed it (We need it in jira somewhere so that people who have it can find it and so that we can put it as fixed in the release notes) ?
Allowing to set the host/port (or whatever else) will not remove the bug by itself.
Thanks
-Vincent
On Mar 2, 2010, at 11:50 AM, Jean-Vincent Drean (JIRA) wrote:
>
> [ http://jira.xwiki.org/jira/browse/XAADMINISTRATION-117?page=com.atlassian.j… ]
>
> Jean-Vincent Drean moved XASCH-50 to XAADMINISTRATION-117:
> ----------------------------------------------------------
>
> Project: XWiki Administration Application (was: XWiki Scheduler Application)
> Key: XAADMINISTRATION-117 (was: XASCH-50)
> Issue Type: Improvement (was: Bug)
> Affects Version/s: 1.27
> (was: 1.16)
> Component/s: Infrastructure
> (was: Plugin)
>
>> URL generated from scheduler jobs can be wrong
>> ----------------------------------------------
>>
>> Key: XAADMINISTRATION-117
>> URL: http://jira.xwiki.org/jira/browse/XAADMINISTRATION-117
>> Project: XWiki Administration Application
>> Issue Type: Improvement
>> Components: Infrastructure
>> Affects Versions: 1.27
>> Reporter: Jean-Vincent Drean
>>
>> Scheduler jobs are passed a stub request. This stub request contains the host used on the first request, URLs generated afterwards will always use this host.
>
> --
> This message is automatically generated by JIRA.
> -
> If you think it was sent incorrectly contact one of the administrators: http://jira.xwiki.org/jira/secure/Administrators.jspa
> -
> For more information on JIRA, see: http://www.atlassian.com/software/jira
Hi guys,
I'm an experienced software engineer but scripting XWiki still seems to
be about as clear as mud to me.
I know I could create a Form.
I know this could result in a new Page being generated.
However, I have no idea how to make this happen.
Is an event raised when I submit the form? If so, how do I attach a
handler to that event? What do I then need to do to squeeze the
user-provided data into a page generated from a template? Or into some
data store from which a templated page would be generated?
I would be incredibly grateful if someone could throw together a very
quick walk-through of doing the following from a web browser:
Creating a new form with a singular field, e.g. Name
Writing the code which takes the contents of this form and creates a new
page with title "Name's Greeting" and content "Hello, Name!"
This does raise further questions. For example: Can a user go back later
and edit the data in the form? Or would the resulting page need to be
edited instead?