Welcome to the new Gigaspaces XAP forum. To recover your account, please follow these instructions.

Ask Your Question
0

Indexing object fields using xml configuration file

Hello!

Does anybody know, if it's possible to tell the gigaspace infrastructure which fields of my POJO object have to be indexed (for example using xml configuation file) to speed up read and take operations? Using @SpaceProperty(index=IndexType.BASIC) annotation is not an option, because this POJO is also used by other projects... So i don't want to change my object, but instead i'd like to have a configuration file, where all fields that need to be indexed are listed.

I've also looked through this page: http://www.gigaspaces.com/wiki/displa... but could not find the answer i need.

Thank you in advance.

{quote}This thread was imported from the previous forum. For your reference, the original is [available here|http://forum.openspaces.org/thread.jspa?threadID=2797]{quote}

asked 2009-01-12 05:01:25 -0500

dmytrop gravatar image

updated 2013-08-08 09:52:00 -0500

jaissefsfex gravatar image
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

See:

http://www.gigaspaces.com/wiki/display/XAP66/POJOSupport%28Annotations
%2Cgs.xml%29-+Advanced#POJOSupport%28Annotations%2Cgs.xml%29-Advanced-
XMLTags

Example:

<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE gigaspaces-mapping PUBLIC "-//GIGASPACES//DTD GS//EN"
"0/gigaspaces-metadata.dtd">http://www.gigaspaces.com/dtd/60/gigaspaces-metadata.dtd">

<gigaspaces-mapping>

<class name="com.j_spaces.examples.hellospacepojo.Employee"
persist="false" replicate="false" fifo="false" >

<version name="versionID" />

<id name="employeeID" auto-generate="false" />

<routing name="employeeID" />

<property name="lastName" index="BASIC" />

<property name="firstName" index="BASIC" />

</class>

</gigaspaces-mapping>

Shay

answered 2009-01-12 06:27:19 -0500

shay hassidim gravatar image
edit flag offensive delete link more

Comments

Thanks Shay! :) This will work great for me!

dmytrop gravatar imagedmytrop ( 2009-01-12 06:39:33 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2009-01-12 05:01:25 -0500

Seen: 66 times

Last updated: Jan 12 '09