JDev 10.1.3 embedded OC4J:  How to run HTTP in port 80 without conflicts?

Hi
I need to run the HTTP protocol using port 80 in the OC4J embedded version that JDeveloper 10.1.3 brings. I don't want the port to be decided at run time. I'm trying to configure it to use port 80, but I get conflicts and the port reconfigures to another value (1024). I need the port to be 80 in order to be consistent to the production port. (Why? Because I'm using SSLEXT, for those who are familiar with it).
How can I understand the conflictand resolve it? How can I know the conflicting process that demands the port 80?

Only way you can change this is to hack jdeveloper...
in jdev.jar (or jdev-sr.jar if you have service pack) find Oc4jPortConflictUtil.class and replace it with compiled code below.
package oracle.jdevimpl.runner.oc4j;
import java.io.IOException;
import java.io.PrintWriter;
import java.net.ServerSocket;
import java.util.ArrayList;
import java.util.Iterator;
import javax.swing.JOptionPane;
import oracle.bali.ewt.text.MultiLineLabel;
import oracle.bali.ewt.text.WordWrapper;
import oracle.ide.util.IdeUtil;
import oracle.jdeveloper.runner.RunMgrArb;
import oracle.jdeveloper.xml.oc4j.Oc4jConfigAdmin;
final class Oc4jPortConflictUtil
    private final Oc4jConfigAdmin _admin;
    private final PrintWriter _log;
    private static final int HTTP_SOCKET = 0;
    private static final int RMI_SOCKET = 1;
    private static final int JMS_SOCKET = 2;
    private static final int IIOP_SOCKET = 3;
    private static final int IIOP_SSL_SOCKET = 4;
    private final ServerSocket _sockets[] = new ServerSocket[5];
    Oc4jPortConflictUtil(Oc4jConfigAdmin oc4jconfigadmin, PrintWriter printwriter)
        _admin = oc4jconfigadmin;
        _log = printwriter;
    boolean acquirePorts()
        try
            ArrayList portConflicts = new ArrayList();
            _admin.setHttpPort(reservePort(0, _admin.getHttpPort(), 23, portConflicts));
            _admin.setRmiPort(reservePort(1, _admin.getRmiPort(), 24, portConflicts));
            _admin.setJmsPort(reservePort(2, _admin.getJmsPort(), 25, portConflicts));
            int iiopPort = _admin.getIiopPort();
            if(iiopPort > 0)
                _admin.setIiopPort(reservePort(3, iiopPort, 26, portConflicts));
            int iiopSslPort = _admin.getIiopSslPort();
            if(iiopSslPort > 0)
                _admin.setIiopSslPort(reservePort(4, iiopSslPort, 27, portConflicts));
            boolean flag = userAcceptsPorts(portConflicts);
            return flag;
        catch(IOException e)
            e.printStackTrace(_log);
        boolean flag1 = false;
        return flag1;
    void releasePorts()
        int n = _sockets.length;
        for(int i = 0; i < n; i++)
            closeSocket(_sockets);
_sockets[i] = null;
private int reservePort(int index, int portSetting, int runMgrArbMsg, ArrayList portConflicts)
ServerSocket socket = findAvailablePort(portSetting);
int actualPort = socket.getLocalPort();
boolean portReassigned = portSetting != actualPort;
if(portReassigned)
portConflicts.add(RunMgrArb.format(runMgrArbMsg, Integer.toString(actualPort)));
_sockets[index] = socket;
return actualPort;
static ServerSocket findAvailablePort(int port)
if(port < 80 || port > 65535)
port = 80;
do
try
ServerSocket serversocket = new ServerSocket(port);
return serversocket;
catch(IOException e) { }
if(port < 65535)
port++;
else
port = 80;
} while(true);
static void closeSocket(ServerSocket socket)
if(socket != null)
try
socket.close();
catch(IOException e)
e.printStackTrace();
private boolean userAcceptsPorts(ArrayList portConflicts)
throws IOException
if(portConflicts.size() > 0)
for(Iterator iter = portConflicts.iterator(); iter.hasNext(); _log.println(iter.next()));
MultiLineLabel mesg = new MultiLineLabel(WordWrapper.getTextWrapper(), RunMgrArb.getString(28));
int result = JOptionPane.showConfirmDialog(IdeUtil.getMainWindow(), mesg, RunMgrArb.getString(29), 2);
if(result != 0)
releasePorts();
_admin.rollbackChanges();
_log.println(RunMgrArb.getString(30));
log.println(RunMgrArb.format(31, Integer.toString(admin.getHttpPort()), Integer.toString(_admin.getRmiPort()), Integer.toString(_admin.getJmsPort())));
log.println(RunMgrArb.format(32, Integer.toString(admin.getIiopPort()), Integer.toString(_admin.getIiopSslPort())));
return false;
return true;

Similar Messages

  • JDev 10.1.2/Embedded OC4J / JDev generated Library path

    Hello!
    I migrated a JDeveloper 9.0.3.4 - Workspace and Project to JDeveloper 10.1.2.
    My application uses Struts 1.2.4 and Toplink 9.0.3.
    I don't want to migrate Toplink 9.0.3 to Toplink 10G (9.0.4.5) in that moment.
    Running my application on embedded OC4J it uses not my referenced toplink 9.0.3 but toplink 9.0.4.5 library.
    I edited "$JDEV_HOME\jdev\system10.1.2.0.0.1811\oc4j-config\application.xml" file and commented out the toplink library path, but as this entry is "jdev-generated", this entry is regenerated.
    How can i solve this issue?
    Thank you!
    Harald.

    Refer to
    http://www.oracle.com/technology/products/jdev/htdocs/10.1.2.0.0/install.html#migrating

  • How to run eg. 'make' without sudo?

    Hi,
    After upgrading from Snow Lepard to Leo I understood I am not able to run Unix commands in Terminal (eg.'make'). System tells me that there is no 'make' command available. But if I do 'sudo make' - it is there and available.
    So my 'nix environment created and used for years is no longer healthy. How I can return to my previous status when 'sudo' was not necessary? I hate to alter all scripts with 'sudo' or run those with 'sudo' upfront.
    Alex

    In your developer suite, under forms developer you can find a link called "run a form on web"
    open the link
    in form field give the file name with full path
    for instance c:\forms\test_form.fmx
    before running the form you need to compile the same in your forms builder 10g
    give the username/password@connnectionstring in the user id field
    ensure that the web host and web port fileds are filled up with the relevant details.
    if u don't know, run the form from the form builder to get the name of the host and port number
    for instance
    http://server_name:port_num/forms/frmservlet
    here server_name will be replaced by the machine name you work and port will be after the colon (:) sign
    now press the run form button.
    Make sure that oc4j instance is running before you try it
    if oc4j instance is not running, then start the oc4j instance from the form developer link

  • How to run netbeans swing code without netbeans

    hi
    i created a GUI use netbeans and it compiles and runs under netbeans. my question is how can i run it on a machine doesnt have netbeans. i realise that in the netbeans project scr file, there s two .java file, but have no idea how should run it. i tried to do
    javac <GUI class name>.java
    but got lots of erro like this:
    GUI_main.java:545: package org.jdesktop.layout does not exist
    jPanel20Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    how can i do it corectly???
    dav

    Hai,
    u need to search the Classes ur using in netbeans installation directory
    i.e., org.jdesktop.layout some class.
    May i know y ur using org.jdesktop.layout package
    From where u got GroupLayout. Search GroupLayout.class and set the classpath.
    javac -classpath <path of the class files>
    regards,
    RdRose.

  • How to run jpximport utility port OAF project to another PC?

    Dear gurus,
    I have OAF JDev project (OAF Extension) on PC A. I need to be able to load the same OAF extension into a different db instance running jpximport utility on a different PC B. How do I move (port) the project? Looking for any documentation on the subject. Can someone kindly advise.
    Thank you.
    Anatoliy Smirnov

    Please disregard.
    Thank you
    Anatoliy

  • How to run a java program without Java Compiler

    I have a small project and I want share it with my friends but my friend'pc have not
    Java compiler.
    for example, I writen a application like YM, then 2cp can sent,receive messege. My cumputer run as Server, and my frien PC run as client.
    How can my friend run it? or how to create an icon in dektop tu run a java program..??..
    (sorry about my English but U still understand what i mean (:-:)) )

    To run a program you don't need a Java compiler. Just the Java Runtime Engine. That can be downloaded from the Sun website and comes with an installer.
    You could then turn your application into an executable jar file and start it somehow like jar myYM.
    There is also software that packs a Java program into an executable file. I've never used that but one that comes to my mind is JexePack. It's for free if you can live with a copyright message popping up every time you start the program.
    http://www.duckware.com/jexepack/index.html

  • How to run a PLSQL mapping without using OWB Interface

    Hi there, does anybody know how to call a PL/SQL mapping <mapname.main> function without using OWB interface. We will have to create some other mechanism to call those generated mappings....
    Thanks in advance

    Hi Marcelo ,
    You can use the following code at the sql prompt to the run the mapping .
    DECLARE
    RetVal NUMBER;
    P_ENV WB_RT_MAPAUDIT.WB_RT_NAME_VALUES;
    BEGIN
    RetVal := <Mapping Name>.MAIN(P_ENV) ;
    COMMIT;
    END;
    Regards,
    Shashin

  • How to run java exe files without having to install jre

    Hi all i want to run a java application. i already converted the jar file to exe using Launch4j but the problem is that i want to run the application on other computers without having to install jre. please, is this possible and if yes, how can i do that. Thanks alot in advance

    The Launch4J website should explain how to bundle the JRE. I've not really used it myself though. If you can't get it to work you could try the launcher I use:
    http://www.megaupload.com/?d=FYZAVM77
    which comes with instructions. Or:
    http://sourceforge.net/projects/javaround
    Both of which are really easy to use.

  • How to run Java 3D Applet without install java3d

    I've written a java3d applet, and it runs correctly in browser on my computer. Now I want it can be run on other computers which havent' Java3d installed. If the program runs as application, then we can use jnlp and web-start to solve this problem. But what about applet? How can I do it just like the application?
    Pls help me!

    Hello. I read this article too. It sounds interesting but I have some questions. The example is given for win32 and what about other OSs and platforms? Sun provides different libraries for different OS. According to this article it is possible to run applets without previous installation of Java3D and if a user runs Windows 2000, Java3D libraries will be downloaded and installed from the location pointed out by the programmer. But how to do this for all OSs and all platforms and architectures so that if a user doesn't have Java3D installed on his/her computer, might to see the applet in his/her browser? Is it the only way that a programmer needs to include into "loader_singed.jar" all possible libraries for all possible platforms?

  • How to run Pre-Upgrade Check without upgrading License Server

    Hi
    How can I run the 8.8 Pre-Upgrade Check without upgrading to the 8.8 license server?
    The Wizard forces me to upgrade it and if I upgrade it, the current 2007 does not run anymore. I want to check my DB's with the Check before upgrading any components and 2007 needs to stay alive.
    Thanks
    Franz

    Hi Franz,
    I would suggest you to check your DBu2019s in your test environment. Please take a backup of all DBu2019s from your live environment and restore them in your test environment once you will have enough free space.
    Please always test the database upgrade in the test environment before doing it in the production environment.
    For more information regarding Business One installation and upgrades on 8.8 version please refer to the Administrator's Guide 8.8, which can be found on the Documentation Resource Centre on the Portal. http://service.sap.com/smb/sbo/documentation  ->  Documentation Resource Center for Release 8.8 
    See chapters: 3.Installing SAP Business One and 5.Upgrading SAP Business One
    Regards,
    Ladislav Meszaros
    SAP Business One Forum Team

  • How to run a Java program without the command line.

    Is there anyway to create a Java program that runs like most programs do in Windows ,by double clicking on their icons?
    Thanks,
    Vance

    http://www.ej-technologies.com/products/exe4j/overview.html
    Looks kinda cool. Most java-2-exe programs are usually way too expensive and wont work with GUIs and require other dlls/libraries...

  • How to run the variable exit without calling the variable selection screen?

    Hi all
    I have a query with 2 variables 0P_PRQUA (Previous Calendar Quarter (SAP Exit)) and ZCCDAT02.
    ZCCDAT02 is a Key Date variable that is derived based on the last day of the quarter that is entered in 0P_PRQUA. The exit code works correctly when calling up the variable screen and ZCCDAT02 is derived properly.
    The problem is that 0P_PRQUA is set to "Can be changed in query navigation". So if the user changes the value of the quarter the exit is not triggered and the value of ZCCDAT02 does not change.
    Is it possible to trigger the exit or is there another way to do it? Ideas would be appreciated. I am trying to create a Web Template with a Dropbox box for the Quarter.
    Query is written in BW 3.X.
    Regards
    Chami

    Hi guys
    Just to restate the requirement. I want the user to be able to change the value of the variable, WITHOUT calling the variable selection screen.
    I want the user to be able to change the value of the quarter by using a dropdown box from within the web template. Once that is selected I want the value of ZCCDAT02 to be derived from the new value of the quarter.
    Regards
    Chami

  • How to run Firefox OS apps without Simulator

    Sorry, just making sure, but is there a way to run Firefox OS apps in Firefox WITHOUT the Firefox OS Simulator?
    I have the Simulator (I actually have mutliple versions), but I would like to see if there is some way to "trick" Firefox into to thinking that it's Firefox OS so I could just go to the Marketplace and get apps.

    You can install Firefox Marketplace Apps from your Firefox web browser itself! You can just visit the marketplace (https://marketplace.firefox.com/) and start using the apps. But few apps like cut the rope maybe only available on mobile phones (hence you may have to depend on simulator)

  • How to run field point vi without the fieldpoint?

    I'm running LV 7.1.  I'm writing a vi that uses compact fieldpoint modules for DAQ and control.  The system is located in another lab.  I'd really like to be able to work on the vi at my desktop, but of course not having the cFP connected makes that a problem, at least when I try to run the program.
    Is there some sort of "dummy" mode for cFP that will let my system actually run the vi?  The cFP is on a private subnet, so I can't get to it over ethernet (although I guess I could try putting it on the public net).  I could replace all the cFP express vis, I guess, but that would be a real pain to swwitch back and forth.
    Thanks, Rob

    That is correct. There is no way to simulate a FieldPoint device. The suggested workaround should work well for you, however. Create some simulated VIs that perform the same task as the FieldPoint writes and reads (at least in terms of what inputs they accept or outputs they have), and place them in the other case in a Case Structure as the FieldPoint VIs.
    LabVIEW 8 takes these possibilities one step further with Conditional Disable Structures and Diagram Disable Structures. The difference between these two structures and a Case Structure is that code in the disabled cases doesn't even compile. This means you could even have broken wires or broken subVIs inside the disabled case, and you'd still be able to run your program. In the case of this FieldPoint application, you could use a Conditional Disable Structure that automatically polls the target OS type (Windows, Linux, Pharlap ETS, etc) and selectively compiles one case based on the target OS. This would allow you to seamlessly run VIs on your computer and FieldPoint without modifying any code. The other advantage is that the simulated FieldPoint code wouldn't get compiled when you target your real FieldPoint device, so you wouldn't increase your code size or memory usage unnecessarily for the final product.
    Message Edited by Jarrod S. on 04-24-2006 03:51 PM
    Jarrod S.
    National Instruments

  • How to run java on computer without java from flash drive

    Im running a chess club at school and the school computers, you aren't allowed to install on the hard drive.
    Is there a way to put an ide and the java folder containing the jre and jdk on a flashdrive and run the ide and run programs solely from the lfashdrive?

    Yes. put the JDK (not the separate JRE) on the flash drive. The JDK contains a JRE.
    Plug the flashdrive into a computer you control. If that computer already has the desired JDK installed, copy the JDK directory (all of it) to the flash drive. Otherwise, do an install of the JDK to the flash drive.
    To run Java application programs use a command that provides the full path to the java.exe program, for instance (in Windows)
    *<drive letter>:\<some directories>java <the name of your program>*
    You could create a bat file to make this easier to type.
    You can't run applets or anything else that depends on Registry entries.

Maybe you are looking for

  • ITunes won't let me update or restore my iPhone.

    So, I got my new iPhone 4S (16GB, Unlocked) yesterday for Boxing Day (hooray!) and since that morning, I've been trying to set it up. Before I bough it, I was using my SIM Card with another phone, and so I had to 'convert' it to MicroSIM, since that'

  • How to use PS+FI WBS Elements?

    Hi Friends... follow the example, There is an account called Printing and stationary in which we will account all the expenses relating to printing, and stationary. Printing may be printing of legal documents, or printing of accdounts mannual, or pri

  • Transfer Order Printing using smart forms

    Hi All Our requirement is to print Transfer Order  ( WM ) for Goods Receipt & Delivery using Smart forms. Can we change the existing standard format (SAP script ) and use our own form(smart form ) to include some other data & print. If possible how t

  • Workspace- login and password

    Hi I am having problems logging onto workspace and reporting studio..I have got 9.3.1 version installed on my laptop..Shared services is working properly.. I had been using the same "admin" and "password" for all of them..But, now a days, when I try

  • Static file with application: deleted on app install/upgrade (bug?)

    Hi, say we have an app (app_id: 100) with abcd.js static file associated with this application (so this is not a workspace static file). Export this app, then import back plus install to the same workspace but on a different and existing application