Using Indy SDK in react native

error observed:

org.hyperledger.indy.sdk.InvalidStateException: The SDK library experienced an unexpected internal error.

This is my code snippet:

    public void openPool(Promise promise ){
        Log.i("RNIndy", "inside openpool");
        String poolName = "indy_pool";

                poolName = PoolUtils.createPoolLedgerConfig();
                Log.i("RNIndy", "pool name is " + poolName);
            } catch (PoolLedgerConfigExistsException e) {
                Log.i("RNIndy", e.getMessage());

            Log.i("RNIndy", "created genesis config");
            Log.i("RNIndy", "protocol version set");
            Pool poolHandle = Pool.openPoolLedger(poolName, null).get();
            Log.i("RNIndy", "resolving poolHandle");
        }catch (Exception e) {
                promise.reject("Exception", e.getMessage());

Erro occurs at Pool poolHandle = Pool.openPoolLedger(poolName, null).get();

I am running on an android device and error happens when openPool is called
can someone guide me?

I am using indy v 1.14.1

It was an issue with how I built my image and run the containers.
I had run them using these commands:

docker build -f ci/indy-pool.dockerfile -t indy_pool .
docker run -itd -p 9701-9708:9701-9708 indy_pool

I deleted the containers and built and run using following commands and it started working.

docker build --build-arg pool_ip=<host_ip> -f ci/indy-pool.dockerfile -t indy_pool .
docker run -itd -p <host_ip>:9701-9708:9701-9708 indy_pool