/**
 * END USER LICENSE AGREEMENT (“EULA”)
 *
 * READ THIS AGREEMENT CAREFULLY (date: 9/13/2011):
 * http://www.akiban.com/licensing/20110913
 *
 * BY INSTALLING OR USING ALL OR ANY PORTION OF THE SOFTWARE, YOU ARE ACCEPTING
 * ALL OF THE TERMS AND CONDITIONS OF THIS AGREEMENT. YOU AGREE THAT THIS
 * AGREEMENT IS ENFORCEABLE LIKE ANY WRITTEN AGREEMENT SIGNED BY YOU.
 *
 * IF YOU HAVE PAID A LICENSE FEE FOR USE OF THE SOFTWARE AND DO NOT AGREE TO
 * THESE TERMS, YOU MAY RETURN THE SOFTWARE FOR A FULL REFUND PROVIDED YOU (A) DO
 * NOT USE THE SOFTWARE AND (B) RETURN THE SOFTWARE WITHIN THIRTY (30) DAYS OF
 * YOUR INITIAL PURCHASE.
 *
 * IF YOU WISH TO USE THE SOFTWARE AS AN EMPLOYEE, CONTRACTOR, OR AGENT OF A
 * CORPORATION, PARTNERSHIP OR SIMILAR ENTITY, THEN YOU MUST BE AUTHORIZED TO SIGN
 * FOR AND BIND THE ENTITY IN ORDER TO ACCEPT THE TERMS OF THIS AGREEMENT. THE
 * LICENSES GRANTED UNDER THIS AGREEMENT ARE EXPRESSLY CONDITIONED UPON ACCEPTANCE
 * BY SUCH AUTHORIZED PERSONNEL.
 *
 * IF YOU HAVE ENTERED INTO A SEPARATE WRITTEN LICENSE AGREEMENT WITH AKIBAN FOR
 * USE OF THE SOFTWARE, THE TERMS AND CONDITIONS OF SUCH OTHER AGREEMENT SHALL
 * PREVAIL OVER ANY CONFLICTING TERMS OR CONDITIONS IN THIS AGREEMENT.
 */

package com.akiban.rest.resources;

import com.akiban.server.AkServerInterface;
import com.google.inject.Inject;

import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;

/**
 * Easy access to the server version
 */
@Path("/version")
public class VersionResource {
    @Inject
    private AkServerInterface akServer;

    @GET
    @Produces(MediaType.APPLICATION_JSON)
    public Response getVersion(@QueryParam("format") String format,
                               @QueryParam("jsoncallback") String jsonp) throws Exception {
        StringBuilder builder = new StringBuilder();
        builder.append("[\n{");
        builder.append("\"server_name\":\"");
        builder.append(akServer.getServerName());
        builder.append("\",\"server_version\":\"");
        builder.append(akServer.getServerVersion());
        builder.append("\"}\n]");
        return Response
                .status(Response.Status.OK)
                .entity(builder.toString())
                .build();
    }
}

@@ -1285,30 +1285,82 @@
 ban.
-server.AkServerInterfa
+ais.model.TableName;%0Aimport com.akiban.server.service.restdml.RestDMLServi
 ce;%0A
@@ -1674,723 +1674,532 @@
     
-@Inject%0A    private AkServerInterface akServer;%0A%0A    @GET%0A    @Produces(MediaType.APPLICATION_JSON)%0A    public Response getVersion(@QueryParam(%22format%22) String format,%0A                               @QueryParam(%22jsoncallback%22) String jsonp) throws Exception %7B%0A        StringBuilder builder = new StringBuilder();%0A        builder.append(%22%5B%5Cn%7B%22);%0A        builder.append(%22%5C%22server_name%5C%22:%5C%22%22);%0A        builder.append(akServer.getServerName());%0A        builder.append(%22%5C%22,%5C%22server_version%5C%22:%5C%22%22);%0A        builder.append(akServer.getServerVersion());%0A        builder.append(%22%5C%22%7D%5Cn%5D%22);%0A        return Response%0A                .status(Response.Status.OK)%0A                .entity(builder.toString())%0A                .build(
+private static final String SCHEMA_NAME = TableName.INFORMATION_SCHEMA;%0A    private static final String TABLE_NAME = %22server_instance_summary%22;%0A    private static final int DEPTH = 0;%0A%0A    @Inject%0A    private RestDMLService restDMLService;%0A%0A    @GET%0A    @Produces(MediaType.APPLICATION_JSON)%0A    public Response getVersion(@QueryParam(%22format%22) String format,%0A                               @QueryParam(%22jsoncallback%22) String jsonp) throws Exception %7B%0A        return restDMLService.getEntities(SCHEMA_NAME, TABLE_NAME, DEPTH
 );%0A 

Use data service for version resource