Giter Club home page Giter Club logo

Comments (3)

japgolly avatar japgolly commented on June 3, 2024 1

Hi @yadavan88 , currently we don't support reading from HOCON format.

If you mean you're moving away from HOCON, then yes that's the right way to do it. You could also have .withPrefix("mongo.") and .withPrefix("postgres.") and then after they're composed together, put a .withPrefix("database.") on the outside, but that depends on how you structure your config code. Whichever way works best for you is the one you should choose.

from clear-config.

japgolly avatar japgolly commented on June 3, 2024

from clear-config.

yadavan88 avatar yadavan88 commented on June 3, 2024

@japgolly I came to know about this library and it is really awesome :) Thanks

Regarding the hocon format, if I currently have a config format as:

database {
  mongo {
   username = "mongoUser"
   password = "pass1"
  }
  postgres {
    username = "pgUser"
    password = "pass2"
  }
}

I should re-write them as and use .withPrefix("database.mongo.") and withPrefix("database.postgres.")

database.mongo.username = "mongoUser"
database.mongo.password = "pass1"
database.postgres.username = "pgUser"
database.postgres.password = "pass2"

Is this correct, or am I missing something?

from clear-config.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.