Re: [xwiki-users] IllegalArgumentException

2014-06-03 Thread Clemens Klein-Robbenhaar
On 06/03/2014 05:16 AM, Daniel Ebanja wrote:
 Hi,
 i am receiveing the following exception:
 Caused by: java.lang.IllegalArgumentException: URLDecoder: Illegal hex
 characters in escape (%) pattern - For input string: !
 

Hm, are you sure it is already decoded?
I can reproduce the error message you get by decoding it twice ...

 My scenario:
 Users can create space by using a URL that looks like:
 mydomain.com/xwiki/bin/...?space=
 %C3%A4%C3%B6%C3%BC%C3%9F%C2%A7%25%21%3C%3E_helloworld
 
 i then try to decode this spacename and create the space without success.
 String decodedspacename = URLDecoder.decode(space, UTF-8);
 
 How should i deal with this?
 thanks for your help in advance.
 ___
 users mailing list
 users@xwiki.org
 http://lists.xwiki.org/mailman/listinfo/users
 

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] IllegalArgumentException

2014-06-03 Thread Daniel Ebanja
Hi,
I am trying to decode only once and I'm getting the exception already.
String decodedspacename = URLDecoder.decode(space, UTF-8).getpath();
Am 03.06.2014 09:50 schrieb Clemens Klein-Robbenhaar 
c.robbenh...@espresto.com:

 On 06/03/2014 05:16 AM, Daniel Ebanja wrote:
  Hi,
  i am receiveing the following exception:
  Caused by: java.lang.IllegalArgumentException: URLDecoder: Illegal hex
  characters in escape (%) pattern - For input string: !
 

 Hm, are you sure it is already decoded?
 I can reproduce the error message you get by decoding it twice ...

  My scenario:
  Users can create space by using a URL that looks like:
  mydomain.com/xwiki/bin/...?space=
  %C3%A4%C3%B6%C3%BC%C3%9F%C2%A7%25%21%3C%3E_helloworld
 
  i then try to decode this spacename and create the space without success.
  String decodedspacename = URLDecoder.decode(space, UTF-8);
 
  How should i deal with this?
  thanks for your help in advance.
  ___
  users mailing list
  users@xwiki.org
  http://lists.xwiki.org/mailman/listinfo/users
 

 ___
 users mailing list
 users@xwiki.org
 http://lists.xwiki.org/mailman/listinfo/users

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] groovy and PermGen space exception

2014-06-03 Thread lequan.moon
Hello,
I'm having a problem with xwiki + groovy which throw PermGen exception a
lot.
I built a page(page A) which send ajax continuously to another page(page B)
At page B, it use groovy to process the request.
The problem as I checked is : It seem like each request, the engine compile
and load groovy script = many Script classes, objects are created that
stress out the memory.
I use jconsole to check and see something like this as Loaded classes:
[Loaded Script2523$_getData_closure6 from file:/groovy/script]
[Loaded Script2524$_getData_closure6 from file:/groovy/script]
[Loaded Script2525$_getData_closure6 from file:/groovy/script]
[Loaded Script2526$_getData_closure6 from file:/groovy/script]
I look like Xwiki engine use something like GroovyShell to evaluate the
groovy script each time it's loaded so it create a lot of Script classes
(something like that, i'm not sure)

How can I fix this? or anyway to work around?

Note that I have already set environment variables
-Xmx512m -XX:MaxPermSize=512m -XX+CMSClassUnloadingEnabled



--
View this message in context: 
http://xwiki.475771.n2.nabble.com/groovy-and-PermGen-space-exception-tp7590836.html
Sent from the XWiki- Users mailing list archive at Nabble.com.
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] improve SpaceIndex

2014-06-03 Thread Pascal BASTIEN
Hello,

Here, I add sort parameter to SpaceIndex function to display the list of 
document with another ... sort:

http://extensions.xwiki.org/xwiki/bin/view/Extension/SpaceIndex+Macro#Comments

Have fun :-)

It will be nice to add that at xwiki engine...


Pascal B
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] improve SpaceIndex

2014-06-03 Thread vinc...@massol.net
Thanks Pascal

Would be great if you could create 1) a JIRA issue and 2) a Pull Request on 
https://github.com/xwiki/xwiki-platform for this!

That would increase the likelihood of getting this in the platform :)

Thanks
-Vincent

On 3 Jun 2014 at 14:07:41, Pascal BASTIEN 
(pbasnews-xw...@yahoo.fr(mailto:pbasnews-xw...@yahoo.fr)) wrote:

 Hello,
  
 Here, I add sort parameter to SpaceIndex function to display the list of 
 document with another ... sort:
  
 http://extensions.xwiki.org/xwiki/bin/view/Extension/SpaceIndex+Macro#Comments
  
 Have fun :-)
  
 It will be nice to add that at xwiki engine...
  
  
 Pascal B

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] improve SpaceIndex

2014-06-03 Thread Pascal BASTIEN

Ok, then:
1- http://jira.xwiki.org/browse/XCOMMONS-602
and 2 - https://github.com/xwiki/xwiki-platform/pull/280
Am I good? :-)
Tell me if it is correct ... or no.

Thxs




 De : vinc...@massol.net vinc...@massol.net
À : XWiki Users users@xwiki.org 
Cc : Pascal BASTIEN pbasnews-xw...@yahoo.fr 
Envoyé le : Mardi 3 juin 2014 15h41
Objet : Re: [xwiki-users] improve SpaceIndex
 


Thanks Pascal

Would be great if you could create 1) a JIRA issue and 2) a Pull Request on 
https://github.com/xwiki/xwiki-platform for this!

That would increase the likelihood of getting this in the platform :)

Thanks
-Vincent

On 3 Jun 2014 at 14:07:41, Pascal BASTIEN 
(pbasnews-xw...@yahoo.fr(mailto:pbasnews-xw...@yahoo.fr)) wrote:

 Hello,
 
 Here, I add sort parameter to SpaceIndex function to display the list of 
 document with another ... sort:
 
 http://extensions.xwiki.org/xwiki/bin/view/Extension/SpaceIndex+Macro#Comments
 
 Have fun :-)
 
 It will be nice to add that at xwiki engine...
 
 
 Pascal B
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] groovy and PermGen space exception

2014-06-03 Thread Thomas Mortagne
How do you use groovy script exactly ? {{groovy}} macro is using the
standard JSR 223 implementation provided by Groovy, we don't have much
control on what is happening.

On Tue, Jun 3, 2014 at 1:31 PM, lequan.moon lequan.m...@gmail.com wrote:
 Hello,
 I'm having a problem with xwiki + groovy which throw PermGen exception a
 lot.
 I built a page(page A) which send ajax continuously to another page(page B)
 At page B, it use groovy to process the request.
 The problem as I checked is : It seem like each request, the engine compile
 and load groovy script = many Script classes, objects are created that
 stress out the memory.
 I use jconsole to check and see something like this as Loaded classes:
 [Loaded Script2523$_getData_closure6 from file:/groovy/script]
 [Loaded Script2524$_getData_closure6 from file:/groovy/script]
 [Loaded Script2525$_getData_closure6 from file:/groovy/script]
 [Loaded Script2526$_getData_closure6 from file:/groovy/script]
 I look like Xwiki engine use something like GroovyShell to evaluate the
 groovy script each time it's loaded so it create a lot of Script classes
 (something like that, i'm not sure)

 How can I fix this? or anyway to work around?

 Note that I have already set environment variables
 -Xmx512m -XX:MaxPermSize=512m -XX+CMSClassUnloadingEnabled



 --
 View this message in context: 
 http://xwiki.475771.n2.nabble.com/groovy-and-PermGen-space-exception-tp7590836.html
 Sent from the XWiki- Users mailing list archive at Nabble.com.
 ___
 users mailing list
 users@xwiki.org
 http://lists.xwiki.org/mailman/listinfo/users



-- 
Thomas Mortagne
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] groovy and PermGen space exception

2014-06-03 Thread lequan.moon
Yes, i use the tag {{groovy}} for groovy script.
Is there anyway else??



--
View this message in context: 
http://xwiki.475771.n2.nabble.com/groovy-and-PermGen-space-exception-tp7590836p7590849.html
Sent from the XWiki- Users mailing list archive at Nabble.com.
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users