You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jspwiki.apache.org by "akakunin (JIRA)" <ji...@apache.org> on 2008/04/22 15:48:23 UTC
[jira] Created: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Rename page with attachment kills Main-Page
-------------------------------------------
Key: JSPWIKI-252
URL: https://issues.apache.org/jira/browse/JSPWIKI-252
Project: JSPWiki
Issue Type: Bug
Components: Core & storage
Affects Versions: 2.6.2
Environment: Java 1.6, JspWiki 2.6.2
Reporter: akakunin
Priority: Blocker
We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
1. Create any Page (for example TestPage1)
2. Add attachment to this page (for example somefile.jpg)
3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
4. So - now everything is ok - you have page with attachment and this page has link to the attachment
5. Open page Info dialog and rename page (for example to TestPage2)
6. Everything is ok - page is renamed
7. Open Main-Page
8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Reopened: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "Janne Jalkanen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Janne Jalkanen reopened JSPWIKI-252:
------------------------------------
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Priority: Blocker
> Attachments: JSPWIKI-252.patch
>
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "akakunin (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12591651#action_12591651 ]
akakunin commented on JSPWIKI-252:
----------------------------------
Just checked - in our case proposed solution fixed the problem.
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Priority: Blocker
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "Harry Metske (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12597739#action_12597739 ]
Harry Metske commented on JSPWIKI-252:
--------------------------------------
I'm a bit busy coming few days, I'll have a look at it next week.
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Fix For: 2.6.3
>
> Attachments: JSPWIKI-252.patch
>
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "Harry Metske (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12597806#action_12597806 ]
Harry Metske commented on JSPWIKI-252:
--------------------------------------
The "good" news is that PageRenamerTest is also failing without patch 231, so the patch is not introducing additional errors.
I cloned the old com.ecyrd.jspwiki.PageRenamerTest to com.ecyrd.jspwiki.content.PageRenamerTest, and this one also fails.
My proposal is to forget about the old PageRenamerTest and concentrate on the new one.
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Fix For: 2.6.3
>
> Attachments: JSPWIKI-252.patch
>
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "Janne Jalkanen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12597722#action_12597722 ]
Janne Jalkanen commented on JSPWIKI-252:
----------------------------------------
BTW, I suspect there is something fishy about the patch, since it breaks our unit tests.
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Fix For: 2.6.3
>
> Attachments: JSPWIKI-252.patch
>
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "akakunin (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12591301#action_12591301 ]
akakunin commented on JSPWIKI-252:
----------------------------------
I think correct fix for this bug is change lines (in PageRenamer.updateReferrerOrRename method)
WikiContext tempCtx = new WikiContext( m_wikiEngine, m_wikiEngine.getPage(referrerName) );
if (context.getPage() != null)
{
to lines
if (m_wikiEngine.getPage(referrerName) != null)
{
WikiContext tempCtx = new WikiContext( m_wikiEngine, m_wikiEngine.getPage(referrerName) );
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Priority: Blocker
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "Janne Jalkanen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Janne Jalkanen resolved JSPWIKI-252.
------------------------------------
Resolution: Fixed
Fixed in 2.6.3-rc-1
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Fix For: 2.6.3
>
> Attachments: JSPWIKI-252.patch
>
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (JSPWIKI-252) Rename page with attachment kills
Main-Page
Posted by "Janne Jalkanen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/JSPWIKI-252?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Janne Jalkanen resolved JSPWIKI-252.
------------------------------------
Resolution: Won't Fix
PageRenamer is completely gone (due to IPR issues) in the trunk now, so this issue ceases to be valid. A replacement contribution is needed.
Please see JSPWIKI-265.
> Rename page with attachment kills Main-Page
> -------------------------------------------
>
> Key: JSPWIKI-252
> URL: https://issues.apache.org/jira/browse/JSPWIKI-252
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.6.2
> Environment: Java 1.6, JspWiki 2.6.2
> Reporter: akakunin
> Priority: Blocker
> Attachments: JSPWIKI-252.patch
>
>
> We met this bug in our www.emforge.org (it is used WikiEngine with own JSF GUI) - but I just reproduced this problem in sandbox:
> 1. Create any Page (for example TestPage1)
> 2. Add attachment to this page (for example somefile.jpg)
> 3. Add text on this page referenced to this attachment: ( for example just [somefile.jpg])
> 4. So - now everything is ok - you have page with attachment and this page has link to the attachment
> 5. Open page Info dialog and rename page (for example to TestPage2)
> 6. Everything is ok - page is renamed
> 7. Open Main-Page
> 8 - Uuups - Main page is Empty! (Right now you can check it in sandbox - I crealed main page by this way)
> I debug it a little bit - problem is in PageRenamer.updateReffererOrRename method. During rename it is called with oldName=TestPage1 and newName TestPage2
> At line 238 it is created tempCtx for old page (TestPage1). Since (seems) this page is not already exists - m_wikiEngine.getPage() returned null.
> But WikiContext constructor for null page created context for Main page - and later - it is cleared Main page.
> In EmForge this problem is reproduced then we trying to report bug (via New Bug Wizard) and has attachment (for example picture) and reference to attachment in bug-description (quite common problem). So, since it is caused quite often - it is produced big problem for us - so, it is why I marked this bug as blocker.
> In any case - I do not think it is good that it is possible to clear Main page then you do not do it :)
> Please - feel free to contact me if you will need any additional info.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.