Is it necessary to save data as region key if that's such a big? Can't you come up with unique uuid? And then use spring data repository for gemfire with handy find queries
Dharam On Aug 30, 2017 8:33 PM, "Xu, Nan" <[email protected]> wrote: > Yes, but because data is big, >100K, and other is small, to save the > bandwidth, I don’t want to get the full object back but only the other part. > > > > *From:* Dharam Thacker [mailto:[email protected]] > *Sent:* Wednesday, August 30, 2017 10:01 AM > *To:* [email protected] > *Subject:* Re: Get part of the object > > > > Region.get() is going to return you domain object. > > > > So let's say yoy have domain class with > > { > > byte[] data > > Map<String,Object> other > > } > > > > > > You can say, > > Region.get(data).getOther() > > > > Thanks, > > Dharam > > > > On Aug 30, 2017 8:18 PM, "Lyndon Adams" <[email protected]> wrote: > > Yes > > > > On 30 Aug 2017, at 15:47, Xu, Nan <[email protected]> wrote: > > > > Not sure I get it. you mean save a list, and list comprise of 2 objects -- > data and properties? > > > > *From:* Lyndon Adams [mailto:[email protected] > <[email protected]>] > *Sent:* Wednesday, August 30, 2017 9:45 AM > *To:* [email protected] > *Subject:* Re: Get part of the object > > > > Make the value a collection wrapper. > > > > On 30 Aug 2017, at 15:39, Xu, Nan <[email protected]> wrote: > > > > Thanks, wondering if geode can save 2 objects for a single key? So I can > put data and other property separately. Or every key is for 1 object? > Never use the PDX and server side function, is that mean those need to be > deployed to the server? or there is a way to programming register the > function to the server? > > > > Thanks, > > Nan > > > > *From:* Luke Shannon [mailto:[email protected] <[email protected]>] > *Sent:* Tuesday, August 29, 2017 8:02 PM > *To:* [email protected] > *Subject:* Re: Get part of the object > > > > +1 on Mike's suggestion for the ReflectionBasedAutoSerializer > > > > To get name and author you could use OQL: > > https://gemfire.docs.pivotal.io/geode/getting_started/ > querying_quick_reference.html#reference_D5CE64F5FD6F4A808AEFB748C867189E > <https://urldefense.proofpoint.com/v2/url?u=https-3A__gemfire.docs.pivotal.io_geode_getting-5Fstarted_querying-5Fquick-5Freference.html-23reference-5FD5CE64F5FD6F4A808AEFB748C867189E&d=DwMFaQ&c=SFszdw3oxIkTvaP4xmzq_apLU3uL-3SxdAPNkldf__Q&r=HB5LZowSGF4DiMmOUsCX6Q&m=8beRJvUxxhwMi53HGv0iYc9bpWOpIjRLWs6L_12UPVQ&s=XWQnjvDN7lTRBBHYWEMKtnyPfsLxW_Pq0wL1ZSMK1No&e=> > > > > On Tue, Aug 29, 2017 at 5:45 PM, Michael Stolz <[email protected]> wrote: > > You should probably use the PDX ReflectionBasedAutoSerializer. > > Then you can write a server-side function that you call to get just the > fields you want and return them. > > > -- > > Mike Stolz > > Principal Engineer, GemFire Product Manager > > Mobile: +1-631-835-4771 <(631)%20835-4771> > > > > On Tue, Aug 29, 2017 at 4:49 PM, Xu, Nan <[email protected]> wrote: > > Hi, > > > > I have an object comprise of > > > > MyObject{ > > byte[] data; > > String name; > > String author; > > …. > > Other properties; > > } > > > > Or I can use > > > > MyObject{ > > Byte[] data; > > Other allOther; > > } > > > > When I get by key, I only want to get all the properties except the data > itself, because data could be large, is that has to be done with query? > Not sure how the performance of query compare to region.get(key). > > > > Another question is to serialize the data. Do I need to upload the jar > containing MyObject to geode server? > > > > Thanks, > > Nan > > > ------------------------------ > > This message, and any attachments, is for the intended recipient(s) only, > may contain information that is privileged, confidential and/or proprietary > and subject to important terms and conditions available at > http://www.bankofamerica.com/emaildisclaimer. If you are not the intended > recipient, please delete this message. > > > > > > > > -- > > Luke Shannon | Platform Engineering | Pivotal > > ------------------------------------------------------------------------- > > > > Mobile:416-571-9495 <(416)%20571-9495> > > Join the Toronto Pivotal Usergroup: http://www.meetup. > com/Toronto-Pivotal-User-Group/ > <https://urldefense.proofpoint.com/v2/url?u=http-3A__www.meetup.com_Toronto-2DPivotal-2DUser-2DGroup_&d=DwMFaQ&c=SFszdw3oxIkTvaP4xmzq_apLU3uL-3SxdAPNkldf__Q&r=HB5LZowSGF4DiMmOUsCX6Q&m=8beRJvUxxhwMi53HGv0iYc9bpWOpIjRLWs6L_12UPVQ&s=6_3MUQQcXn4OGBkgQjyTWec_NaJU4gvp3tHRQfoV-38&e=> > ------------------------------ > > This message, and any attachments, is for the intended recipient(s) only, > may contain information that is privileged, confidential and/or proprietary > and subject to important terms and conditions available at > http://www.bankofamerica.com/emaildisclaimer. If you are not the intended > recipient, please delete this message. > > > ------------------------------ > > This message, and any attachments, is for the intended recipient(s) only, > may contain information that is privileged, confidential and/or proprietary > and subject to important terms and conditions available at > http://www.bankofamerica.com/emaildisclaimer. If you are not the intended > recipient, please delete this message. > > > > > ------------------------------ > This message, and any attachments, is for the intended recipient(s) only, > may contain information that is privileged, confidential and/or proprietary > and subject to important terms and conditions available at > http://www.bankofamerica.com/emaildisclaimer. If you are not the intended > recipient, please delete this message. >
