S++Business systems language
DEMO SOURCE · SPP / APP / PHYRead the book

product.phy

product/product.phy

Download original file · Petstore source contents

1domain product;23phy {4    numeric {5        replace BigDecimal(9, 2) with BigDecimal(18, 2);6    }7    i18n {8        resources: "../../resources/i18n/product/";9        defaultLocale: "en-US";10    }11    environment develop {12        repository shopRecords {13            adapter jdbcObjectRepository;14            config default = true;1516            config appDdlTables = true;17            config datasourceUrl = "${spp.petstore.datasource-url:jdbc:h2:mem:petstore;DB_CLOSE_DELAY=-1}";18            config driverClassName = "org.h2.Driver";19            config table = "petstore_records";20        }21        backend shopDatabase {22            adapter localJdbc;23            at shopRecordsResource;24            repository shopRecords;25            config datasourceUrl = "${spp.petstore.datasource-url:jdbc:h2:mem:petstore;DB_CLOSE_DELAY=-1}";26            config driverClassName = "org.h2.Driver";27        }28    }29    environment testing {30        config domainRpcToken = "${spp.petstore.testing.rpc-token}";31        repository shopRecords {32            adapter jdbcObjectRepository;33            config default = true;34            config appDdlTables = true;35            config datasourceUrl = "${spp.petstore.testing.product-url:jdbc:h2:file:./petstore-demo/target/testing-product;DB_CLOSE_DELAY=-1}";36            config driverClassName = "org.h2.Driver";37            config table = "petstore_records";38        }39        backend shopDatabase {40            adapter localJdbc;41            saga shopRecordsResource;42            repository shopRecords;43            config datasourceUrl = "${spp.petstore.testing.product-url:jdbc:h2:file:./petstore-demo/target/testing-product;DB_CLOSE_DELAY=-1}";44            config driverClassName = "org.h2.Driver";45        }46    }47}