Re: Wicket as rest backend....

2012-09-26 Thread Ondrej Zizka
Hi,

I am not really sure why would one serve REST through Wicket, is there
any advantage? Maybe to adjust it according to the state of
page/session?

But if it's a service without no such req, I am using RestEasy, which
works like a charm.
https://www.jboss.org/resteasy/

All I need to make it working is:

!-- One of the way of activating REST Servises. --
servlet-mapping
servlet-namejavax.ws.rs.core.Application/servlet-name
url-pattern/rest/*/url-pattern
/servlet-mapping

The rest are POJOs with @Path(/...) etc and I mostly reuse my JPA
entities as DTOs.


Ondra




On Thu, 2012-09-20 at 20:54 +0300, Josh Kamau wrote:

 Hi Guys;
 
 Is there a way(a sub project may be..) of exposing a wicket web app as a
 REST API ?
 
 
 Josh.




Re: Wicket as rest backend....

2012-09-21 Thread Bruno Borges
Jersey is really good, but you also should consider using the spec JAX-RS.
Why not?


*Bruno Borges*
(11) 99564-9058
*www.brunoborges.com*



On Thu, Sep 20, 2012 at 5:00 PM, Dan Alvizu dalv...@pingidentity.comwrote:

 I've used wicket-rest before - it got the job done, but I couldn't use it
 for wicket 1.5.

 Since then I've moved my rest services to Jersey - I highly recommend using
 that if you can:

 http://jersey.java.net/

 -Dan

 On Thu, Sep 20, 2012 at 1:21 PM, Josh Kamau joshnet2...@gmail.com wrote:

  Good idea...
 
  I would like to use JSON though...
 
  Josh.
 
  On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
  reier...@gmail.com wrote:
 
   I have implemented rest like services by mounting pages and using
 them
  to
   generate XML content instead of HTML.
  
   On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com
  wrote:
  
Hi Guys;
   
Is there a way(a sub project may be..) of exposing a wicket web app
 as
  a
REST API ?
   
   
Josh.
   
  
  
  
   --
   Regards - Ernesto Reinaldo Barreiro
   Antilia Soft
   http://antiliasoft.com
  
 



Re: Wicket as rest backend....

2012-09-21 Thread Martin Grigorov
On Fri, Sep 21, 2012 at 8:58 PM, Bruno Borges bruno.bor...@gmail.com wrote:
 Jersey is really good, but you also should consider using the spec JAX-RS.
 Why not?

Because specs are boring and the compatibility between different impls
is not as they claim it to be.



 *Bruno Borges*
 (11) 99564-9058
 *www.brunoborges.com*



 On Thu, Sep 20, 2012 at 5:00 PM, Dan Alvizu dalv...@pingidentity.comwrote:

 I've used wicket-rest before - it got the job done, but I couldn't use it
 for wicket 1.5.

 Since then I've moved my rest services to Jersey - I highly recommend using
 that if you can:

 http://jersey.java.net/

 -Dan

 On Thu, Sep 20, 2012 at 1:21 PM, Josh Kamau joshnet2...@gmail.com wrote:

  Good idea...
 
  I would like to use JSON though...
 
  Josh.
 
  On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
  reier...@gmail.com wrote:
 
   I have implemented rest like services by mounting pages and using
 them
  to
   generate XML content instead of HTML.
  
   On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com
  wrote:
  
Hi Guys;
   
Is there a way(a sub project may be..) of exposing a wicket web app
 as
  a
REST API ?
   
   
Josh.
   
  
  
  
   --
   Regards - Ernesto Reinaldo Barreiro
   Antilia Soft
   http://antiliasoft.com
  
 




-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket as rest backend....

2012-09-21 Thread Bruno Borges
True, but we don't move between impls that often, do we? :-)


*Bruno Borges*
(11) 99564-9058
*www.brunoborges.com*



On Fri, Sep 21, 2012 at 4:11 PM, Martin Grigorov mgrigo...@apache.orgwrote:

 On Fri, Sep 21, 2012 at 8:58 PM, Bruno Borges bruno.bor...@gmail.com
 wrote:
  Jersey is really good, but you also should consider using the spec
 JAX-RS.
  Why not?

 Because specs are boring and the compatibility between different impls
 is not as they claim it to be.

 
 
  *Bruno Borges*
  (11) 99564-9058
  *www.brunoborges.com*
 
 
 
  On Thu, Sep 20, 2012 at 5:00 PM, Dan Alvizu dalv...@pingidentity.com
 wrote:
 
  I've used wicket-rest before - it got the job done, but I couldn't use
 it
  for wicket 1.5.
 
  Since then I've moved my rest services to Jersey - I highly recommend
 using
  that if you can:
 
  http://jersey.java.net/
 
  -Dan
 
  On Thu, Sep 20, 2012 at 1:21 PM, Josh Kamau joshnet2...@gmail.com
 wrote:
 
   Good idea...
  
   I would like to use JSON though...
  
   Josh.
  
   On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
   reier...@gmail.com wrote:
  
I have implemented rest like services by mounting pages and using
  them
   to
generate XML content instead of HTML.
   
On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com
   wrote:
   
 Hi Guys;

 Is there a way(a sub project may be..) of exposing a wicket web
 app
  as
   a
 REST API ?


 Josh.

   
   
   
--
Regards - Ernesto Reinaldo Barreiro
Antilia Soft
http://antiliasoft.com
   
  
 



 --
 Martin Grigorov
 jWeekend
 Training, Consulting, Development
 http://jWeekend.com

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: Wicket as rest backend....

2012-09-21 Thread Martin Grigorov
On Fri, Sep 21, 2012 at 11:42 PM, Bruno Borges bruno.bor...@gmail.com wrote:
 True, but we don't move between impls that often, do we? :-)

Exactly!
But then why to follow restrictions and not use the full power of the
specific implementation ?



 *Bruno Borges*
 (11) 99564-9058
 *www.brunoborges.com*



 On Fri, Sep 21, 2012 at 4:11 PM, Martin Grigorov mgrigo...@apache.orgwrote:

 On Fri, Sep 21, 2012 at 8:58 PM, Bruno Borges bruno.bor...@gmail.com
 wrote:
  Jersey is really good, but you also should consider using the spec
 JAX-RS.
  Why not?

 Because specs are boring and the compatibility between different impls
 is not as they claim it to be.

 
 
  *Bruno Borges*
  (11) 99564-9058
  *www.brunoborges.com*
 
 
 
  On Thu, Sep 20, 2012 at 5:00 PM, Dan Alvizu dalv...@pingidentity.com
 wrote:
 
  I've used wicket-rest before - it got the job done, but I couldn't use
 it
  for wicket 1.5.
 
  Since then I've moved my rest services to Jersey - I highly recommend
 using
  that if you can:
 
  http://jersey.java.net/
 
  -Dan
 
  On Thu, Sep 20, 2012 at 1:21 PM, Josh Kamau joshnet2...@gmail.com
 wrote:
 
   Good idea...
  
   I would like to use JSON though...
  
   Josh.
  
   On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
   reier...@gmail.com wrote:
  
I have implemented rest like services by mounting pages and using
  them
   to
generate XML content instead of HTML.
   
On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com
   wrote:
   
 Hi Guys;

 Is there a way(a sub project may be..) of exposing a wicket web
 app
  as
   a
 REST API ?


 Josh.

   
   
   
--
Regards - Ernesto Reinaldo Barreiro
Antilia Soft
http://antiliasoft.com
   
  
 



 --
 Martin Grigorov
 jWeekend
 Training, Consulting, Development
 http://jWeekend.com

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org





-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket as rest backend....

2012-09-21 Thread Bruno Borges
I'm just saying that he can opt to use jax-rs... not that he must because
X or Y...

I like jax-rs, it is a good spec, that's why I'm suggesting. :P

Do you think it is not a good spec?


*Bruno Borges*
(11) 99564-9058
*www.brunoborges.com*



On Fri, Sep 21, 2012 at 5:44 PM, Martin Grigorov mgrigo...@apache.orgwrote:

 On Fri, Sep 21, 2012 at 11:42 PM, Bruno Borges bruno.bor...@gmail.com
 wrote:
  True, but we don't move between impls that often, do we? :-)

 Exactly!
 But then why to follow restrictions and not use the full power of the
 specific implementation ?

 
 
  *Bruno Borges*
  (11) 99564-9058
  *www.brunoborges.com*
 
 
 
  On Fri, Sep 21, 2012 at 4:11 PM, Martin Grigorov mgrigo...@apache.org
 wrote:
 
  On Fri, Sep 21, 2012 at 8:58 PM, Bruno Borges bruno.bor...@gmail.com
  wrote:
   Jersey is really good, but you also should consider using the spec
  JAX-RS.
   Why not?
 
  Because specs are boring and the compatibility between different impls
  is not as they claim it to be.
 
  
  
   *Bruno Borges*
   (11) 99564-9058
   *www.brunoborges.com*
  
  
  
   On Thu, Sep 20, 2012 at 5:00 PM, Dan Alvizu dalv...@pingidentity.com
  wrote:
  
   I've used wicket-rest before - it got the job done, but I couldn't
 use
  it
   for wicket 1.5.
  
   Since then I've moved my rest services to Jersey - I highly recommend
  using
   that if you can:
  
   http://jersey.java.net/
  
   -Dan
  
   On Thu, Sep 20, 2012 at 1:21 PM, Josh Kamau joshnet2...@gmail.com
  wrote:
  
Good idea...
   
I would like to use JSON though...
   
Josh.
   
On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
reier...@gmail.com wrote:
   
 I have implemented rest like services by mounting pages and
 using
   them
to
 generate XML content instead of HTML.

 On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau 
 joshnet2...@gmail.com
wrote:

  Hi Guys;
 
  Is there a way(a sub project may be..) of exposing a wicket web
  app
   as
a
  REST API ?
 
 
  Josh.
 



 --
 Regards - Ernesto Reinaldo Barreiro
 Antilia Soft
 http://antiliasoft.com

   
  
 
 
 
  --
  Martin Grigorov
  jWeekend
  Training, Consulting, Development
  http://jWeekend.com
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 



 --
 Martin Grigorov
 jWeekend
 Training, Consulting, Development
 http://jWeekend.com

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: Wicket as rest backend....

2012-09-21 Thread Martin Grigorov
I'm saying that JAX-RS is currently at version 1.
Version 2 is in development and will be available ... when it is ready.
By using internal APIs of Jersey/RestEasy/... you use something like
JAX-RS ver. 1.[1-9] *now*. And  ver. 1.[1-9] considered better than
version 1.

On Sat, Sep 22, 2012 at 12:06 AM, Bruno Borges bruno.bor...@gmail.com wrote:
 I'm just saying that he can opt to use jax-rs... not that he must because
 X or Y...

 I like jax-rs, it is a good spec, that's why I'm suggesting. :P

 Do you think it is not a good spec?


 *Bruno Borges*
 (11) 99564-9058
 *www.brunoborges.com*



 On Fri, Sep 21, 2012 at 5:44 PM, Martin Grigorov mgrigo...@apache.orgwrote:

 On Fri, Sep 21, 2012 at 11:42 PM, Bruno Borges bruno.bor...@gmail.com
 wrote:
  True, but we don't move between impls that often, do we? :-)

 Exactly!
 But then why to follow restrictions and not use the full power of the
 specific implementation ?

 
 
  *Bruno Borges*
  (11) 99564-9058
  *www.brunoborges.com*
 
 
 
  On Fri, Sep 21, 2012 at 4:11 PM, Martin Grigorov mgrigo...@apache.org
 wrote:
 
  On Fri, Sep 21, 2012 at 8:58 PM, Bruno Borges bruno.bor...@gmail.com
  wrote:
   Jersey is really good, but you also should consider using the spec
  JAX-RS.
   Why not?
 
  Because specs are boring and the compatibility between different impls
  is not as they claim it to be.
 
  
  
   *Bruno Borges*
   (11) 99564-9058
   *www.brunoborges.com*
  
  
  
   On Thu, Sep 20, 2012 at 5:00 PM, Dan Alvizu dalv...@pingidentity.com
  wrote:
  
   I've used wicket-rest before - it got the job done, but I couldn't
 use
  it
   for wicket 1.5.
  
   Since then I've moved my rest services to Jersey - I highly recommend
  using
   that if you can:
  
   http://jersey.java.net/
  
   -Dan
  
   On Thu, Sep 20, 2012 at 1:21 PM, Josh Kamau joshnet2...@gmail.com
  wrote:
  
Good idea...
   
I would like to use JSON though...
   
Josh.
   
On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
reier...@gmail.com wrote:
   
 I have implemented rest like services by mounting pages and
 using
   them
to
 generate XML content instead of HTML.

 On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau 
 joshnet2...@gmail.com
wrote:

  Hi Guys;
 
  Is there a way(a sub project may be..) of exposing a wicket web
  app
   as
a
  REST API ?
 
 
  Josh.
 



 --
 Regards - Ernesto Reinaldo Barreiro
 Antilia Soft
 http://antiliasoft.com

   
  
 
 
 
  --
  Martin Grigorov
  jWeekend
  Training, Consulting, Development
  http://jWeekend.com
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 



 --
 Martin Grigorov
 jWeekend
 Training, Consulting, Development
 http://jWeekend.com

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org





-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: Wicket as rest backend....

2012-09-20 Thread Bruno Borges
Take a look at the (very outdated) wicket-rest project:
http://code.google.com/p/wicket-rest/

*Bruno Borges*
(11) 99564-9058
*www.brunoborges.com*



On Thu, Sep 20, 2012 at 2:54 PM, Josh Kamau joshnet2...@gmail.com wrote:

 Hi Guys;

 Is there a way(a sub project may be..) of exposing a wicket web app as a
 REST API ?


 Josh.



Re: Wicket as rest backend....

2012-09-20 Thread Josh Kamau
Thanks Bruno... i will take alook

On Thu, Sep 20, 2012 at 9:56 PM, Bruno Borges bruno.bor...@gmail.comwrote:

 Take a look at the (very outdated) wicket-rest project:
 http://code.google.com/p/wicket-rest/

 *Bruno Borges*
 (11) 99564-9058
 *www.brunoborges.com*



 On Thu, Sep 20, 2012 at 2:54 PM, Josh Kamau joshnet2...@gmail.com wrote:

  Hi Guys;
 
  Is there a way(a sub project may be..) of exposing a wicket web app as a
  REST API ?
 
 
  Josh.
 



Re: Wicket as rest backend....

2012-09-20 Thread Ernesto Reinaldo Barreiro
I have implemented rest like services by mounting pages and using them to
generate XML content instead of HTML.

On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com wrote:

 Hi Guys;

 Is there a way(a sub project may be..) of exposing a wicket web app as a
 REST API ?


 Josh.




-- 
Regards - Ernesto Reinaldo Barreiro
Antilia Soft
http://antiliasoft.com


Re: Wicket as rest backend....

2012-09-20 Thread Josh Kamau
Good idea...

I would like to use JSON though...

Josh.

On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
reier...@gmail.com wrote:

 I have implemented rest like services by mounting pages and using them to
 generate XML content instead of HTML.

 On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com wrote:

  Hi Guys;
 
  Is there a way(a sub project may be..) of exposing a wicket web app as a
  REST API ?
 
 
  Josh.
 



 --
 Regards - Ernesto Reinaldo Barreiro
 Antilia Soft
 http://antiliasoft.com



Re: Wicket as rest backend....

2012-09-20 Thread Ernesto Reinaldo Barreiro
Then it would (maybe) better to mount a resource producing your JSON.

On Thu, Sep 20, 2012 at 9:21 PM, Josh Kamau joshnet2...@gmail.com wrote:

 Good idea...

 I would like to use JSON though...

 Josh.

 On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
 reier...@gmail.com wrote:

  I have implemented rest like services by mounting pages and using them
 to
  generate XML content instead of HTML.
 
  On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com
 wrote:
 
   Hi Guys;
  
   Is there a way(a sub project may be..) of exposing a wicket web app as
 a
   REST API ?
  
  
   Josh.
  
 
 
 
  --
  Regards - Ernesto Reinaldo Barreiro
  Antilia Soft
  http://antiliasoft.com
 




-- 
Regards - Ernesto Reinaldo Barreiro
Antilia Soft
http://antiliasoft.com


Re: Wicket as rest backend....

2012-09-20 Thread Dan Alvizu
I've used wicket-rest before - it got the job done, but I couldn't use it
for wicket 1.5.

Since then I've moved my rest services to Jersey - I highly recommend using
that if you can:

http://jersey.java.net/

-Dan

On Thu, Sep 20, 2012 at 1:21 PM, Josh Kamau joshnet2...@gmail.com wrote:

 Good idea...

 I would like to use JSON though...

 Josh.

 On Thu, Sep 20, 2012 at 10:14 PM, Ernesto Reinaldo Barreiro 
 reier...@gmail.com wrote:

  I have implemented rest like services by mounting pages and using them
 to
  generate XML content instead of HTML.
 
  On Thu, Sep 20, 2012 at 7:54 PM, Josh Kamau joshnet2...@gmail.com
 wrote:
 
   Hi Guys;
  
   Is there a way(a sub project may be..) of exposing a wicket web app as
 a
   REST API ?
  
  
   Josh.
  
 
 
 
  --
  Regards - Ernesto Reinaldo Barreiro
  Antilia Soft
  http://antiliasoft.com