Wednesday Mar 10, 2010

WSDL Customization Issues and Workarounds in Java EE 6 Applications in NetBeans

I've found a couple issues when using NetBeans to generate a WSDL file for an EE 6 web service, and then customizing that WSDL file. Some other users have reported them as well, so I thought I'd share them with the community.

  • When I set a new wsdlLocation attribute in the web service class, this is ignored and the default, autogenerated WSDL is used instead. It appears that GlassFish v3 doesn't recognize the wsdlLocation attribute. A bug against GlassFish has been reported (11437), there's a fix in the nightly GF builds, and the fix will be there in 3.0.1. In the meantime, it's probably worth downloading and installing the nightly GF build and registering this server in the IDE.
  • When you use NetBeans to generate the WSDL for an EE 6 JAX-WS service, generation fails because wsgen "Could not create declaration for annotation type javax.ejb.Stateless" or javax.ejb.EJB. Workaround is simply to comment out those annotations, generate WSDL, then uncomment them.

The NetBeans guys told me that the second problem is related to wsgen in JAX-WS, not an NB issue. I posted this as issue #837 in jax-ws, but the JAX-WS guys replied that this was a problem with apt, not wsgen. Their suggested workaround is to "Pass the Java EE API jar that contains @Stateless in the wsgen classpath." I don't know how this is done and am waiting to hear from the NetBeans guys, again, to find out if this is something we can do in the IDE. Also, I hope someone can explain to me what "apt" is.

UPDATE: All these issues are resolved using NB 6.9 RC, GF 3.0.1 and JDK 6 u 20.

Friday Dec 04, 2009

RESTful Web Services and EJB 3.1

First, no, I'm not dead, and I'm still at Sun. But there hasn't been that much activity with NetBeans IDE support for WS, and I've been working a lot on PHP and Cloud. I'm here though to plug Milan Kuchtiak's new DZone article, which shows how JAX-RS 1.1 can be used with EJB 3.1, taking advantage of the new EE6 Singleton EJB and the JAX-RS @ApplicationPath annotation. Check it out at DZone.

Friday Feb 06, 2009

Question of the day

Why are versioning control systems given names like Subversion, Mercurial, and Git? Do I want to trust my project to software that undermines order, that is given to unpredictable fits of temper, or that is just annoyingly stupid?

Wednesday Jan 28, 2009

Still alive

My apologies for not posting in a while. My thoughts have been elsewhere, and for a large part of the time, so have I. My wife and I were in the US for 3 weeks, one week in the DC area and 2 weeks in NYC. DC pictures are on my Photobucket here and NYC pictures are here. The highlights of DC were our visits to the Natural History Museum and the Museum of American History at the Smithsonian. We are used to British museums, which are generally excellent, but these surpassed any history or natural history museums we have ever been to. I also found DC to be a more pleasant city than I remembered, but much has changed of course in the intervening 16 years. NYC was as staggering as it was 2 years ago on our first visit. Manhattan is one of the few cities, along with Rome, that I can wander around in for hours and be constantly gobsmacked just by the appearance of the place. Highlights include The Met, which may be the best museum we've ever been to (sorry, BM, we still love you!), and eating our way through ethnic neighborhoods, particularly Flushing in Queens. If you ever get the chance, I strongly recommend the Roosevelt Food Court at Roosevelt and Main.

Monday Jun 16, 2008

Back from Devon

Just back from a lovely short holiday in Devon, visiting my in-laws. My mother-in-law took us up to Dartmoor for a walk up and around Wistman's Wood. This is a tiny wood about the size of a large suburban back lawn in the States, but it's inhabited by twisted, stunted trees and a remarkable variety of mosses and ferns. It may be a remnant of what all Dartmoor was like before people and their sheep changed the landscape, though on the other hand it is much rockier than most of the moor. People also say it has survived because it was sacred to the Druids or some such and the locals didn't want to take their sheep there. On the other hand, it may just be too rocky.

There was also much drinking of real ale in nice pubs and wandering around Exeter. They had a craft fair on the Cathedral green, and Eve was happy to find represented a local farm that would sell her raw wool she could spin. She thought you couldn't buy raw British wool as it all had to be sold to the government's Wool Board, but evidently this only applies to white wool. The farm itself, West Yeo Farm, sounds pretty cool--besides various wool from rare breed sheep, they sell organic beef and pork from rare breed, free range animals. I'd provide a link but their web page is down, silly hippies.

Tuesday May 27, 2008

Olomouc and Kromeriz

Last weekend my wife and I went to Olomouc, a small historical city and ancient Archbishop's seat in central Moravia. It's a UNESCO world heritage site, mainly due to its plague column on the Upper Square, which is the largest Baroque column in Europe. We prefer the 2001 turtle fountain (both visible in photo). Olomouc is very pretty and very quiet on weekends and only a 3 hr train ride from Prague (2.5 if you take the Pendolino, but I don't think it's worth paying almost double). When we went a couple years ago, the only foreign tourists were on tours organized by the Catholic church to see various regional sites of pilgrimage. Now however there were a number of what appeared to be independent family groups. This includes what to me were a surprising number of Americans, in that any Americans at all who weren't doing a year abroad at the University or taking a side trip backpacking between Vienna and Krakow would be a surprising number. Well, good for the city, I say, as the region is rather depressed and needs all the money it can get. One indication of this is that the city's tourist information office is open on Sundays--unheard of! As this was our third visit to Olomouc, we took a day trip to Kromeriz, where the archbishop of Olomouc had his chateau (38 mins by train, one transfer).

Amadeus was filmed at the chateau, and it is a really impressive building, with a surprisingly good gallery of historical paintings. Usually small city chateau collections are full of B-team C. European stuff that the noble family who owned them couldn't be bothered to take when they fled the country ahead of Communist state asset seizure in 1948 (or 1946 if they'd been bad boys in the war).

Thursday May 15, 2008

Springtime in Prague

After the long, dank, grey Central European winter, Spring has arrived and with a bang. In the last couple weeks of April, everything flowered and all the leaves came out. True, I spent most of that time trying to get our new tutorials page nice and pretty, at least for web services. And then I was off to the Netherlands and Spain for 11 days, while everyone else was at JavaOne. (The Netherlands was great, and the weather really picked up after our first two days. On the other hand, while Barcelona is a great town, they had record breaking gales for two of the three days we were there.) But I'm back now, and it's May, which is my favorite time of the year in this country and this city. I have more pictures of Prague in general and Vinohrady, my neighborhood on my Photobucket account. You can also see some of my wife's knitting there...

Monday Feb 25, 2008

Food post: Bun ca

Since food is one of my great pleasures, I thought I'd share the occasional food post with you. On Sundays, my wife and I have the custom of going to the huge Vietnamese market complex in Malesice. Aside from the household supplies and countless dodgy textile stores, they have a couple of Asian grocers that actually sell fresh green stuff (hey, this is the Czech Republic) and some luncheon places that mainly serve the market workers. We usually go to the one at the end, where we sit huddled over a formica-topped table and watch Vietnamese state TV while having a big bowl of pho ba (beef noodle soup w broad rice noodles), or construct-your-own bun cha (crispy barbecued pork belly, not greasy at all, in a marinade, along with a bowl of rice vermicelli and a plate of greens. You spoon the marinade on the noodles, break up some greens on top and eat it with a slice of pork belly.) This Sunday we had enormous bowls of bun ca, fish soup with rice vermicelli. They make it from carp, the local cheap farmed fish. Normally I avoid carp as it is rather muddy and has a mushy texture, but the soup is made from tiny crispy fried bits of carp, in a broth with hot peppers, tomatoes, dill, onions, garlic, and scallions.

The pink lump in my bowl was a big cake of fish roe. I don't know if it was carp roe, which I never would have thought about eating, but it was certainly edible, whatever fish it was. Probably carp just due to the size. I shared my roe with Eve, who never met a fish egg she didn't like. Note also the condiments on the table, including a bowl of crisp fried onion and hot pepper in oil (white bowl in background), which makes pretty much anything delicious.

Belated cat blogging

By tradition, Friday is a cat blogging day, but as usual I am days behind everything, so you get it on a Monday.

That is Kocic, our miniature black cat. 6 years old and no more than 2.8 kg. That's just as big as she gets. She's a very affectionate and well behaved animal, except when she's hunting our toes, or when she decides to get our attention by sinking her fishhook-like claws into us.

Sunday Jan 27, 2008

Hello, World!

Well, hello, everyone! My name is Jeff Rubinoff and this is the end of my first month at Sun. I'm a technical writer on the NetBeans team, covering web services functionality.

I got my start in technical writing in 2002, working for Systinet. That's a name some of you will recognize. I was in charge of the WASP Server for Java doc set (later Systinet Server for Java), all 700+ pages of it, in DocBook source. When I started, I had never heard of XML in my life, and Java was an island in Indonesia, famous for its coffee. Later, as Mercury Interactive acquired Systinet and then Hewlett-Packard acquired Mercury, I moved over to the new SOA Systinet product. But after 5 years I was ready for a change, and when a position opened up on the NetBeans team, I decided to take it.

I knew a little about NetBeans from back when Systinet Developer supported it, although I had more experience with Eclipse. NetBeans has certainly improved leaps and bounds from those days, as has web service technology in general. When I joined Sun, I hadn't looked at web service creation since 2004, and I was immediately impressed with the convenience of J2EE 5 annotations in JAX-WS. In my day, when we wanted to deploy a web service, we had to create a deployment descriptor, and edit it by hand, and carry it uphill through the snow for 5 miles, without boots!

Since I am so new to the job, you can help me help you. What is missing from our tutorials or product Help that you would like to see? Is there anything about our page designs that you think could be improved? Send me a comment!

Also, have a look at my blogroll. It includes a bunch of NetBeans tech writing and web services veterans. It also has one or two people who have nothing to do with web services, but might interest you anyway...


I'm a technical writer for NetBeans, covering web service support.


« August 2016