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

Ask Your Question
0

Space Routing and GSCs

Hello,

I have been experimenting with space routing using the HelloWorld sample application, and I think I have observed three behaviours I wasn't expecting:

  1. GSCs seem to remember routing information until they are cycled:

    • deploy the application
    • inspect the classes with the space browser to confirm that space routing is configured as I expect it to be
    • undeploy the application
    • add a new field to the class
    • modify Messages-gs.xml to specify the new field as the routing field
    • rebuild the application
    • redeploy it (by fetching it from the application directory)
    • restart the application
    • inspect the classes with the space browser

The routing configuration has not changed to my new field.

I then:

  • cycle the GSCs
  • re-deploy the application (no need to go to the source directory this time)
  • inspect the classes with the space browser

Now the routing configuration has changed to my new field.

  1. GS seems to select a routing field when none has been specified in the application:

    • remove the Messgaes-gs.xml file from the source area
    • rebuild the application
    • cycle the GSCs
    • deploy the application by fetching it from the application directory
    • inspect the classes with the space browser

Routing is set to id.

  1. Unable to configure routing with @SpaceRouting

    • add a new field to the Messages class
    • add @SpaceRouting annotation to that field's getter method
    • remove theMessgaes-gs.xml file from the source area
    • rebuild the application
    • cycle the GSCs
    • deploy the application by fetching it from the application directory

Routing is set to id, not my new field.

Can anyone confirm these behaviors? Are any of them bugs? The first one seems wrong to me. The second might be sensible. The third must just reflect some misunderstanding on my part.

Many thanks.

-Dan

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

asked 2008-12-31 04:14:00 -0500

subuta 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

1. This is a known issue. Will be fixed with the next GigaSpaces XAP 7.0 milestone. To clean the old version of the class you need to recycle the GSM/GSC. Sorry for the inconvenience involved.
2. By default if there is no routing field specified the ID field will be used as the routing field.
3. This should work. The getter method annotated with @SpaceRouting should be used as the routing field. Clean the relevant deploy folder recycle the GSM and GSC and re-deploy. You should see the annotated field as your routing field.

Shay

answered 2008-12-31 08:03:03 -0500

shay hassidim gravatar image
edit flag offensive delete link more

Comments

Hi Shay,

Thanks for this. It is most helpful.

-Dan

subuta gravatar imagesubuta ( 2008-12-31 12:46:54 -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: 2008-12-31 04:14:00 -0500

Seen: 68 times

Last updated: Dec 31 '08