jakarta-jcs-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bret Schuhmacher" <Bret.Schuhmac...@lombardi.com>
Subject RE: Really stupid question - can I cache any random object?
Date Wed, 09 Jul 2008 04:29:00 GMT
No, just an object.  I thought you could cache anything (the little docs
I found just showed "Object").  But being serializable makes sense now
that I think about it.  Is this required for memory caching, too,
though?  I've got the most minimal memory cache set up (cache.ccf copied
directly from the web pages).  I'll change my objects and see what
happens.  Thanks for the quick response!! :-)

Rgds,


Bret


> -----Original Message-----
> From: Michael Toback [mailto:Michael.Toback@chordiant.com]
> Sent: Wednesday, July 09, 2008 12:17 AM
> To: JCS Users List
> Subject: RE: Really stupid question - can I cache any random object?
> 
> Silly question about your stupid question. Is your object
serializable?
> 
> -----Original Message-----
> From: Bret Schuhmacher [mailto:Bret.Schuhmacher@lombardi.com]
> Sent: Tuesday, July 08, 2008 9:09 PM
> To: jcs-users@jakarta.apache.org
> Subject: Really stupid question - can I cache any random object?
> 
> Can I cache *any* object?  I get exceptions when I attempt to cache
> objects I've created, although I can cache simple objects like
Strings.
> Unfortunately cache.put(String foo, myCustomObject bar) doesn't tell
me
> much more than the name of the class I'm trying to cache (i.e.
> "myCustomObject").  It doesn't tell me why it threw the exception, it
> just prints a stacktrace.  Like I said - it all works fine if I do
> this:
> cache.put("foo", "bar"), but if I do cache.put("foo", new
> myCustomObject()) it will fail.  I've even cast myCustomObject back to
> Object, but it still doesn't like it.  Any way to get more verbose
> messages out of the JCS code instead of just ERROR level?
> 
> Thanks,
> 
> 
> Bret
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jcs-users-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jcs-users-help@jakarta.apache.org
> 
> The information transmitted herewith is sensitive      information of
> Chordiant Software or its customers and is intended only for use to
the
> individual or entity to which it is addressed. If the reader of this
> message is not the intended recipient, you are hereby notified that
any
> review, retransmission, dissemination, distribution, copying or other
> use of, or taking of any action in reliance upon, this information is
> strictly prohibited. If you have received this communication in error,
> please contact the sender and delete the material from your computer.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jcs-users-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jcs-users-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: jcs-users-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jcs-users-help@jakarta.apache.org


Mime
View raw message