Tm1Seed
import io.skipcheck.tm1.testcontainers.Tm1Seed;Used in the walkthrough Test your code against a real TM1.
Objects the image puts into an empty database on first start (its TM1_SEED
setting). The samples come from the TM1 install itself, so they're only available where
the install includes them.
A server seeded with IBM's SData sample:
Tm1Source source = Tm1Source.discover().orElseThrow();
// SData's login is admin / apple, and the server must be this version
try (var server = new Tm1ServerContainer(source).withSeed(Tm1Seed.SDATA)
.withExpectedVersion(Tm1Version.parse("11.8.03500.6"))) {
server.start();
Tm1Client tm1 = Tm1Client.builder()
.baseUrl(server.getRestUrl())
.basicAuth(server.getUsername(), server.getPassword())
.build();
try {
// SData's cubes, such as SalesCube
return tm1.cubes()
.modelCubes(ODataQuery.none().select(Cube.NAME))
.map(Cube::name)
.collectList()
.block(WAIT);
}
finally {
tm1.close().block(WAIT); // before the container stops
}
}
Members
values static | |
valueOf static | |
EMPTY static | No objects. |
SDATA static | IBM's SData sample, with the login admin / apple. |
values
staticstatic Tm1Seed[] values()valueOf
staticstatic Tm1Seed valueOf(String name)EMPTY
staticEMPTYNo objects: an empty database with the login admin and no password.
SDATA
staticSDATAIBM's SData sample, with the login admin / apple.
Also in the Javadoc.