pinpoint-apm/pinpoint · error · OracleConnectionStringException

Syntax error. Expected token='LITERAL

Error message

Syntax error. Expected token='LITERAL'' :<token>

What it means

Parser guard in getLiteralToken: a token was available but its type is not TYPE_LITERAL — the parser expected a literal value for a descriptor key and instead found a syntax token like '(' or '='. Indicates misplaced punctuation in the Oracle connection descriptor.

Solutions

  1. Ensure values in the descriptor are literals, e.g. (HOST=myhost) not (HOST=(...))
  2. Fix misplaced parentheses or '=' inside the value position
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at agent-module/plugins/oracle-jdbc/src/main/java/com/navercorp/pinpoint/plugin/jdbc/oracle/parser/OracleNetConnectionDescriptorTokenizer.java:220 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of pinpoint-apm/pinpoint@744c3d3075 (2026-09-07). Data as JSON: /api/errors/6e0d1caa0e96f211. Report an issue: GitHub.

Appendix: source

Thrown at agent-module/plugins/oracle-jdbc/src/main/java/com/navercorp/pinpoint/plugin/jdbc/oracle/parser/OracleNetConnectionDescriptorTokenizer.java:220

    public void checkEndToken() {
        Token token = this.nextToken();
        if (token == null) {
            throw new OracleConnectionStringException("parse error. token is null. Expected token=')");
        }
        // We can check by == because the token object is singleton.
        if (!(token == TOKEN_KEY_END_OBJECT)) {
            throw new OracleConnectionStringException("Syntax error. Expected token=')' :" + token.getToken());
        }
    }

    public Token getLiteralToken() {
        Token token = this.nextToken();
        if (token == null) {
            throw new OracleConnectionStringException("parse error. token is null. Expected token='LITERAL'");
        }
        // We can check by == because the token object is singleton.
        if (!(token.getType() == TYPE_LITERAL)) {
            throw new OracleConnectionStringException("Syntax error. Expected token='LITERAL'' :" + token.getToken());
        }
        return token;
    }

    public Token getLiteralToken(String expectedValue) {
        Token token = this.nextToken();
        if (token == null) {
            throw new OracleConnectionStringException("parse error. token is null. Expected token='LITERAL'");
        }
        // We can check by == because the token object is singleton.
        if (!(token.getType() == TYPE_LITERAL)) {
            throw new OracleConnectionStringException("Syntax error. Expected token='LITERAL' :" + token.getToken());
        }
        if (!expectedValue.equals(token.getToken())) {
            throw new OracleConnectionStringException("Syntax error. Expected token=" + expectedValue + "' :" + token.getToken());
        }
        return token;
    }

View on GitHub (pinned to 744c3d3075)