Single instance app with native packaging

Is there any way to allow only one instance of the app to run with javafx2 native packaging? Like an attribute in the build.xml or something?
I'm using the .exe for windows and the .dmg for mac.
Appreciate your help.

There is no simple deployment build switch that I know of for achieving a single instance app.
A couple of ideas (none of which I have tried).
Perhaps you could use the SingleInstanceService:
http://www.oracle.com/technetwork/articles/java/fxbest-1583679.html "Ensuring Only One Instance of the Application Is Started"
http://docs.oracle.com/javase/7/docs/technotes/guides/javaws/developersguide/examples.html#SingleInstanceService "SingleInstanceService"
It is a jnlp api based service though and I'm not sure if such a service would be available to a packaged app (maybe it would require including the jre/lib/javaws.jar file with your app or something like that).
You could write out a lock file when the app starts.
On unix (i.e. mac/linux) the lock could include the process pid for your app. On startup, check if there is a process with the lock pid currently running, if so, don't startup and perhaps send an interrupt signal to the existing app notifying it that the user tried to start a new instance.
On windows you could read and write the lock value value from the registry.
To get rid of the OS specific stuff surrounding this, perhaps this kind of lock logic could be implemented using the Java Preferences API:
http://docs.oracle.com/javase/7/docs/technotes/guides/preferences/index.html
Intellij Idea is open source and and seems to have this kind of functionality, so you could check how they do it.

Similar Messages

  • I've a Single Folio app with 1526 articles. Its there a maximum number for articles per Folio?

    Helo! I've created a Single Folio app with 1526 articles.
    It works in the generic Adobe Content Viewer, but does not work on my custom App.
    It shutdowns after splash window.
    Could someone help me?
    Elismar

    Changing settings? What part of setting?
    My guess is that if you have so many articles, and each article need some particular files in the .folio file, then the Viewer make a mistake trying load all files in the same moment, causing auto shutdown. And, I'm using the iPad 3 to test it.
    So, would be fine if someone could give me numbers about the maximum number of articles suggested to put in a Folio Issue.
    And yes, I'm publishing the Bible!
    Elismar

  • 11.2 Single Instance DB with ASM

    DB version:11.2.0.2
    OS : RHEL 5
    I want to create a single instance DB with ASM. I did a software only installation . In DBCA , i can't find an option to create Diskgroup through UI like we have in 10.2's DBCA. I will have to use ASMCA for this. But i think i'll have to install Grid Infrastructure for this. Is there alternative way of creating diskgroup through UI ?

    Hi
    I want to create a single instance DB with ASM. I did a software only installation . In DBCA , i can't find an option to create Diskgroup through UI like we have in 10.2's DBCA. I will have to use ASMCA for this. But i think i'll have to install Grid Infrastructure for this. Is there alternative way of creating diskgroup through UI ?You need to install first Grid Infrastructure with sotware only option to can use ASM
    Than you need to use asmca to create asm diskgroup
    Than you need to use install Oracle 11gR2 software only,than you can use dbca
    Regard
    Helios

  • Publishing air apps with native extension with Flash CS6 on Windows

    Hi all,
    is there any trick to publish air apps with Flash CS6 on Windows?
    I tried all native extensions from devnet, but nothing work to me.
    I read on Mac is possibility to specify the iOS SDK folder in publish
    settings, but on Windows it´s missing. 
    Is there anybody who has some experiences with publishing apps
    with native extensions for iOS and Android with windows Flash CS6?
    Thanks for all advices.

    I sympathize. I recently found a native alert for iOS and Android that's working with Flash CS6 on Windows with AIR 3.2.0.2070 but not AIR 3.2.0.2060. You can get the ANE here:
    http://www.jampot.ie/ane/
    Haven't tried the other ones. Let us know if you decide to try them.
    The sample code they have on the page doesn't work with the native alert. Here's the code I created - it's a document class for a .fla that has one dynamic TextField and one Button component on the stage :
    http://pastebin.com/DsxR9nJ4

  • Oracle single instance installation  with RHEL Cluster suite

    Hi ,
    Can anyone help regarding Oracle single instance installation with RHEL Cluster suite? I have to know what factor need to be considered for RHEL Cluster configuration for Oracle Installation. And is it certified by Oracle?
    Aungshu

    Does any body like to share their experience ?

  • Single-folio apps with Pro subscription

    Hello,
    Are there any limitations for publishing single-folio apps using Pro subscription? Can I publish unlimited number of single-folio apps then? If no, what could it cost?
    Thanks a lot!

    You can create an unlimited number of apps with a Pro subscription.

  • Can you create a single edition app with CC Enterprise?

    My company have Creative Cloud Enterprise edition and I would like to create a simple single edition app. It's going to be a one off free app and I have no requirement for all the bells and whistles that Enterprise offers plus with it being free it would cost me because of the $0.30 per download fee. Does anyone know if this can be done or am I going to have to start looking at alternatives?

    You could sign up for the full version of Creative Cloud which will enable you to build a Single Edition app before that support is removed from Creative Cloud on May 1st. You'd create a new app in InDesign using the Create App menu item in Folio Builder Panel. After you create the app and submit it you could then cancel your Creative Cloud subscription.
    Note that you would need to get support to help you set the version number of your new app high enough to replace your existing app in iTunes. If you plan to go the CC route let me know and I can assist in making sure the version number is updated on your app appropriately.
    Neil

  • Update an Single edition app with different (pro) account

    Hello,
    I have question regarding updating SE apps.
    1. From what I understand you can still create single edition apps for ipads after May 1st with a pro account, correct?
    2. If I create an app now, with my CC account, can I later, after May 1st, create a professional account under a different name (company name, not mine) and update my old app? (assuming that my apple account and certificates stays the same)
    Thank you
    Alex

    1. Yes.
    2. Yes.
    Neil

  • How to specify a single instance app?

    Hi
    I've got an app that sets itself up as a menuitem app (using LSUIElement). However I only want a single instance of this app to ever run (even if the bundle is copied to a different location and launched). How does one force mac apps to run as single instance? Any help would be appreciated! Thanks.

    Have you tried setting LSMultipleInstancesProhibited in Info.plist? This key is usually used to prevent the app from launching in another user's session, but I think it also prevents multiple instances in the same session.
    \- Ray

  • Single folio app with DPS PRO

    I have a dps Pro account.
    I would like to create a single folio app for iOS( iPad-iphone) and android devices that it will be free of charge.
    i know that single folio app can be created for iOS and in that case there is charge for folio fulfillment.Is that correct?
    For android version can i create a single folio app?As i have see i think that this is not possible.Is that correct?In that case is there anything else that i could do?For example if i create a multi folio app and i upload only one folio will this work?In that case does the charge for folio fulfillment exist?

    Single edition apps are iPad only and do not incur a download charge. For Android you need to create a multifolio app even if it will contain only a single folio.

  • Launch App with Native Process

    Hi,
    I want to launch serproxy application (http://www.lspace.nildram.co.uk/freeware.html) using native process in adobe air. But it seems not working.
    Here is my code:
    protected function launchSerproxy():void{
        if(NativeProcess.isSupported){
         var serproxy:File = File.applicationDirectory;
         serproxy = serproxy.resolvePath("serproxy/serproxy.exe");
         var nativeProcessStartupInfo:NativeProcessStartupInfo = new NativeProcessStartupInfo();
         nativeProcessStartupInfo.executable = serproxy;
         var process:NativeProcess = new NativeProcess();
         process.start(nativeProcessStartupInfo);
         // connect to the com port
         setTimeout(connect,1500,"127.0.0.1",5339);
    Flex did not return any error or problem on runtime. What should I do to have Adobe Air load and run serproxy? Thanks.

    I think you just missing the working directory.
    "nativeProcessStartupInfo.workingDirectory = File.applicationDirectory;"

  • CREATE SINGLE INSTANCE DBCA WITH ASM GET ERRO "The netwok adapter cold not

    Hi all,
    Im try to create single instacne im ASM, but get erro when i need to put password of SYS from ASM.
    The erro is:
    "Cannot verify passord
    Ioexception: The network adapter cold not establish the connection"
    But my ASm are OK and all disk appear fine. I have to HOMES ORA_ASM_HOME and ORACLE_HOME.
    Usind DBCA from ORACLE_HOME.
    Tks,
    Elber

    Hi all,
    Im try to create single instacne im ASM, but get erro when i need to put password of SYS from ASM.
    The erro is:
    "Cannot verify passord
    Ioexception: The network adapter cold not establish the connection"
    But my ASm are OK and all disk appear fine. I have to HOMES ORA_ASM_HOME and ORACLE_HOME.
    Usind DBCA from ORACLE_HOME.
    Tks,
    Elber

  • Native package for Mac and relative path

    Hi,
    I done a small application with Javafx that start an Embedded Jetty. All works fine in Windows also with native package. Instead in Mac it works only before native packaging. Seems that the problem is how relative path are considered.
    The tree of the content is this:
    myfile.jar
    webapp (folder)
    libs (folder)
    Look at this code:
                    String webAppDir = "webapp";
                    File f = new File(webAppDir);
                    log.debug("Path webapp folder: " + f.getAbsolutePath());
                    if (!f.exists())
                        throw new Exception("The folder " + f.getAbsolutePath() + " doesn't exist");
                    if (!f.canRead())
                WebAppContext context = new WebAppContext();
                context.setContextPath("/myapp");
                context.setResourceBase("webapp");
                context.setDescriptor("WEB-INF" + File.separator + "web.xml");
                context.setSessionHandler(new SessionHandler(sessionManager));
                        throw new Exception("La cartella " + f.getAbsolutePath() + " non è leggibile");
    The problem is that before the packaging in Mac the relative path is that where the main .jar is located an so the code works because the webapp folder is found. Instead after the bundle the path became /Users/MyUser/webapp and of course the folder is not found because it is bundled inside the file.app near the libs folder.
    Someone can explain me if this behaviour is due to JavaFx packager and how I can solve the problem in a elegant way?
    Thanks very much

    Some good soul has any idea?
    Thanks

  • Single Edition Licence with Creative Cloud

    Do you have to subscribe to the full version (all apps) of creative cloud to be able to publish single edition apps with DPS? Or will a single app subscription to InDesign allow you to publish unlimited SE apps too?
    Thanks

    Thanks for the reply Himanshu, that is a great help.
    So can I just clarify.  I can publish unlimited different apps from different folio files to the app store as a cc member.
    I got confused with the below comment i found on Adobe's site:
    Adobe via email that will allow you to submit one single-.folio file to Apple's iTunes App Store for publication.

  • Create and activate app with separate Adobe ID

    Before Adobe offered unlimited Single Editions in my Creative Cloud subscription I created a separate Adobe ID for every single app I was creating. I shared the login/password with my clients so they could track progression and finally approve the app. In the end I purchased a Single Edition licence and activated the app to submit to the App Store. Everything within one Adobe ID.
    Now it seems I can only activate an app (with a built-in serial number) when I've created the folio with my personal (paid) Adobe ID?
    Any suggestions for a nice workflow? Ofcourse I don't want to share my personal Adobe ID, but I do want to share the folios I'm creating. If possible I don't want my clients need to sign up for an Adobe ID themselve.

    I'm not sure I understand why you did that. There was nothing to keep you from creating everything with one ID and then creating the Single Edition apps with the same one. From there, just supply the distribution and developer apps to the client for submission to Apple using their developer accounts.
    They would need Adobe IDs in order to share folios via the ACV but nothing else, really.
    Bob

Maybe you are looking for

  • Envy 15 - No audio able to be heard, despite volume mixer showing activity.

    I have a HP ENVY 15 Notebook PC (LW897AV), running Windows 7 Home Premium 64-bit Service Pack 1.  It is only a little over a year old as I got it in June 2012, so is still under warranty.  Obviously I'd rather not send it back in if I don't have to. 

  • External hard drive not visible in Finder or Disk Utility

    Hi everyone, My Wester Digital 2TB external hard drive has disappeared, so to speak, with all my photos. I work as a freelance photographer. Mostly on Lightroom 5.6 When I plug it in, with firewire, I can feel the disk rotating normally however it do

  • Object Expected Errors in IE 6/ 7

    www.crystalhoyt.com Error messages on every page relative to the navigation bar. Says that an object is expected, char 1. I can't figure out what is "missing" because I made the navigation bar with the Dreamweaver Menu Tool. Please advise.

  • Why no sound out of front headset port of MSI 975 MOBO?

    A friend of mine has an MSI 975x motherboard and hooked up his cases molded front audio connector to the MOBO on JAUD1. There is only one way to connect the connector since one pin hold is filled in (no hole there). While he gets sound out of the spe

  • Smartview causing Excel to randomly crash

    We have recently installed Hyperion Smartview 9.3.1.2 for a number of users who are now experiencing random crashes in Excel. they are not using Smartview at the time but this has only started happening since Smartview was installed and enabled. Disa