On Fri, Dec 2, 2011 at 11:52 AM, jerem <jeremie.bousquet(a)gmail.com> wrote:
Of course Vincent, I completely agree with you ...
It's more a joke hiding
some kind of lazyness from my side, having to rewrite parts as components
(and having to gain information about how to do that most of all ...)
* How do you autocomplete in wiki pages
I'm so used not having this feature when working in wiki pages that I don't
even bother...
* How do you have quick access to all your code scattered in several pages
all visible from within your IDE
My IDE is XWiki ... :/ Never found an easy way to manage wiki pages in link
with IDE / SCM tools.
* How do you write unit tests
* How do you document and generate javadoc
Of course there is none of that for now ... :(
* How do you handle registration/unregistration of components
Well, that's a question for me : for now I used the application manager to
generate a Xar and set a version to it. I don't know if this kind of thing
is/will be managed by extension manager ?
Of course for now it's not a component at all.
On another side working directly inside XWiki pages has some great advantage
: you can test directly (no deployment or compilation phases).
In fact it's too late to create the component before putting too much code
in wiki pages, because almost all the app is already coded (in wiki pages
...) :) And what is left to code is mainly display ...
But business logic is mainly located in one groovy class in one page (the
mail loading, is the heart of the application).
What's left in other pages are some utility methods (that need some
refactoring), the ldap bridge, and the threading algorithm maybe.
So I agree with you that it should not be a very big deal to refactor and
transform this groovy class into an xwiki java component, and it has
added-value. I'll add that in the pre-requisites for the first version.
Indeed, I will ask you to be a little patient :)
Side-question : is it possible / advisable to write this xwiki java
component in groovy ? At the end it can be compiled into java bytecode, and
as most groovy dependencies are already part of the xwiki distrib, it should
work, what do you think ?
Yes but there is an important drawback: there is no way for your
groovy component to be registered automatically at startup, you need
to external action to explicitly register it (either by hand or some
cron which regularly check if your component is still registered). It
could sound minor like that but it's a real pain to always have to
remember to register you groovy component when you restard or worst
when XWiki automatically restart because it was stuck.
A good example of Goovy component with regsitration page is the IRC
bot. See
https://github.com/xwiki/xwiki-platform/tree/master/xwiki-platform-core/xwi….
This should be fixed by wiki component (see
http://dev.xwiki.org/xwiki/bin/view/Design/WikiComponents) but the way
XWiki database initialization is done make it difficult to cleanly
find and intialize the wiki component at startup, need a bit of
refactoring. An example of specialized wiki components is wiki macro
but the way theses are initialized is very crappy and we are trying to
avoid doing the same thing for components in general.
Or do you recommend to write it in Java ?
Jeremie
--
View this message in context:
http://xwiki.475771.n2.nabble.com/Your-feedbacks-on-a-possible-MailArchive-…
Sent from the XWiki- Users mailing list archive at
Nabble.com.
_______________________________________________
users mailing list
users(a)xwiki.org
http://lists.xwiki.org/mailman/listinfo/users
--
Thomas Mortagne