How do I activate the new RESTful api?
Scott Battaglia
scott.battaglia at gmail.com
Fri Sep 19 08:12:57 EDT 2008
Thanks! I hadn't had a chance to look through that yet and do essentially
the same thing you did (so if it makes you feel better, you helped my
productivity too ;-))
-Scott Battaglia
PGP Public Key Id: 0x383733AA
LinkedIn: http://www.linkedin.com/in/scottbattaglia
On Fri, Sep 19, 2008 at 6:12 AM, Michael Johnston <lastobelus at mac.com>wrote:
> The fix as a patch:
>
> --- cas-server-integration-restlet/src/main/java/org/jasig/cas/
> integration/restlet/TicketResource.java.orig 2008-09-19
> 03:01:41.000000000 -0700
> +++ cas-server-integration-restlet/src/main/java/org/jasig/cas/
> integration/restlet/TicketResource.java 2008-09-19 03:08:22.000000000
> -0700
> @@ -16,6 +16,7 @@
> import
> org.jasig.cas.authentication.principal.UsernamePasswordCredentials;
> import org.jasig.cas.ticket.TicketException;
> import org.restlet.data.Form;
> +import org.restlet.data.Reference;
> import org.restlet.data.Request;
> import org.restlet.data.Status;
> import org.restlet.resource.Representation;
> @@ -61,7 +62,8 @@
> final String ticketGrantingTicketId =
> this.centralAuthenticationService.createTicketGrantingTicket(c);
> System.out.println(ticketGrantingTicketId);
> getResponse().setStatus(Status.SUCCESS_CREATED);
> - getResponse().setLocationRef(ticketGrantingTicketId);
> + Reference ticket_ref =
> getRequest().getResourceRef().addSegment(ticketGrantingTicketId);
> + getResponse().setLocationRef(ticket_ref);
> } catch (final TicketException e) {
> log.error(e,e);
> getResponse().setStatus(Status.CLIENT_ERROR_BAD_REQUEST,
> e.getMessage());
> _______________________________________________
> Yale CAS mailing list
> cas at tp.its.yale.edu
> http://tp.its.yale.edu/mailman/listinfo/cas
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://tp.its.yale.edu/pipermail/cas/attachments/20080919/9215329d/attachment.html
More information about the cas
mailing list