Package org.voltdb

Examples of org.voltdb.VoltProcedure$StmtProcedure


//    }
   
    @SuppressWarnings("unchecked")
    public static <T extends VoltProcedure> T getCurrentVoltProcedure(PartitionExecutor executor, Class<T> expectedType) {
        int tries = 3;
        VoltProcedure voltProc = null;
        while (tries-- > 0) {
            voltProc = executor.getDebugContext().getCurrentVoltProcedure();
            if (voltProc != null) break;
            ThreadUtil.sleep(NOTIFY_TIMEOUT);   
        } // WHILE
        assertNotNull(String.format("Failed to get %s from %s", expectedType, executor), voltProc);
        assertEquals(expectedType, voltProc.getClass());
        return ((T)voltProc);
    }
View Full Code Here


                @Override
                public Map<String, Object> visitJava(Class<?> p) throws VoltCompilerException {
                    // get the short name of the class (no package)
                    String shortName = deriveShortProcedureName(p.getName());

                    VoltProcedure procInstance;
                    try {
                        procInstance = (VoltProcedure)p.newInstance();
                    } catch (InstantiationException e) {
                        throw new RuntimeException("Error instantiating procedure \"%s\"" + p.getName(), e);
                    } catch (IllegalAccessException e) {
View Full Code Here

TOP

Related Classes of org.voltdb.VoltProcedure$StmtProcedure

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.