Monday, August 31, 2009

Project 2a

Due date: Fri, 11 Sep
Individual project


An understanding of
  • web service access through HTTP
  • authentication and authorization for web service access 
  • web service access through specific client libraries
Familiarity with
Part 1 (4 points)

Perform the following steps:
  • Create a Google account if you don't yet have one.
  • Sign into Google Base and create a few items through the web interface.
  • Following the ClientLogin documentation, use cURL to obtain an authorization token for your account (without using Captcha). For each request parameter, use a -d argument for cURL. Your response should contain three lines, one of which begins with Auth=. The following value is the authorization token you will use in subsequent requests.
  • Now take a look at your list of items using the following HTTP GET request (all on one line):
    • curl -H 'Authorization: GoogleLogin auth=YourToken'
  • In this list, you should see the embedded URLs of the individual items. Select and copy one of them. Now delete the item by submitting an HTTP DELETE request with the same Auth header as before directly to the item's URL.
  • Take another look at the list. The item you deleted should no longer be there.
Part 2 (6 points)

Perform the following steps:
  • Obtain a Google Base API key for installed applications.
  • Check out the GDataJavaClientTest example from the course repository, then update its Maven dependencies (right-click on project root node > Maven > Update Dependencies). There should be no more compile-time errors (as indicated by red Xs).
  • Enter your API key and your authorization token in the test/ file. All the existing JUnit tests should now pass (run them by right-clicking on the project root node > Run As > JUnit Test). 
  • Add another test method (with the @Test annotation) that does the following:
    • Insert several items of item type TestOnly, each with a float-unit attribute indicating the item's price.
    • Iterate through your feed and count the items with this item type and compute their average price. Use assertions to ensure that the item count and average price are as expected.
    • Iterate through your feed again to increase each item's price by the same percentage.
    • Iterate through your feed one more time to compute the new average. Check that it has gone up by the same percentage.
    • Iterate through your feed to delete all items you created at the beginning of this test method.
    • Iterate through your feed one last time to make sure the items are gone.
  • Part 1: Screenshot or other form of transcript of your complete command-line interaction with Google Base.
  • Part 2: Complete, working project with the additional test case.
Please follow these online submission instructions. Submission by email, especially to the mailing list, is highly discouraged.

Project 1

Due date: Fri, 4 Sep
Individual project

  • Installation of and familiarity with required software
  • An understanding of the HTTP protocol
  • Initial experiments with web service access
Part 1: Installing cURL

cURL is a command-line data transfer tool that supports HTTP, among several other common protocols. Therefore, it can play the role of a command-line web user agent (commonly called browser).

You should set up cURL in at least one of the following ways:
  • It should be installed by default on Mac OS X.
  • Install using the package management system for your platform, e.g., sudo apt-get install curl ca-certificates on Ubuntu.
  • Download an appropriate version for your platform with SSL support.
  • Use it remotely by logging on to one of the departmental hosts, or
Test the HTTPS support of your cURL installation as follows. You need your own Delicious account or your own Twitter account.
  • curl -u yourid
  • curl -u yourid
cURL will prompt you for the password. In either case, you should see a response in XML format (with lots of angular brackets). If you see any error messages pertaining to missing SSL support, double-check your installation and try again. If you don't have any bookmarks or friends, your response will be essentially empty, for example, <posts user="yourid" ...> </posts>, but that's still a successful interaction with the service.

Part 2: Installing Eclipse

We are using Yoxos to manage our Eclipse configurations. In particular, I have created a configuration for this class. To obtain a distribution for your OS based on this configuration:
(You can also manage your own configurations on Yoxos and use this one as a starting point.)

If Eclipse runs out of memory, please follow these directions.
  • Screenshot or other form of transcript of your successful access to the Delicious or Twitter web service.
  • Screenshot of your Eclipse configuration showing the successful execution of a HelloYourname Java project that prints Hello Yourname.
Please follow these online submission instructions. Submission by email, especially to the mailing list, is highly discouraged.

Monday, August 24, 2009

Tentative weekly course schedule

Week 1

  • organizational matters
  • overview
  • introduction to computing with services (ch 1)
  • SOA versus programmable web
  • connecting to and combining existing services: in-class demo

Week 2

  • principles of service-oriented computing (ch 5)
  • connecting to and combining existing services: in-class demo (continued)

Week 3

  • programming web services (ch 3)
  • resource-oriented (REST) services (Restlet book ch 4)
  • project discussion

Week 4

  • project 2b discussion
  • test 1

Week 5

  • enterprise architectures (ch 4)
  • basic standards for web services (ch 2)
  • resource-oriented (REST) and process/flow-oriented (SOAP) views of services (Restlet book ch 4  and ch 10)
  • project 2b discussion (as needed)

Week 6

  • restful services
  • project 2b discussion

Week 7

  • WS-* standards
  • stateful services
  • SOAP
  • test 2

Week 8

  • SOAP
  • Apache CXF framework
  • project 2c discussion

Week 9

  • project 2c discussion
  • message-based integration

Week 10

  • message-based integration
  • project 3 discussion

Week 11

  • message-based integration
  • project 3 discussion
  • test 3

Week 12

  • semantic web

Week 13

  • semantic web

Tentative project roadmap

  • connecting to and combining existing services: details TBA
  • implementing resource-based services:
  • implementing process-based (flow-based) services: Apache CXF
  • message-based service integration: Apache Camel
  • (time permitting) implementing agent-based and semantic web services: JADE, Jena

Project 0

Discussion Group Subscription

The first part of this project, due immediately, requires you to subscribe to the discussion group for this course. Keep in mind that you are responsible for being familiar with any information exchanged on this discussion group.

Linux Account Verification

The second part of this project, also due immediately, requires you to verify that your departmental Linux account works. (If you are a new student, you should have received email about your account.) This account is separate from your Loyola account and will allow you to use the lab machines as well as the server (we will use the CVS system for version control in conjunction with team-based development). If you have any problems with your Linux account, please contact our lab manager right away.

Group Formation

The last part of this project, due within about two weeks, requires you to form a project work group with other fellow students. The groups should be of size three. The groups should stay the same throughout the semester.
Once you have formed your group, please send me email containing a list of all group members with the user IDs for their departmental Unix accounts.
For each subsequent project, there will be one submission and consequently one grade per group.


There is no submission required for this project, other than sending the list of group members by email.