Grails Package Naming

Recently, my friend and colleague asked some questions about package naming conventions in Grails. I think they were excellent questions, and I wouldn’t be surprised if others were wondering about the same things. You could get into arguments with some guys over stuff like this, but here is my opinion…

Is there an inherent advantage to that package naming convention? Do you use this package naming by default, or is it does it vary according to certain designs?

This is pretty standard, and a lot of J2EE shops do it this way. There is nothing forcing you, however, but I think this is the right way.

Let’s say your company is WidgetCo Inc, and they have a website at They want a new webapp called “Spanky” that will allow online ordering.


This package structure will allow them to create a new webap in the future for their internal payroll (or whatever):


So com.widgetco is their company package, and where they can park all their applications.

I saw a post on the Grails mailing list about someone having a package names like:
com.businessname.appname.domain and com.businessname.appname.controller, etc.

Does adding the “domain” or “controller” have an advantage? Seems like it would obviously prevent name clashes, but it also seems like overkill.

Don’t do this! This is bad. Grails creates these separations for you within grails-app by having controller and domain folders. The point being that you can have your Foo domain object, FooController, FooService, FooJob, FooEtc, and FooTests all in the same convenient package. When people start putting ‘domain’, ‘controller’, ’service’, etc. in their package names, they ruin that. Now there will be lots of importing. Boo!

We have a client that still has all their domain objects in a ‘domain’ package, and every time I go work with them I complain to them about it because I have to see so many meaningless import statements! So I’m in the FooController, and I need to import the Foo class? That sucks, IMHO. (They still haven’t done it because, as you know, repackaging is a huge pain in the ass! So get your packaging right early.)

Package names should describe and separate code functionality, not code type.

The aforementioned ‘domain’ package is describing what type of code is within: the domain classes. I don’t think this is a good idea, since Grails has already provided this type of code separation at a higher level.

The right reason to create a new package is because you have some specific code functionality that might spread over your application. For example, say you have written a very specific rule engine in your app. You might keep it in /src/groovy/com/company/app/rules/RulesEngine.groovy. This may have a Rule domain object associated with it, and it would go in /grails-app/domain/com/company/app/rules/Rule.groovy. Also, maybe a rule service in /grails-app/services/com/company/app/rules/RuleService.groovy, etc.
I assume that it’s in the best interest of devs to decide on a package naming convention earlier rather than later.

Absolutely. I think the best time to start packaging a Grails app is after you’ve run grails create-domain-class foo. Once you have a paradigm set for your application, making new classes conform to it is not a big deal. I can be royally painful to apply a packaging model as an afterthought.
I haven’t seen many Grails tutorials/intros that deal with this issue. I’m also a n00b when it comes to package naming in Java/Grails projects, so this could be one giant “DUH ” or RTFM” question.

Don’t feel bad, I’ve seen a lot of enterprise java shops do really stupid things with package naming.

How to Use a YouTube Channel For SEO

How to Use a YouTube Channel For SEO

Since its launch and subsequent acquisition by the Google, YouTube has become one of the world’s most popular video sharing site and has also emerged as a second biggest search engine. Today many businesses and individuals realize that by not having a YouTube channel, they are missing out on the potential exposure to millions of people worldwide and possible inquiries and sales that they could generate.

You should not overlook the fact that videos are now part of natural search results offered by Google and by having a YouTube video channel, you can ensure success for your business.

Let’s have a close look at our top tips on Using YouTube Channel for SEO success:

  1. Make quality videos -You need to make quality videos to stand out amongst millions of other videos on YouTube. You should release good videos that are meaningful and should avoid flooding the channel with just short clips that don’t mean anything. You should preferably make general advice and “how to” videos so that your viewers feel that they are learning something from them. Aside from that, videos need to be watchable with decent audio and should be at least 3-4 minutes in length if you are trying to promote some service or product. Any awful video can affect the image of your business, service, and product, so you need to be careful on that count.
  2. Place links to your site or blog -You should place a link in your videos so that people who watch your videos can go to your main website or blog. You can place a link in the video description as this is more convenient for the viewer and can get you tons of traffic.
  3. Request rating – You can request rating at the end of your videos. Once you get ratings, your videos will be found more and can help you get more traffic.
  4. Add tags and descriptions to your video – This will help your videos to be found easily on YouTube, and you will get much more views.
  5. Place YouTube channel on social networking accounts – This will help others in knowing that your video channel exists on YouTube and when you have new videos for them. This is the best way of using YouTube Channel for SEO success.
  6. Interact with comments – You should interact with your comments on the YouTube page. This can get you more comments, and you can also create a following that will come back for discussion.
  7. Subscribe to other YouTube Channels – By subscribing to YouTube channels that are in the same niche as yours, you can increase chances that they might also subscribe back to your channel. Therefore, whenever you release your video, your subscribers will be notified and if they like your video, then all their subscribers and friends could see your video as well.
  8. Research on competitors’ keywords – If you see that your rival YouTube channels are getting more views and traffic, then you should study their tags and keywords. Choose the right keywords to increase the ranking of your videos.
  9. Promote – You should inform people more about your YouTube channel by promoting the logo on emails, website and other types of online marketing that you might do.
  10. Find Friends – YouTube account or channel allows you to make friends just as Twitter allows you to build your fan base that is notified each time you add a new video. Now as friends are public on every channel, you may start picking up extra viewers from the friends of your friends who may see your YouTube channel listed on other people accounts.
5 Steps To More Website Traffic

5 Steps To More Website Traffic

There are a few things people can do when they want to generate a lot of website traffic. Below are five ways that can boost traffic to any website.

Use Social Networking Websites

The first thing a person should do to get more traffic to his website is to use social networking websites. Join at least three social networking websites. Try to build up your profiles and make the profiles represent your website, and then try to get as many people to follow you or become your friend.

The more friends/fans/followers mean that traffic to a website will increase over time. The more a person’s social networking profile grows, the more people who will check out the website the person is promoting. Social networking is one of the best tactics to generate traffic to a website.

Use the Right Keywords

Using appropriate keywords is important when people want to generate much traffic. Using the right keywords on a site can help the site rise to the top of search engines, and this means tons of traffic will come to the site.

You should use a keyword research tool and find out what keywords are being searched for (words relating to their website) and then use some of those keywords when they add content to their site. Every time a person adds content, they should add keywords a few times throughout the content.

Article Marketing

Article marketing is a way to increase traffic to a website fast. Article marketing is when somebody writes an article, includes a link to their website and then distributes the article to many article directories.

A person wants to write a short article about a topic that relates to their website’s content and include keywords throughout the article, including one link to their website and then submit it to at least ten article directories. This will help the website rise to the top of the search engines and get traffic from the article directories themselves.

Build Links

Link building is an excellent method to use to generate traffic to a website. Link building is a technique that involves a person placing their website’s links to other places on the web. The best way to link build is by placing a website’s link on blogs and websites that have related topics.

A person can and should also place their website’s link in website directories or URL directories. Doing this will help a website get to the top page/pages of search engines, and this means that a whole lot of people will find the website when they search for specific keywords.

Video Marketing

Video marketing can do wonders for a website’s traffic. A website owner should create a video that relates to the content of their website. Once the video is done being created, they should submit the video to at least three video sharing websites.

The video should be around three or five minutes, and a new video should be created twice a month. Doing this will help generate a ton of traffic as time goes on.

These are five things that should be done and repeated. Doing these things will undoubtedly increase traffic to any website.

Is Inmotion Hosting Any Different than the Rest?

Is Inmotion Hosting Any Different than the Rest?

InMotion is a web hosting solutions provider that goes beyond most other firms by offering packages ideally suited for setting up e-businesses. Unlike other services providers, however, InMotion offers you the advantage of a company that understands business in general and not just e-businesses.

Being one of the world’s leading web hosting solutions and services providers, they have a roster of high-profile clients from all over the world. You can read here how they aim to provide corporate users and individuals with a variety of web hosting plans that are reliable and easy-to-use, yet offers all the advantages of a state-of-the-art website hosting architecture.

Ordering Domain Names at Inmotion Hosting

Moreover, with a customer support staff that should be a model for responsiveness and knowledge, their clients have ready access to qualified help when they need it the most.

Linux and Unix-based Infrastructure

They offer users the advantage of fast and reliable hosting that remains surprisingly affordable. The company has its network built on fast and reliable Linux– and Unix-based systems. Network facilities are monitored continuously and subjected to benchmark tests that ensure trouble-free performance.

Account Management Panel at Inmotion

No matter what your needs are about web hosting, Inmotion can offer a package that meets your every requirement. With a line of services specifically designed for personal, business, and even government and education applications, they neatly cover the needs of the global market in a way that few other hosting company does.

Max Speed Zones

Customers of this company also benefit from domain name registration and web hosting that stands way above the rest regarding speed, reliability, and cost-effectiveness. In fact, InMotion is one of the few web hosting service providers that can boast of Max Speed Zones.

Not only that, but their feature list also includes:

  • Fast email with SPAM blocking
  • 24x7x365 Support
  • Different levels of hosting so you can grow
  • 90-day money back guarantee
  • Very reliable with 99% Uptime
  • Easy to use control panel and a premium website builder
  • Unlimited disk space and Unlimited monthly traffic
  • Top technical support

Crafted with E-commerce in Mind

Aside from high-quality services, Inmotion Hosting also offers a slew of e-commerce solutions that are perfect for anyone who is looking to make inroads into the world of online business. Since security is one of the critical concerns of anyone who is planning to start up an e-commerce website, the company has taken steps to ensure total safety and data integrity of every client that it serves.

Security at Inmotion

Helpful Staff

Central to the quality of services that InMotion can provide is the highly qualified and helpful staff. The company is well attuned to the needs of every customer that it services, and with a senior staff comprised of professionals with long years of experience in the business, virtually all web hosting needs are addressed to full customer satisfaction.

So with a helpful customer support team that adequately responds to every user concern, they ensure a smooth and trouble-free web hosting solution for every need.

They Draw Inspiration from Customers

One thing that sets InMotion apart from other web host is the equal focus the company places on business and technology. This ensures that the company can provide software, hardware and method-based solutions to every website.

Inmotion Features

A vital aspect of the their business model is providing web hosting plans that adequately addresses the needs of their customers. To achieve this goal, the company fosters healthy business relationships with all clients, placing utmost priority on a thorough understanding of their needs, priorities, and expectations at all times.

Combined with a slew of innovative products and state-of-the-art technology, the company provides users with a variety of web hosting solutions that can indeed make a difference in the way they run their site.

Since the company routinely draws inspiration from suggestions by its customers, they provide a variety of reliable solutions that are built for the customer from the ground up.

40 Ways to Finding Great Blog Topics

40 Ways to Finding Great Blog Topics

For all those who are running out of ideas to write new blog posts, there are ample sources available. All you have to do is look around. I have collected 40 ways of finding great blog topics easily and quickly.

1. Maintain an idea log.

Keep a notebook handy with you whether you are at the airport or a party. Use it to jot down any new idea that comes to you.

2. Use books and magazines.

Move away from your computer and pick up some book or magazine. These are a treasure trove of ideas.

3. Watch the news.

Most of us have stopped watching the news much. Try this out, and you will have a mine full of current topics.

4. Turn your blog into a contest.

Organize some contest in your next blog post. You may give out free movie tickets to the person who comments the most; or to the most relevant comments.

5. Get a guest blogger.

Ask a friend or a new blogger to post a blog. Your audience will enjoy the change.

6. Go out and enjoy life.

There is no need to work too hard for getting a blog. Go out for a movie, or to a museum, or hang out with friends. You never know when a new idea will strike you.

7. Comment on other blogs.

Use your blog post to comment on other people’s blogs. Give your own opinion.

8. Visit social networking sites.

Use these sites to know what people are talking about and get ideas.

9. Visit other blogs.

Check out the blogs of others. Good ideas are contagious. You will get enough material to write your blog.

10. Change your category.

In case you had been writing on food all this time, try to write on travel now. Alternatively, politics, or even economy.

11. Visit your previous blogs.

Check out your previous blogs and find out which ones garnered maximum comments. You may add on to these or perhaps add a new perspective now.

12. Share tips.

You can give tips about any topic. These are easy and fast.

13. Read the comments.

Your readers are your best source of ideas. Check out their comments.

14. Set Google alerts and many other such alerts with some keywords to get stories delivered to you each day.

15. Read newspapers and comment on what you feel will be the next development in the major stories.

16. Go through the local papers.

17. Read the business papers and write on the relevant topics.

18. Watch some TV soaps and write on that.

19. Pick out a popular blog post and give a contradictory viewpoint.

20. Watch a play or something similar.

21. Visit an exhibition.

22. Check out the trade fair.

23. Visit a children’s fair.

24. Visit YouTube.

25. Try to be an Agony Aunt.

26. List out your grudges.

27. Talk about problems your readers may be facing.

28. Give solutions to these problems.

29. Invite solutions from other readers.

30. Ask your friend.

31. Talk to your family.

32. Speak to your child’s friends.

33. Ask any question.

34. Write a letter to anybody.

35. Talk about your memories.

36. Write about your dreams.

37. Write about your regrets.

38. Talk about somebody’s life.

39. Take anybody’s interview.

40. Talk about the future.

Use these 40 ways of finding great blog topics, and you will never run out of ideas.

How To Build A Successful Online Business

How To Build A Successful Online Business

Are you tired of working for someone else? Do you want to start applying your energy towards your success? Answering yes to these two questions means it’s time you discovered how to build a successful online business.

Perhaps you have already tried to make money online. Maybe you even have the product and the website set up. However, that’s it. Now what? This is where lots of folks who try out the online lifestyle make their first, and sometimes the most significant mistake.

They think the product and the website are all they need.

These are the people who decide that everyone who says they have a successful online business must be lying. After all, they aren’t having any success, so it must all be a scam, right?

Wrong. What they forgot is that without customers, you’re not in business. This is something bricks, and mortar stores figure out right away, but for some reason, people think the Internet is different. Well, it’s not.

Planning Means Customers

Let’s go back in time and start planning. This is how you get customers. With customers, you have a business. And if you have a business, you can make money.

You can start off by offering people something for free. People love free. If you’re trying to sell an eBook, why not write a short report that contains some of the jewels that are in the eBook?

Perhaps you don’t want to go the free report route. That’s fine. You still need to start marketing your website. There are many ways to do this, including:

  1. Leaving relevant posts in forums, with your website in your signature
  2. Offering an informative Twitter feed, with occasional links to your site
  3. Starting a fan page on Facebook, where you offer valuable advice and the all-important link back to your website
  4. Writing articles about your niche and submitting them to the reputable article directories

All four of these tactics will get you customers. It takes time and effort, but most things that are worth it do. Work at marketing your website every day and you will begin to see results.

Don’t Get Lazy

This is something that doesn’t always get talked about, but it should. Some people, quite frankly, get lazy. In fact, inherent laziness might be one reason some people turn to the Internet to make money: because they think it’s easy.

Making money online does not take the skill or smarts of a brain surgeon, but you also can’t be lazy. You must be willing to put work into your online endeavor. If you succeed, the results will be more than worth it.

Never Stop Learning

Even if your niche is tiny, new information will still become available. It’s the nature of cyberspace. Never stop learning about your niche or the industry it resides in.

Another excellent technique is to pay attention to the successful marketers out there. That includes copywriters and bloggers as well.

Watch what successful Internet gurus are doing and learn from them. Study their sales pages, their websites and anything else you can find out about them. If you want to know how to build a successful online business, model yourself after those who already have.


Hello world!

Welcome to weblog. There is not much you can read here yet. I plan to update this blog on a regular basis. Since I am a software developer it’s going to be mostly tech stuff.

Check back if you are interested.