rds needs a cleanup, and isn't perfectly modeled, but here is an
example instance request.
Instance newInstance = api().create(
"id",
InstanceRequest.builder()
.instanceClass("db.t1.micro")
.allocatedStorageGB(5)
.securityGroup(securityGroup.getName())
.name("jclouds-db")
.engine("mysql")
.masterUsername("master").masterPassword("Password01")
.backupRetentionPeriod(0).build());
Note the flat request, and lack of complex relationships. You can't
create multiple dbs or multiple users afaik in RDS, which makes it
simple and more approachable.
Ideally, we wouldn't create, test, or do code reviews on things that
don't have a Customer who can validate it covers their use case and
that they will in fact use it, hopefully in prod.
Esp lacking a user, we should be careful not to add hairy code just
because it is defined in a public rest doc. In the case of this, I'd
do a simple create 1 DB with 1 user command and stop until someone
external asks for more in a issue or on the mailing list. This will
keep the review team working on things that add highest value, and
save you from the deep holes of complex api structure.
make sense?
https://github.com/jclouds/jclouds-labs/blob/master/rds/src/test/java/org/jclouds/rds/features/InstanceApiLiveTest.java
http://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_CreateDBInstance.html