private static ApplicationId getAndValidateFromParameter(URI from) {
        UriPattern.Match match = new UriPattern(fromPattern).match(from);
        if (match == null || match.groupCount() < 7)
            throw new BadRequestException("Parameter 'from' has illegal value '" + from + "'");

        return new ApplicationId.Builder()
            .tenant(match.group(2))
            .applicationName(match.group(3))
            .instanceName(match.group(6)).build();
    }
A handler that is able to create a session from an application package,
or create a new session from a previous session (with id or the "active" session).
Handles /application/v2/ requests

@author hmusum
configserver/src/main/java/com/yahoo/vespa/config/server/http/v2/SessionCreateHandler.java