[xwiki-users] Phantom documents
Hello, I've recently noticed that one of the documents on XWiki is in the orphaned list while clicking on it redirects me to the document that obviously has parent (path in the above section is present). Going to the database I found out on einteresting thing mysql> select xwd_id, xwd_name, xwd_fullname, xwd_parent, xwd_version, xwd_translation from xwikidoc where xwd_name like 'InitialRequirements'; +------------+---------------------+----------------------------------+--------------------------------+-------------+-----------------+ | xwd_id | xwd_name | xwd_fullname | xwd_parent | xwd_version | xwd_translation | +------------+---------------------+----------------------------------+--------------------------------+-------------+-----------------+ | 43295369 | InitialRequirements | MyHappySpace.InitialRequirements | | 5.1 | 1 | | -536599142 | InitialRequirements | MyHappySpace.InitialRequirements | xwiki:MyHappySpace.UserStories | 25.2 | 1 | +------------+---------------------+----------------------------------+--------------------------------+-------------+-----------------+ 2 rows in set (0.00 sec) As I understand it's not quite normal to have document wit negative ID. I remember such issue happening before, the solution to it was to back-up the document content, delete the document. This would make "the document behind" (or phantom document) visible, delete the phantom document, and then create the document once more, restoring it from the backup. If you'd ask me for circumstances under which it occurred, I recollect only in general - we were simultaneously working on the document trying to create it and import its content from MSWord file. Is this a known issue? Any circumstances under which it might occur? I've experienced it at least on version 2.4 and 2.6. Regards, Roman -- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6221973.html Sent from the XWiki- Users mailing list archive at Nabble.com.
On 03/30/2011 02:21 AM, coldserenity wrote:
Hello,
I've recently noticed that one of the documents on XWiki is in the orphaned list while clicking on it redirects me to the document that obviously has parent (path in the above section is present). Going to the database I found out on einteresting thing
mysql> select xwd_id, xwd_name, xwd_fullname, xwd_parent, xwd_version, xwd_translation from xwikidoc where xwd_name like 'InitialRequirements'; +------------+---------------------+----------------------------------+--------------------------------+-------------+-----------------+ | xwd_id | xwd_name | xwd_fullname | xwd_parent | xwd_version | xwd_translation | +------------+---------------------+----------------------------------+--------------------------------+-------------+-----------------+ | 43295369 | InitialRequirements | MyHappySpace.InitialRequirements | | 5.1 | 1 | | -536599142 | InitialRequirements | MyHappySpace.InitialRequirements | xwiki:MyHappySpace.UserStories | 25.2 | 1 | +------------+---------------------+----------------------------------+--------------------------------+-------------+-----------------+ 2 rows in set (0.00 sec)
As I understand it's not quite normal to have document wit negative ID. I remember such issue happening before, the solution to it was to back-up the document content, delete the document. This would make "the document behind" (or phantom document) visible, delete the phantom document, and then create the document once more, restoring it from the backup. If you'd ask me for circumstances under which it occurred, I recollect only in general - we were simultaneously working on the document trying to create it and import its content from MSWord file.
Is this a known issue? Any circumstances under which it might occur? I've experienced it at least on version 2.4 and 2.6.
Try checking the language if those two documents. (XWD_LANGUAGE in sql) Since 2 translations of the same document are the actually 2 distinct documents, it is possible for them to have different parents. If MyHappySpace.InitialRequirements was an orphan, then it was translated the translation would too be an orphan. Then if the original document was corrected the correction would not carry over to the translation. As for the negative IDs, that is normal. They are not sequential but rather generated by a hashcode of the document name and language in what is one of the more embarrassing functions in the code base. Caleb
Regards, Roman
-- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6221973.html Sent from the XWiki- Users mailing list archive at Nabble.com. _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
Thanks for the hint, Caleb Indeed they have different xwd_language values mysql> select xwd_id, xwd_language from xwikidoc where xwd_name like 'InitialRequirements'; +------------+--------------+ | xwd_id | xwd_language | +------------+--------------+ | 43295369 | en | | -536599142 | | +------------+--------------+ 2 rows in set (0.00 sec) one is "en" and one is empty. Multilingual option is turned off, I guess that's why XWiki cannot recognize these documents as a bundle and allow editing each document separately. -- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6222240.html Sent from the XWiki- Users mailing list archive at Nabble.com.
One addition to that - I have checked and only 2 documents in our database have 'en' language. The rest of them have empty language value. I have checked the second document with 'en' set - and it too has a phantom. -- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6222268.html Sent from the XWiki- Users mailing list archive at Nabble.com.
That is indeed a bug. There should never be multilingual documents with multilingual turned off. Would you mind reporting that on jira.xwiki.org? Thanks Caleb On 03/30/2011 04:10 AM, coldserenity wrote:
One addition to that - I have checked and only 2 documents in our database have 'en' language. The rest of them have empty language value.
I have checked the second document with 'en' set - and it too has a phantom.
-- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6222268.html Sent from the XWiki- Users mailing list archive at Nabble.com. _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
On 03/30/2011 10:00 AM, coldserenity wrote:
Thanks for the hint, Caleb Indeed they have different xwd_language values
mysql> select xwd_id, xwd_language from xwikidoc where xwd_name like 'InitialRequirements';
Try this also: select xwd_id, xwd_language, xwd_default_language from xwikidoc where xwd_name like 'InitialRequirements'; Is the default language en as well?
+------------+--------------+ | xwd_id | xwd_language | +------------+--------------+ | 43295369 | en | | -536599142 | | +------------+--------------+ 2 rows in set (0.00 sec)
one is "en" and one is empty. Multilingual option is turned off, I guess that's why XWiki cannot recognize these documents as a bundle and allow editing each document separately.
-- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6222240.html Sent from the XWiki- Users mailing list archive at Nabble.com. _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
-- Sergiu Dumitriu http://purl.org/net/sergiu/
Sergiu, The results are the following mysql> select xwd_id, xwd_language, xwd_default_language from xwikidoc where xwd_name like 'InitialRequirements'; +------------+--------------+----------------------+ | xwd_id | xwd_language | xwd_default_language | +------------+--------------+----------------------+ | 43295369 | en | | | -536599142 | | en | +------------+--------------+----------------------+ 2 rows in set (0.00 sec) -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Sergiu Dumitriu Sent: Wednesday, March 30, 2011 2:54 PM To: XWiki Users Subject: Re: [xwiki-users] Phantom documents On 03/30/2011 10:00 AM, coldserenity wrote:
Thanks for the hint, Caleb Indeed they have different xwd_language values
mysql> select xwd_id, xwd_language from xwikidoc where xwd_name like 'InitialRequirements';
Try this also: select xwd_id, xwd_language, xwd_default_language from xwikidoc where xwd_name like 'InitialRequirements'; Is the default language en as well?
+------------+--------------+ | xwd_id | xwd_language | +------------+--------------+ | 43295369 | en | | -536599142 | | +------------+--------------+ 2 rows in set (0.00 sec)
one is "en" and one is empty. Multilingual option is turned off, I guess that's why XWiki cannot recognize these documents as a bundle and allow editing each document separately.
-- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6222240.html Sent from the XWiki- Users mailing list archive at Nabble.com. _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
-- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
Done http://jira.xwiki.org/jira/browse/XWIKI-6205 -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Caleb James DeLisle Sent: Wednesday, March 30, 2011 12:44 PM To: XWiki Users Subject: Re: [xwiki-users] Phantom documents That is indeed a bug. There should never be multilingual documents with multilingual turned off. Would you mind reporting that on jira.xwiki.org? Thanks Caleb On 03/30/2011 04:10 AM, coldserenity wrote:
One addition to that - I have checked and only 2 documents in our database have 'en' language. The rest of them have empty language value.
I have checked the second document with 'en' set - and it too has a phantom.
-- View this message in context: http://xwiki.475771.n2.nabble.com/Phantom-documents-tp6221973p6222268.html Sent from the XWiki- Users mailing list archive at Nabble.com. _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
_______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users
participants (4)
-
Caleb James DeLisle -
coldserenity -
Roman Muntyanu -
Sergiu Dumitriu