@ Nullable static Long getTimeoutFromMethodConfig ( Map < String , ? > methodConfig ) { if ( ! methodConfig . containsKey ( METHOD_CONFIG_TIMEOUT_KEY ) ) { return null ; } String rawTimeout = getString ( methodConfig , METHOD_CONFIG_TIMEOUT_KEY ) ; try { return parseDuration ( rawTimeout ) ; } catch ( ParseException e ) { throw new RuntimeException ( e ) ; } }
Returns the number of nanoseconds of timeout for the given method config .