We're Hiring!!!

Thanks to our loyal customers and the great work our team members are doing for those customers, we are growing. We're looking for top talent to join our award winning team. Our staff get to teach the top firms in the country on the latest technologies or use those same technologies to build great new application for clients.

If you like solving challenging problems with great technology this might be the place for you.

Here are some of the needs we have:

·         Senior Developer/Architect (.Net Silverlight WPF WCF)

·         C# ASP.NET Developer

·         Software Developer (.Net)

·         Software Developer (ASP.Net MVC)

·         Software Developer (C# ASP.NET)

·         Sr. Systems / Software Engineer ( C#.Net )

·         .Net Manufacturing Systems / Solutions Architect

·         C#.Net developer

·         .Net Developer

·         Systems / Solutions Architect (.Net Manufacturing)

·         ASP.Net MVC Developer

·         Senior .Net Silverlight WPF WCF Developer/Architect

·         Sr. C#.Net Systems / Software Engineer

·         Senior Java Developer\Architect

 

For more details on our jobs, click here.

 

You can also apply online or if you find a job that is perfect for a friend, we make it easy for you to send it to them.

 

Let us know if you find one that is perfect for you or if you know someone who may be a great fit.

 

We’re offering a free training certificate to anyone who refers someone that joins our firm.

 

Thanks!

 

 


.NET WCF vs. Java JAX-WS and JAX-RS

by Jim White (Intertech Director of Training and Instructor)

I attended fellow instructor Andrew Troelsen?s Complete Windows Communication Foundation (WCF) class last week (recently updated for .NET 4.0). Andrew is a gifted teacher with a deep deep knowledge of .NET. If you want to learn anything about .NET, you really need to take a class from Andrew. Regardless of the topic, you are going to learn more in a day with Andrew than you will reading an entire library of books on your own. For those not aware, WCF is Microsoft?s relatively new service oriented framework. In Java, this would be equivalent to your JAX-WS and JAX-RS more on that in a bit APIs.

If you had to put me in one of the software-centricities today, I guess you would say I am a ?Java developer.? I have been doing Java for over 14 years. However, I have recently ?crossed to the dark side? (as some of my Java friends would say) as I am participating in and leading Intertech?s Cloud Computing efforts ? most notably with Windows Azure (Microsoft?s cloud platform). WCF is at the heart of a lot of Azure capabilities and APIs. I took Andrew?s class to get better insight into this Azure foundational element.

However, as a Java developer, I was also curious to see how the other world treated SOA and Web services. When writing interoperable Web services or consumer applications, I am always very curious how non-Java applications might work with my Java service or Java consumer. After all, SOA and Web services are all about interoperability.  This week?s class gave me a much better appreciation for that, at least from the current Microsoft stack. Below, I have provided a kind of compare and contrast look at how Java and .NET provide developers with tools and APIs for wresting with services. For those that spend a lot of time in SOA worlds, I hope you find the discussion encouraging. The point of this post is not to highlight the differences, but to really spotlight the fact that the two have to address many of the same issues and are therefore more alike than you might think. In other words, there is more that binds us (pun intended) than separates us.

First, some of the differences I saw. Note, ?differences? doesn?t not mean better or worse ? just different.

Support for Multiple Bindings

Java has an API for everything. Unfortunately, that means for each job, you need a different API. The JAX-WS API provides a great environment for writing interoperable SOAP-based Web Services and Web Service Clients. What if you need to communicate Java-to-Java using a different (more Java centric) protocol? Well, then it?s probably another distributed technology API (like RMI or EJB) that you probably want to explore ? at least if you want the performance and Java objects passed around. Want to do REST in Java? You need JAX-RS. In the .NET world, its WCF - period. In fact, what I was impressed with is that WCF has taken over as the communications framework in the Microsoft camps. Gone (not deprecated, but certainly relegated to legacy support) are .NET Remoting, ASP.NET web services, and other such APIs. Everything is now WCF. .NET to .NET, or .NET to Java using SOAP, it?s all the same. WCF offers multiple bindings. Bindings dictate the protocols, encoding mechanisms, and the transport layer used between consumers and service providers. What?s more, when you write a WCF service, the code doesn?t know or care what binding you choose. The binding is taken care of through configuration and hosting operations. In class, we wrote simple services in our lab that ran SOAP over HTTP in one minute and in TCP or named-pipe, .NET-centric fashion the next minute. Java wonks will argue you can do multiple bindings with Java APIs too. Yes you can, just like I can cut my yard with scissors ? doesn?t mean I want to or that it?s a good idea either.

WCF Host vs. the App Server

In Java, you typically create your service as a simple Java object (POJO or plain old Java object as it is know) and hand it off (with some configuration) to a Java application server/container to do the rest of the work. While Java services (like those produced in JAX-WS) can run in multiple environments, by and large, they are really engineered to be simply packaged and deployed into a managed Java runtime container (a Java application server). Nicely, the container manages the lifecycle of the service, routes traffic to and from the service, and generally handles all the details of the service as it is deployed and running. In the WCF, once you have created the service (which is also just a simple object), your work may only be half done. Now, you need to pick and possibly build its host environment. You can choose something like IIS to host the service (your job is now simpler) or you may choose to have a custom Windows service, or console application, Windows Server (through Windows Activation Service) host your service objects. Some choices will require you to write the code that essentially manages your service at runtime. Other options just need some configuration. Choices are good.  Allowing for you to pick how and what manages the life of your service.  However, choices can also lead to some complexity. I can see that making the wrong choice (or coding the host inappropriately) could lead to some issues (like poor service performance).

To be fair and honest, as those in the Java community know, running in an application container is not always a picnic - i.e. seamless or easy.  Your Java Web services don't always deploy simply or easily in containers as it often requires special libraries and/or configuration.  In fact, there is even a JSR (JSR-109) that attempts to address the deployment issue interoperable Web services.

Development Approaches (top-down, bottom up)

As Java?s main Web service stack (JAX-WS) is all about interoperable SOAP-based Web services, it should come as no surprise that the IDEs, tools, and API support both top-down (a.k.a. WSDL or contract first) and bottom-up (a.k.a. code first) approaches to building Web services. I?ll leave the pros/cons of both approaches to material you can find on the Internet. However, both are supported with neither relegated to an ?alternate approach? status. While you can do top-down service development in WCF, you need to use a command prompt tool (SvcUtil) to generate code from the WSDL and related schema documents. This seemed a bit kludgey to me. I am sure the tool works fine and once you are used to working with it, you can make it do all sorts of neat tricks. However, when I have a WSDL URL, I?d like to point my IDE to the WSDL and say ? go generate skeleton code for my new service. I didn?t see anything like that in WCF, which leads me to feel that the top-down approach is relegated to second class status in .NET. However, remember again that WCF deals with multi-bindings and the service code itself doesn?t know or care that it is doing SOAP or .NET binary. Top-down development is about using a contract to drive development of consumers and services. In an all .NET world, a top-down contract approach probably isn?t going to be an option (no WSDL to leverage there).

REST

Formal REST support is something added to WCF with the latest release (.NET 4.0). Frankly, it kind of looks like it was added recently.  For example, a number of configuration simplifications were made for "normal" services in .NET 4.0.  However, RESTful Web services must use the older form of configuration.  Further, the WCF templates in Visual Studio 2010 may still require a few reference updates and configuration changes when creating a RESTful service project.  These are minor issues, and I think we can all presume that things will be better and different in a future release of WCF.  However, WCF is the framework for any type of "communications" - REST or otherwise.  So again, when building a service using WCF, you can create a simple class that performs some sort of offering and you can make it available as a Web service, .NET named-pipe, or RESTful Web service all with the same framework.  Java's RESTful API (JAX-RS which is relatively young itself) is a separate API (and implementation) from its other service types (notably JAX-WS).  While it might be possible to have a class implement both JAX-WS and JAX-RS simultaneously, you are really talking about two different frameworks and two APIs for Java Web vs. RESTful services.

Security

WCF leverages Microsoft's Role Based Security system for most in-house (.NET to .NET) types of services.  This makes security slick and easy for service providers and consumers.  The API for determining who is the caller and what access they have is built into the API as well as a declarative model that makes securing services pretty easy.  For externally facing services, authentication and authorization are, like Java, a bit more manual (generating, handling and passing credentials and/or certificates in the message), and takes a bit more work on the part of the service provider/consumer to setup.  However, WCF applications can leverage the SQL Membership Provider API.  The SQL Membership Provider API, for non-.NET developers, is an auto-generated custom database (at runtime) for registering users and granting access.

Proxy API

In both Java and WCF, proxy classes are generated for the consumer developer.  The proxy makes communicating with the service easy and abstracts away the details of the protocol being used or even the fact that it is distributed computing going on.  Working with a WCF proxy is so simple, as they say in the commercials, even a caveman can do it.

BasicMathClient proxy = new BasicMathClient();
Console.WriteLine("1 + 1 = {0}", proxy.Add(1, 1));
proxy.Close();

In Java, there are actually two types of proxies.  Using the dynamic proxy client (a generated proxy), is very similar to using the WCF proxy.  I think JAX-WS client proxy coding is a bit more complex, but also offers the ability (in theory) to use different ports on the service (e.g. SOAP vs. RMI). 

BasicMathService service = new BasicMathService();
BasicMath port - service.getBasicMathSOAPPort();
System.out.println("1 + 1 = " + port.Add(1,1));

Java also offers the Dispatch Client.  This client requires more work (a lot more work), but allows the developer to have more direct control of the raw message (typically SOAP).

More That's The Same Than Different

As mentioned, there is really more that is similar between Java and .NET's Web service frameworks than is different.

Services as Simple Classes

Both rely on objects that come from simple classes dictated by interfaces for implementing services.  Plain old Java, C#, or VB objects are running the SOA world!  In fact, I even found it interesting that both environments encourage but do not require the use of an interface for defining the service.  Of course, services can contain complex logic and complex calls to other classes to get business done, but the service structure itself is simple and easy to understand.

Annotations or Attributes

Both rely on metadata (Annotations in Java and Attributes in .NET) to demarcate the service, its operations, and much of its runtime behavior.  Its fun to see that there is almost a one-to-one correspondence in the metadata tags in both worlds.  If you were a Java developers, I dare say you could pick up a C# Web service and translate it into Java code with only a little assistance.  And of course the opposite holds true for .NET developers.

//C# attributes
[ServiceContract]
public class ServiceTypeAsContract
{
[OperationContract]
public void SomeMethod() { /* Some interesting code. */ }
[OperationContract(IsOneWay = true)]
public void AnotherMethod() { /* Some interesting code. */ }
}
//Java annotations
@WebService
public class ServiceTypeAsContract
{
@WebMethod
public void SomeMethod() { /* Some interesting code. */ }
@WebMethod
@OneWay
public void AnotherMethod() { /* Some interesting code. */ }
}

Serialization/Deserialization

The frameworks are largely responsible for the creation of the request and response messages and marshalling/unmarshalling data to the applications.  The days of manipulating raw XML, JSON, or other formatted requests and responses are over in any language.  Let the framework do the grunge work of distributed communications and data formatting. 

WS-* and WS-I adherence

Both Java (JAX-WS) and WCF are now fully WS-I compliant.  This is good news for everyone.  While you can certainly use annotations/attributes or configuration to construct non-interoperable services, it requires work (and presumably acknowledgement on your part) to implement only for a certain platform.  There are still many gotchas in Web service interoperability, but developers now have a fighting chance of making things work with other platforms without having to know every detail about the other platforms.

Exceptions as faults

Both WCF and the Java frameworks translate language exceptions into faults.  Both provide a similar means of creating application specific faults that can contain more details about what went wrong to the client.

Filters vs. Channel

Both the Java frameworks and WCF provide for pre and post processes to operate on in bound and out bound messages at both the consumer and service provider levels.  They have different names, but provide similar capability to alter the message on the way to and from its destination and even to alter message flow under the right circumstances (say authentication failure).  In Java, these processes are called handlers.  In .NET/WCF they are called channels, but they serve the same general purpose.

I am sure a more experienced practitioner in both the Java and .NET SOA worlds can provide you with more detailed and better comparisons than I have here.  Hopefully, you get the idea that the software community is more united in its approach to SOA than divided - at least when it needs to be.  Sure, you can write applications in Java or C# that just need to communicate with their ilk and then things often get simpler.  But the design, patterns and approach to building services, no matter the platform, is starting to get more similar and that's good news for everyone.

Sign up today for Complete WCF or Complete Java Web Services to learn more about SOA in any environment.


Posted by: Jim White
Posted on: 6/21/2010 at 11:38 AM
Tags: , , , , , ,
Categories: .NET | Java | SOA/Web Services
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Subscribe to this BlogRSS comment feed

Questions and Answers to RESTful Web Services Oxy Blast

By Jim White (Intertech Instructor and Director of Training)

Last Thursday (April 15th), I presented in our virtual classroom on RESTful Web Services in Java, an introduction to the new JAX-RS API.  You'll find links in this blog to the presentation and demo code shown in that talk.  During the talk, several attendees posted questions on RESTful Web services which I did not have time to answer during the session.  Below, I have tried to answer the remaining questions.

1.  Can you address security in RESTful services?

Since most RESTful Web services rely on HTTP, you can use HTTPS and/or existing HTTP mechanisms to secure your RESTful Web services.  By design, RESTful Web services are lighter-weight that their SOAP counterparts.  Therefore, the kinds of security standards that exist in WS-* specifications are formally available in RESTful settings.  Some RESTful advocates suggest RESTful Web services are actually more secure because they rely on the Internet's existing security infrastructure (see http://www.networkworld.com/ee/2003/eerest.html?page=1).  

In general, you pretty much have to adopt/roll your own with regard to security.  I have started to see some third party (many open source) packages that provide security options for RESTful Web services, but these are not guided by any standard.

2. How is Jersey ( JAX_RS)  different than Servlet based REST mechanism like Restlet. I can see Jersey has AdapterServlet too? Is Jersey  based on Servlet too then?

Jersey is an JAX-RS implementation.  RESTlet is a way to provide RESTful services in Java, but it is not guided by any standard.  In JAX-RS, your RESTful resource services are implemented as annotated POJO's.  In RESTlet, the resource service classes extend ServerResource so some consider this a bit of a burden and intrusive.

The RESTlet group does now have an extension package with allows implements the JAX-RS specification.  See here for more details.

For more comparisons of JAX-RS (and implementations like Jersey) to RESTlets, see the following links:

http://thestewscope.wordpress.com/2008/01/08/rails-jsr311-restlet-and-jersey/

http://stackoverflow.com/questions/80799/jax-rs-frameworks

Per part 2 of your question, yes a servlet does act as a controller to route traffic to the appropriate annotated Jersey resource service.  In that way, both RESTlet and Jersey are similar in their reliance of servlet technology.

3. What is the best way to supply the request=GetCapabilities for REST that one has in SOAP or WMS services to communicate meta-data of REST services?

Many RESTful advocates would say the "conventions" associated with RESTful services makes a capabilities listing unnecessary.  That is, the resource as noun and HTTP method as verb make the services very transparent and easy to work with.

That answer doesn't satisfy many.  There have been home grown solutions like that provided by ebay (see http://developer.ebay.com/products/shopping/) that provide a useful API/description for developers to use.  Others have found a way to wedge RESTful descriptions into WSDL.  However, a relatively new description language called Web Application Description Language (see http://searchsoa.techtarget.com/tip/0,289483,sid26_gci1265367,00.html) is being used in the RESTful community to provide a WSDL-like alternative in the RESTful arena.

4. Can we run a rest web service using https protocol?

Yes

5. How about Spring and REST?

As of Spring 3.0, Spring offers RESTful API, but it is not JAX-RS compliant.  See here for details.  In general, Spring makes use of the annotated MVC controllers to serve as RESTful resources.

6. is there simple/lightweight authentication capabilities with restful web services?

Per #1, again nothing formal is provided, but there are some 3rd party packages sprouting up and all the standard Web authentication mechanisms could be used

7. Is there a way to override the HTTP return error and give more detail?

Yes - to some extent.  For how to modify the message returned from the Jersey implementation see https://jersey.dev.java.net/nonav/documentation/latest/user-guide.html#d4e410.

8. A lot of time was spent on exposing a service using JAX-RS from the server.  On the client, what does REST provide (or not provide) as a 'contract' to be used to define the web service..similar to the WSDL, etc in SOAP (for client-side data binding, etc.).

As mentioned and demonstrated in my talk, JAX-RS does not provide for a client API or contract.  Since REST normally operates on HTTP, one could develop a client using java.....  However, many JAX-RS implementations (like Jersey and RESTEasy) offer client side APIs.  These are non-standard, but do offer a means to more easily communicate with RESTful services independent of implementation.

9. It should be noted to get JSON to output correctly for web-applications (i.e.. {'id':12} instead of {'id':'12'} - supporting primitives as primitives, or handling of arrays properly etc, you need to setup a JAXBContextResolver and dictate the notation to user / type.  JAXB will not 100% give this to you.  You need to map your JAXB annotation to a JSON mapping using a context resolver.   Jersey website/forums do have some notes on this and I have been very successful using Natural Notation with GWT/GXT clients.

Correct and thanks for the providing the extra insight.

10. Twitter's REST API is also pretty good reference if you're trying to grow your own app and don't know where to start. http://apiwiki.twitter.com/Twitter-API-Documentation.

I agree.

11. How do we handle streaming using REST based approach?

There is nothing specific in the current JAX-RS specification about how to handle streaming content.

12. client-side data binding?  Thoughts on Spring 3 MVC as an impl?

Per #5 above, Spring 3 through MVC annotations does provide a RESTful service API but it is not Java spec compliant.  If one was using Spring heavily, I could see an attraction to using the same annotated Spring controller classes for both human Web facing and machine RESTful facing clients.

Thanks for all the great questions, comments and feedback  on our presentation.  I hope you will consider attending our Complete Java Web Services class.


Posted by: Jim White
Posted on: 4/19/2010 at 11:45 AM
Tags: , , , ,
Categories: Java | SOA/Web Services
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Subscribe to this BlogRSS comment feed

RESTful Web Services in Java (using JAX-RS)

If you did not have a chance to catch the free Intertech Oxygen Blast training event on April 15th (RESTful Web Services in Java), you can get the slides and code from the links below.

Slide Presentation:  http://www.intertech.com/downloads/JAXRS-OxyBlast.pdf

Code Samples:  http://www.intertech.com/downloads/JAXRS-OxyBlast.zip

Also, the presentation was recorded and can be replayed at the link here.


Posted by: Jim White
Posted on: 4/19/2010 at 8:59 AM
Tags: , , , , ,
Categories: Java | SOA/Web Services
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Subscribe to this BlogRSS comment feed

Learn Java RESTful Web Services

It’s St. Patrick's Day week.  May the luck of Irish be with you!  As my father (who was very Irish) used to tell me, everyone is Irish on St. Patty's Day.

Has your company joined the Service Oriented Architecture (SOA) bandwagon?  If so, you have probably become very familiar with the WS-* technologies to include XML, namespaces, Schema, SOAP, WSDL, WS-Security, etc.  I'll call this the "heavy stack" for SOAP-based Web service (service provider) and Web service client (consumer) development.  This stack provides all the standards and technologies for interoperable SOA.  While platform agnostic, many have found SOAP-based Web services difficult to learn and the XML message structure cumbersome and unnecessary for many applications - thus my "heavy" adjective.

As an alternative to SOAP-based Web services, many have started to explore REST-based, or RESTful, Web services.  In fact, many of the familiar Internet giants (Google, Amazon, eBay, Yahoo, etc.) provide RESTful Web services.  Some have abandoned SOAP-based Web services in favor of RESTful services!  Why?  RESTful services are considered "lighter."  That is easier to learn and data exchange that does not have to be as cumbersome/heavy.  RESTful Web services use the conventions that underlie the World Wide Web - namely HTTP - and any data exchange format you would like - to include plain text, CSV, JSON and even XML if you would like.

JAX-RS is the relatively recent Java EE specification and API for dealing with RESTful Web services in Java.  If you would like to learn more about JAX-RS and RESTful Web services, please come join my 2 hour Web seminar on April 15th.  This is a free seminar and is conducted over the Web so you can learn at home or the office (you don't even have to be dressed - just don't share that with me J ).  To sign up for this Web seminar, click the link at the bottom of this post.  If you are looking to learn more about both SOAP and RESTful Web service and Web service client development, consider taking Intertech's Complete Java Web Service class.

Free RESTful Web Services in Java seminar:  http://www.intertech.com/resource/Briefing.aspx?EventID=210


Posted by: Jim White
Posted on: 3/15/2010 at 10:07 AM
Tags: , , , ,
Categories: Java | SOA/Web Services
Actions: E-mail | Kick it! | DZone it! | del.icio.us
Post Information: Permalink | Comments (0) | Subscribe to this BlogRSS comment feed
Contact Us 651-994-8558 1-800-866-9884
Home | Training | Curriculum | Course Finder | Schedule | Enroll | Twin Cities Java User Group | Consulting | Foundation | Jobs | About Us | Our Story | Press Room | Instructors | President | Map & Directions | Sitemap

Java Training | JSF / Struts / Spring / Hibernate Training | Java Power Tools Training | .NET 4.0 & Visual Studio 2010 Training | .NET 3.5 and Visual Studio 2008 Training | .NET 2.0 and Visual Studio 2003 Training | Prism / MVVM / MEF Training | Microsoft Web Development Training | Cloud Computing Training | Ajax / Web Services / XML Training | Groovy and Grails Training | SQL Server 2008 Training | SQL Server 2005 Training | Mobile Development Training | SharePoint 2010 Training | SharePoint 2007 Training | Agile, Process, Analysis & Design Training | Arch/Design Patterns Training | Microsoft Official Curriculum Training | Web Development Training | Ruby Training | Rational Application Developer (RAD) Training | WebSphere Application Server Training | WebSphere Portal Training | WebLogic Training | Boot Camp Training | Project Management Training | C++ Training | Metro / WinRT / Windows 8 Development Training | Retired

Intertech delivers training on-site and virtually serving cities including Phoenix, AZ | San Francisco, CA | Los Angeles, CA | San Diego, CA | San Jose, CA | Washington, DC | Chicago, IL | Orlando, FL | Boston, MA | Duluth, MN | Minneapolis St. Paul, MN | Rochester, MN | Raleigh-Durham, NC | New York, NY | Philadelphia, PA | Austin, TX | Dallas, TX | Houston, TX | Seattle, WA.