Generator-jhipster: Microservices stack generation using JDL

Created on 30 Aug 2018  Â·  15Comments  Â·  Source: jhipster/generator-jhipster

@MathieuAA has done most of the work already, this ticket is for fixing any gaps and making the full stack generation work. I'll be starting this next week as I'm planning to demo this.

$100

All 15 comments

@MathieuAA can you list down any known issues or TODO on this part here as well

Yes, I'll try to do it when I have the time today

@MathieuAA @deepu105 hey guys, if you need another pair of eyes to try/test/give feedback on the new JDL version on microservices stack, I'm your man.

My main issue about the generation, and my only one, is multi-app generation. Telling the generator to import a JDL file (creating the .yo-rc.json & entity files) was pretty "easy" once yarn and some yeoman surprises got out of the equation.
However, the multi-app generation flow as described below:

  • Reading a JDL file (check)
  • Creating all the .yo-rc.json & entity files in all required folders (check)
  • Knowing what to generate and where (the JDLImporter does all the work, check)
  • Ordering the generators to:

    • Go to a certain folder

    • Generate the target (app and/or entity/ies)

    • Go back to the root (where the JDL file actually is)

    • Generate another target

The last point isn't done. Solutions exist:

  • Fighting yeoman might work, but I don't want another headache like the one before the conf.
  • Not using yeoman but using JHipster as an installed tool (calling the generation from the outside): ugly solution, and not testable.
  • Not having folders but multiple JDL files (one for each app, each file being self-sufficient), and for each file (understand: app & its entities) generating the app & entities, moving the generated files into a created folder -> I don't quite like it as it involves file manipulation

And there's the matter of upgrading the JDL Studio. I vote to redo the app from scratch.
I clearly don't have the time to do any of that right now (I don't even have the time to do half the things I want, even for myself). If I'm lucky, I can code this week-end the linter.

I have some ideas on how to do the full stack generation. It will be a mix
of the JH cli and yeoman part working together. Yes that means if you try
to do yo jhipster: import-jdl it will fallback to current behaviour. But
thats ok for me we are not advising anyone to do yo commands anymore and if
someone is stubborn to do that then they just miss the feature. Not a big
deal. I'm back from vacation and will start work on this soon.

On Thu, 30 Aug 2018, 11:48 pm Mathieu ABOU-AICHI, notifications@github.com
wrote:

My main issue about the generation, and my only one, is multi-app
generation. Telling the generator to import a JDL file (creating the
.yo-rc.json & entity files) was pretty "easy" once yarn and some yeoman
surprises got out of the equation.
However, the multi-app generation flow as described below:

  • Reading a JDL file (check)
  • Creating all the .yo-rc.json & entity files in all required folders
    (check)
  • Knowing what to generate and where (the JDLImporter does all the
    work, check)
  • Ordering the generators to:

    • Go to a certain folder

    • Generate the target (app and/or entity/ies)

    • Go back to the root (where the JDL file actually is)

    • Generate another target

The last point isn't done. Solutions exist:

  • Fighting yeoman might work, but I don't want another headache like
    the one before the conf.
  • Not using yeoman but using JHipster as an installed tool (calling
    the generation from the outside): ugly solution, and not testable.
  • Not having folders but multiple JDL files (one for each app, each
    file being self-sufficient), and for each file (understand: app & its
    entities) generating the app & entities, moving the generated files into a
    created folder -> I don't quite like it as it involves file manipulation

And there's the matter of upgrading the JDL Studio. I vote to redo the app
from scratch.
I clearly don't have the time to do any of that right now (I don't even
have the time to do half the things I want, even for myself). If I'm lucky,
I can code this week-end the linter.

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/jhipster/generator-jhipster/issues/8185#issuecomment-417478093,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABDlF6yvhi1KOa1twni7g7QnE1zVJRumks5uWF3JgaJpZM4WSw-0
.

I have started work on this

@MathieuAA do you have any good sample JDL for microservice stack?

Le 9 sept. 2018 22:55, Deepu K Sasidharan notifications@github.com a écrit :@MathieuAA do you have any good sample JDL for microservice stack?

—You are receiving this because you were mentioned.Reply to this email directly, view it on GitHub, or mute the thread.

I used to, maybe in the tests. 

@MathieuAA I think you are generating jwtSecretKey from jh core, it keeps changing that during regeneration. You can leave that prop in generated json files and the generator will automatically generate that if not found

@deepu105 Indeed. I'll fix it tomorrow and release v3.3.4 for that (and do the same for rememberMe keys as well)

This ticket is complex and deserves clearly a bounty on this.

@pascalgrimaud I disagree. The complexity is either brought by:

  • Small things (changes here and there, nothing huge and interesting)
  • the generator itself (its internal composition, but we're already limited by yeoman)
    IMO, this ticket should be split in several tasks.

yes, I mean globally, not this specific one, because it's a big feature

I have 2 bounties left from yesterday, I'm gonna assign one to the JHcore ticket and one here

@pascalgrimaud and lets do the travis part in another ticket

Was this page helpful?
0 / 5 - 0 ratings

Related issues

dronavallisaikrishna picture dronavallisaikrishna  Â·  3Comments

lsadehaan picture lsadehaan  Â·  3Comments

SudharakaP picture SudharakaP  Â·  3Comments

DanielFran picture DanielFran  Â·  3Comments

DanielFran picture DanielFran  Â·  3Comments