• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

persistance question

 
Ranch Hand
Posts: 166
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I've got a requirement that a user can work with several databases at once. DBs can be attached or detached by the user whenever they wish. But there's some data that should always be available.
What we do is persisting this data in all databases, but this doesn't solve the problem completely.
Ideally, I'd like to store this data on the file system, but EJBs are banned to use java.io directly (by the spec). Is there any way to work it around?
What are other options for persisting data?
 
Ranch Hand
Posts: 2166
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
what about storing data temporarily as durable jms topics?
[ March 04, 2004: Message edited by: Axel Janssen ]
 
Ranch Hand
Posts: 2713
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why not use a small database dedicated specifically for this task? Something like MySQL or even an in-memory database like hsqldb.
 
Ranch Hand
Posts: 1934
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
well, it is common that many databases will be present for a enterprise; but there are common tables that are shared across different databases.
They are usually names as a reference work in the schema. I can not answer how to setup this mechanism.
This is more of a database question. Please check with a DBA in your work place, if he is experienced and knows stuff; he can sure help you set that up.
(example is employee table in a enterprise database setup).
Dan.
 
Serge Adzinets
Ranch Hand
Posts: 166
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Axel Janssen:
what about storing data temporarily as durable jms topics?


That data should be stored permanently, not temporarily. Anyway, jms topics are stored in the DB as well, so the client would have to set up the JMS in the app server and map it to the DB.
 
Serge Adzinets
Ranch Hand
Posts: 166
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Chris Mathews:
Why not use a small database dedicated specifically for this task? Something like MySQL or even an in-memory database like hsqldb.


OK, there's no need in additional dbms as a client should already have one. The simplest solution would rather be setting up a separate db for this data, which should be always available.
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why don't you externalise this data and load it during startup? A helper class can always update this in sync with database..
 
Serge Adzinets
Ranch Hand
Posts: 166
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Chris Daniel:
well, it is common that many databases will be present for a enterprise; but there are common tables that are shared across different databases.
They are usually names as a reference work in the schema. I can not answer how to setup this mechanism.
This is more of a database question. Please check with a DBA in your work place, if he is experienced and knows stuff; he can sure help you set that up.
(example is employee table in a enterprise database setup).
Dan.


This is an interesting idea... I think this could be achieved when defining a table in one db and declaring an alias pointing to it in another.
Thanks, guys, for your help!
 
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"shashi",
Welcome to the JavaRanch
We don't have many rules here but one of them is our naming policy, which requires both a first name and a last name for a display name. You can edit your profile via the My Profile link next to the moose head.
Thanks.
 
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, even I/O is not possible thenre is a way to do if you have samll ammount of data. that is Resource Reading..
Java Provides ResuourceBundel API to do so...
just a suggestion..to make simple
Viswa
-------
 
Joel Salatin has signs on his property that say "Trespassers will be Impressed!" Impressive tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic