Access Keys:
Skip to content (Access Key - 0)

caGrid 1.3


Using the Photosharing Service


Table of Contents

Creating Galleries


We now want to create our personal and public galleries. We will create a "SummerVacation" gallery as well as a "Work" gallery.

Start the Image Gallery Application

  1. Open a Windows Command Prompt
  2. Change directory to your Hackathon directory

    %> cd C:\hackathon

  3. Start the gallery application

    %> ant gallery

Create Galleries:

  1. Click the Gallery Browser button near the top of the panel.
  2. Select MyLaptop in the Photo Sharing Services(s) tree viewer
  3. Right-Click on MyLaptop
  4. Click + Add Gallery (Note for Mac Users: command + double click will also access the menu)
  5. Set SummerVacation as Gallery Name
  6. Add a second gallery called Work

Adding Photos


Now let's add some photos to each gallery that we have created.

Add Photos to SummerVacation Gallery


  1. Select SummerVacation from the Viewer.
  2. Right-Click on SummerVacation and click + Add Photo
  3. Set "Jen and I" as Name
  4. Set "Walking on the Beach at Sunset" as the Description
  5. Browse to C:\hackathon\images and select SummerOne.jpg
    Note: When browsing for the images, you'll need to change "Files of type:" to All Files to see Folders.
  6. Click Add Photo
  7. Set "Surfing" as Name
  8. Set "Surfing a 10' foot wave" as the Description
  9. Browse to C:\hackathon\images and select SummerTwo.jpg
  10. Click Add Photo
  11. Set "Aunt Midge and Mom" as Name
  12. Set "Mom and Aunt Midge going for a walk" as the Description
  13. Browse to C:\hackathon\images and select SummerThree.jpg
  14. Click Add Photo

Viewing the Gallery

  • Right-Click on SummerVacation and select View
    This will refresh the Gallery Browser and display the recently added photos.
  • Click a thumbnail to see a full-size photo.
  • Click the Access Control to review the permissions for the gallery.
  • Note that by default only you have the ability to view or add images to the gallery.
  • Make note of your Identity. You'll need to provide to your neighbor later so he can give you permissions to see their photo galleries.

Add Photos to Work Gallery


  1. Select Work from the Viewer.
  2. Right-Click on Work and click + Add Photo
  3. Set "Opening Remarks" as Name
  4. Set "Opening Remarks by Dr Livingston" as Description
  5. Browse to C:\hackathon\images and select ConferenceOne.jpg
  6. Click Add Photo
  7. Select Work from the Viewer.
  8. Right-Click on Work and click + Add Photo
  9. Set "Presentation" as name
  10. Set "Presentation on cliff erosion" as the description
  11. Browse to C:\hackathon\images and select ConferenceTwo.jpg
  12. Click Add Photo

13. Select Work from the Viewer.
14. Right-Click on Work and click + Add Photo
15. Set "Bones" a name
16. Set "Head bone connected to the neck bone" as the description.
17. Browse to C:\hackathon\images and select ConferenceThree.jpg
18. Click Add Photo

Share Your IP Address


We've just finished loading our own photos onto the grid. Now we want to see our neighbor's photos. Since we're not using a centralized index service to advertise our services for this tutorial, we'll need to manually configure our gallery browser to connect to other services. To do this we'll need to provide our machine's IP address to a neighbor and obtain our neighbor's IP address.

If you have been doing this tutorial with someone else on a different machine:

  1. Give them the IP address to your machine.
  2. Note the IP address to their machine.

Verifying the PhotoSharing Service


Verify that you can access your neighbor's PhotoSharing Service:

  1. Open Internet Explorer
  2. Go to: https://<NEIGHBOR'S IP>:8443/wsrf/services/cagrid/PhotoSharing
  3. Click "Yes" (or "Continue to this website") if prompted for a "Security Alert" to access our secured service.
Note: If you cannot connect to your neighbor or vice versa, you might to need to check your network / firewall settings to allow incoming connections on port 8443.

View Your Neighbor's Gallery


We'll now need to configure the Image Browser

  1. Select Window->Preferences
  2. Expand Photo Sharing
  3. Select Photo Sharing Service(s)
  4. Set the Display Name to your neighbor's machine's hostname
  5. Set the Service URL to https://<NEIGHBOR IP>:8443/wsrf/services/cagrid/PhotoSharing
  6. Click + Add
  7. Click Save
  8. Click Gallery Browser. You should now see the Services you just added.
  9. Select a new service and expand it.
  10. Right-Click on one of your neighbor's galleries and click "View"
    By default, when galleries are created only the creator has the ability to view or add photos. You should receive an error message from your neighbor's service as shown below.

Share Your Grid Identity


We've connected to our neighbor's service, but we don't have permission to view any of the galleries. To grant view privileges, our neighbor will need to know who to grant access to. We'll need to provide them with our grid identity so they can grant us view rights.

In the Gallery Application:

  1. Click the My Account menu item, then select Credential Manager
  2. Share your Identity with your neighbor

Give Your Neighbor Permissions


Now that we have our neighbor's grid identity, we can grant them permission to see only those galleries we want them to see.

  1. Click on your Work gallery
  2. Select the Access Control tab
  3. Set your neighbor's grid identity into the Identity box at the bottom of the panel.
  4. Click Add
  5. Check the View Images checkbox next to the newly added Identity

After you've given permissions to your neighbor and vice versa, try viewing the Work gallery and SummerVacation gallery. You should now be able to view their Work gallery and not the SummerVacation gallery. Nor should you be able to add additional photos to their Work gallery.

We have worked with the PhotoSharing service and displayed its security capabilities and ease of use. The next part in the tutorial is an advanced section that will walk through the steps of creating the service using Introduce.

Last edited by
Sarah Honacki (1017 days ago)
Adaptavist Theme Builder Powered by Atlassian Confluence