Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7968047
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T07:00:56+00:00 2026-06-04T07:00:56+00:00

I wonder what is the best way to implement dynamic domain model persisted in

  • 0

I wonder what is the best way to implement dynamic domain model persisted in SQL database?
Saying dynamic domain model I mean such model when user can change “class” of object by adding or removing properties.

For example: little internet shop where manager can add new types of product with web-interface.
Should I use something like Map everywhere? Maybe it is better to keep only dynamic part of object in Map? Or maybe runtime class generation will help? Or I should take a tour over dynamic languages like Groovy? I have tested first and second methods and this is real headache to develop in such way.

What is the common practise?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T07:00:57+00:00Added an answer on June 4, 2026 at 7:00 am

    You have a 1 to 1 from product to product type. So product has a member var called productType. You’ll also have a 1-to-many from product to features. So the product class will have a list of features.

    I can’t imagine a more wrong way to do this then using cglib to create classes on the fly.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I wonder what is the best way to implement a for-each loop over an
I wonder what is the best way to transfert data from the database to
I wonder what would be the best way to implement multiple versions / languages
I wonder how is the best way to integrate Java modules developed as separate
I always wonder about the best way to access a class attribute from a
I wonder what is the best way to measure the execution time of some
I wonder - what is the best way to supply contextual (i.e. not related
I wonder what's the best way to write a modular extension of an existing
I wonder what is the best way to test a method that only checks
I wonder what is the best way to deal with 3 levels deep and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.