Skip to content
This repository has been archived by the owner on May 12, 2020. It is now read-only.

Add start method which takes IRuntimeConfig without List<String> additionalParams #154

Open
LukeButters opened this issue Dec 27, 2018 · 0 comments

Comments

@LukeButters
Copy link

Hi

Could a start method be added which looks like this:

    public String start(IRuntimeConfig runtimeConfig, String host, int port, String dbName, String user, String password) throws IOException {
        return start(runtimeConfig, host, port, dbName, user, password, additionalParams, DEFAULT_ADD_PARAMS, DEFAULT_POSTGRES_PARAMS);
    }

So that it is possible to set it up like:

final String url = postgres.start(cachedRuntimeConfig(new File("target/embeddedPostgress").toPath()), 
                    "localhost", 12345, "name", "user", "pass");

Otherwise I would have to copy the private static List DEFAULT_ADD_PARAMS into the calling class then pass in those arguments.

I guess the alternative would be to make DEFAULT_ADD_PARAMS public although if that is done it would need to be wrapped in a unmodifiable list.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant