Thursday, March 10, 2011

How to solve "Port Conflict Detected"

Sometimes while starting Integrated weblogic Server from Jdeveloper11g we encounter the error as :



One solution for this issue is to log out from the system and login again, which i have seen many developer follow.

To solve this issue go to Task manager and locate all Java related instances.
In my case when i earlier closed Jdeveloper without stopping Weblogic server, this Java.exe kept on running.
so this is creating conflict while again starting the weblogic server.
select Java.exe and end the process.



Now start the Integrated Weblogic Server as:



It will start successfully.






I have reproduced this error by directly colsing Jdeveloper without stopping Integrated Weblogic Console:






BEA WebLogic 7 Server Administration









Sunday, March 6, 2011

Steps to create Login Page in ADF11g

I was following Andrejus's blog to create a login page in ADF 11g. and i successfully created it in Jdev11.1.1.3.
but the issue came when i tried to create the Login Page in Jdev11.1.1.4.
In this blog i will explain the issue i faced while creating Login page in Jdev11.1.1.4 and how to solve that issue.

when we will follow the steps of Jdev11.1.1.3 then on running the Application the login.jspx page will never come up and there will be no error on the Log files. we will end up with a screen like:



Though everything seems to be fine and same as that of Jdev11.1.1.3 there is one improvement made in Jdev11.1.1.4.
As explained in Andrejus's blog that in Jdev11.1.1.3 we need to explicitly grant anonymous-role permission to the login page.
In Jdev11.1.1.4 whenever a login page is created it is automatically granted the anonymous-role permission.
so when we open the jazan-data.xml and go to Resource Grants tab we will see that it is automatically  granted

but actually when we open the jadan-data.xml file and click on the "+" sign on Granted To Role column for login page we will see that we are still getting anonymous-role option

so in the jazan-data.xml it is appearing that it already has public permission but for Add Grantee it is still giving option to add anonymous-role.
so this was causing the problem.
for me it seems as in Jdev11.1.1.3 Login page was not public by default, so in Jdev11.1.1.1.4 it has been made public by default. but in the backend it is still not updated for our application.

so to solve this issue after configuring the ADF Security go to the source of jazan-data.xml and delete all the code from there.
come back to the overview tab of jadan-data.xml.
now you will see that the automatic grant to anonymous-role for Login page has dissapered and on clicking the "+" sign we are getting only 1 option of anonymous-role.

Now follow the same steps to add Application roles and grant Resources.
now when you will run the code you will get the Login screen.:)