jhipster-dotnetcore
jhipster-dotnetcore copied to clipboard
MSSQL does not work in databaseType
Overview of the issue
When importing a JDL with a databaseType set to mssql we get a:
ERROR! Error during import-jdl: Unknown value 'mssql' for option 'databaseType'.
Motivation for or Use Case
Reproduce the error
Related issues
Suggest a Fix
JHipster Version(s)
JHipster.NET :v3.1.1 jhipsterVersion: 7.1.0
JHipster configuration
JHipster Version(s)
E:\dev\studing\programming\dotnet\jhipster-test-app-microservice
`-- (empty)
JHipster configuration, a .yo-rc.json
file generated in the root folder
.yo-rc.json file
{ "generator-jhipster": { "blueprints": [ { "name": "generator-jhipster-dotnetcore", "version": "3.1.1" } ], "otherModules": [ { "name": "generator-jhipster-dotnetcore", "version": "3.1.1" } ], "baseName": "mystore", "namespace": "mystore", "applicationType": "gateway", "serviceDiscoveryType": "consul", "jhipsterVersion": "7.1.0", "skipClient": true, "clientFramework": "angularX", "withAdminUi": false, "clientTheme": "none", "skipUserManagement": true, "skipServer": false, "skipCheckLengthOfIdentifier": false, "skipFakeData": true, "jhiPrefix": "jhi", "entitySuffix": "", "dtoSuffix": "DTO", "testFrameworks": ["cypress", "gatling", "cucumber"], "pages": [], "creationTimestamp": 1629538114354, "cqrsEnabled": false, "databaseType": "mssql", "authenticationType": "oauth2", "serverPort": "5004", "enableTranslation": true, "nativeLanguage": "en", "languages": ["en", "ar-ly"], "packageName": "com.mycompany.myapp", "cacheProvider": "ehcache", "websocket": false, "prodDatabaseType": "mysql", "devDatabaseType": "mssql", "searchEngine": false, "buildTool": "maven", "enableHibernateCache": true, "reactive": false, "clientThemeVariant": "", "clientPackageManager": "npm", "entities": [] } }
JDL for the Entity configuration(s) entityName.json
files generated in the .jhipster
directory
JDL entity definitions
/* Store gateway application */ application { config { baseName store applicationType gateway packageName mystore serviceDiscoveryType consul authenticationType oauth2 databaseType sql devDatabaseType mssql prodDatabaseType mssql cacheProvider ehcache buildTool maven clientFramework angularX languages [en, ar-ly] blueprints [generator-jhipster-dotnetcore] testFrameworks [cypress, gatling, cucumber] } entities * } /* Invoice microservice application */ application { config { baseName invoice applicationType microservice packageName mystore serviceDiscoveryType consul authenticationType oauth2 databaseType mongodb devDatabaseType mssql prodDatabaseType mssql serverPort 8081 languages [en, ar-ly] } entities Invoice, Shipment } /* Notification microservice application */ application { config { baseName notification applicationType microservice packageName mystore serviceDiscoveryType consul authenticationType oauth2 databaseType mongodb cacheProvider no enableHibernateCache false serverPort 8082 languages [en, ar-ly] } entities Notification } /* Entiteis for store service */ /** Product sold by the Online store */ entity Product { name String required description String price BigDecimal required min(0) productSize Size required image ImageBlob } enum Size { S, M, L, XL, XXL } entity ProductCategory { name String required description String } entity Customer { firstName String required lastName String required gender Gender required email String required pattern(/^[^@\s]+@[^@\s]+\.[^@\s]+$/) phone String required addressLine1 String required addressLine2 String city String required country String required } enum Gender { MALE, FEMALE, OTHER } entity ProductOrder { placedDate Instant required status OrderStatus required code String required } enum OrderStatus { COMPLETED, PENDING, CANCELLED } entity OrderItem { quantity Integer required min(0) totalPrice BigDecimal required min(0) status OrderItemStatus required } enum OrderItemStatus { AVAILABLE, OUT_OF_STOCK, BACK_ORDER } relationship OneToOne { Customer{user(login) required} to User } relationship ManyToOne { OrderItem{product(name) required} to Product } relationship OneToMany { Customer{order} to ProductOrder{customer(email) required} , ProductOrder{orderItem} to OrderItem{order(code) required} , ProductCategory{product} to Product{productCategory(name)} } /* Entities for Invoice microservice */ entity Invoice { code String required date Instant required details String status InvoiceStatus required paymentMethod PaymentMethod required paymentDate Instant required paymentAmount BigDecimal required productOrderId Long required } enum InvoiceStatus { PAID, ISSUED, CANCELLED } enum PaymentMethod { CREDIT_CARD, CASH_ON_DELIVERY, PAYPAL } entity Shipment { trackingCode String date Instant required details String } relationship OneToMany { Invoice{shipment} to Shipment{invoice(code) required} } microservice Invoice, Shipment with invoice /* Entities for notification microservice */ entity Notification { date Instant required details String sentDate Instant required format NotificationType required userId Long required productId Long required } enum NotificationType { EMAIL, SMS, PARCEL } microservice Notification with notification /* General options */ service * with serviceClass paginate Product, Customer, ProductOrder, Invoice, Shipment, OrderItem with pagination
Environment and Tools
openjdk version "11.0.12" 2021-07-20 OpenJDK Runtime Environment Temurin-11.0.12+7 (build 11.0.12+7) OpenJDK 64-Bit Server VM Temurin-11.0.12+7 (build 11.0.12+7, mixed mode)
git version 2.32.0.windows.2
node: v14.17.5
npm: 6.14.14
Docker version 20.10.8, build 3967b7d
docker-compose version 1.29.2, build 5becea4c
Entity configuration(s) entityName.json
files generated in the .jhipster
directory
Browsers and Operating System
- [ ] Checking this box is mandatory (this is just to show you read everything)
thanks for your feedback i work on it soon or if you want you can help me to resolve it
For the comment we don't support application part in the jdl