Saturday, January 31, 2015

[OSGi][Service] Creating a service and calling it from other bundle

Hi,

We are going to create a service, export it and import in another bundle. If you did not create a simple bundle yet, follow the post [OSGi] Hello World from OSGi | Create your first OSGi Bundle

We are going to create a classic ECHO service. Whatever is given to the service is ECHOed back to us.

After you are done creating a simple bundle HelloFromOSGi. Follow the steps below.

Thursday, January 29, 2015

[Liferay][Tomcat] Permission Denied Errors in Catalina.out

Hi,

I have seen some people struggling with permission errors when running Liferay. Errors like below..


The main cause for these errors is that server was started with a user lets say A having permissions(like root) and then server was stopped and started by a user lets say B with limited permissions. Now entries in temp and several other places are owned by A and when B tries to start/restart server B is unable to access those files and get permission denied errors.

Tuesday, January 27, 2015

[OSGi] Hello World from OSGi | Create your first OSGi Bundle

Hi Friends,

This post will guide you to create a very very simple Hello World bundle using OSGi. We will use Eclipse for this purpose.

Few simple steps to follow.

Step 1. Create a new project in Eclipse. Open New > Project

Sunday, January 25, 2015

[Eclipse] Workbench has not been created yet. Error while creating OSGi modules.

Hi,

It was my first day with OSGi bundles and I got an error.. Workbench has not been created yet. If you have the same error, please follow the steps below to resolve it.

Step 1. Go to MANIFEST.MF and right click on it and then navigate to Run As > Run Configuration.

Friday, January 23, 2015

[Liferay] java.net.UnknownHostException | Unknown Host Exception Liferay

Hi,

I got this exception on a fresh Linux machine. It was clear that Liferay was not able to find the hostname entries properly. Solution was simple. Just needed to add hostname in hosts file. Here is the exception log.

And the solution here.. On linux open /etc/hosts file and make an entry.

> sudo vim /etc/hosts


That's it. Pretty easy. :) Hope this helps someone.