Useful examples of best practices of coding in large programs

Hi, ive been writing code for a dozen years now. A good piece on labview know now lmao! But want to get acquainted with code practices, for example by creating programs, code templates, avoiding race conditions, use multiple loops and be able to write code to clients as an entrepreneur. Someone help me?

Stu

Learn more about thelargeapp community and this KB article

Tags: NI Software

Similar Questions

  • Design by using NetApp's best practices

    I am preparing for my VCP5 and I read the new book by Scott Lowe. the book describes how the traffic should be isolated. your vMotion, vmkernal, etc., but in many organizations, I see the NetApp with some of data warehouses and a few LUNS to CIFS share LUNS. I guess you can have your vmMotion on a VLAN separated, but would not safer just configure a windows VM file server to host your files? In freenas and openfiler forums, they stress is not to run their software in virtual machines in a production environment.   Physical separation would be better then just a VLAN? I was inking and correct me if I'm wrong. I think the CIFS shares in a virtual hosting machine would SAN, vMotion, vmkernal, most reliable if you have redundant switches on both sides VMware hosts. So if your kernel switches drop your vmware environment will not drop.

    > traffic must be isolated.

    Yes, the network traffic must be split on networks separated for various reasons, including performance and safety.

    > NetApps with MON a few for data warehouses and a few LUNS to CIFS share.

    Yes, if you have a NetApp file server you can block-level storage server as FCP or iSCSI, CIFS or NFS file-level storage.

    > I guess you can have your vmMotion on a VLAN separated, but would not safer just configure a windows VM file server to host your files?

    OK, you lost me.  Yes, you must separate the vMotion traffic to enhance the performance and because the vMotion traffic is not encrypted.

    I don't see where you're going for vMotion to a Windows file server?

    However, if you are referring to, why don't you your NetApp instead of Windows CIFS Server:

    You don't need to patch and reboot the NetApp at least once a month.

    Performance is better

    You don't need to buy a Windows license and then maintain Windows

    Snapshots.  NetApp has the best shots in the business.  When your Windows I/O high, or just typing box because it of Tuesday and removes all of your VSS snapshots you really wish you had a NetApp.

    > In the forums of freenas and openfiler, they stress is not to run their software in virtual machines in a production environment.

    Note that there are a ton of storage there equipment running as VMs and server NFS for shared storage, including left and they have been stable for years.

    > Physical separation would be better then just a VLAN?

    Yes, if you have the infrastructure.  When it comes to the first time I've seen reference you VLAN?  Are you talking about now the NetApp as the series 2020 with two network cards where you need to carry all traffic (managent, CIFS and iSCSI) through them via VLAN?

    Like this: http://sostechblog.com/2012/01/08/netapp-fas2xxx-fas3xxx-2-nic-ethernet-scheme/

    > I was inking and correct me if I'm wrong. I think the CIFS shares in a virtual hosting machine would SAN, vMotion, vmkernal, most reliable

    CIFS is nothting to do with SAN, vMotion or VMkernel.  CIFS (SMB) is the protocol used mainly by Windows file sharing

    > If you have redundant switches on both sides of the VMware hosts. So if your kernel switches drop your vmware environment will not drop.

    You always want to redundant switches.  No single point of failure is the best practice.

  • Best practice? Storage of large data sets.

    I'm programming a Client to access the customer address information. The data are delivered on a MSSQL Server by a Web service.

    What is the best practice to link these data namely ListFields? String tables? Or an XML file with is analyzed?

    Any ideas?

    Thank you, hhessel

    These debates come from time to time. The big question is how normally geet she on the phone after

    someone asks why BB does not support databases. It is there no magic here - it depends on what you do with

    the data. Regarding the General considerations, see j2me on sun.com or jvm issues more generally. We are all

    should get a reference of material BB too LOL...

    If you really have a lot of data, there are libraries of zip and I often use my own patterns of "compression".

    I personally go with simple types in the store persistent and built my own b-tree indexing system

    which is also j2se virtue persistable and even testable. For strings, we'll store me repeated prefixes

    that only once even though I finally gave up their storage as only Aspire. So if I have hundreds of channels that start "http://www.pinkcat-REC".

    I don't store this time. Before you think of overload by chaining these, who gets picked up

    the indexes that you use to find the channel anyway (so of course you have to time to concatenate pieces)

    back together, but the index needs particular airspace is low).

  • HP FlexFabric use case VMWare best practices

    Hi all.

    I'm trying to validate some configurations in a particular environment.  ESXi 5.5 - vDS - Enterprise Plus Licensing, Chasis C7000, with BL460 G7s - regarding the ETH networking to ESXI hosts.  Fiber Channel is healthy.

    Basically, each chassis have an uplink of 10 GB for the central office switch in each module HP Flexfabric VC.  All the VLANS are the these and the VLAN apply are set up in the HP Virtual Connect.  My questions are on the side of VMware for the most part.  Essentially, each host is presented with 2 cards of 10 GB with the permission of HP FlexFabric configurations.  The last admin setup a distributed virtual switch, broke with the VDPG there is, all VLAN tagging looks them good so far.  All VDPG are installed in / assets without consolidation and failover on any of them.  Also on one of the VDPG, it is configured for management and vmotion, so 1 VLAN for management and vMotion (I know if is not recommended) and on the same subnet.  I've read can cause problems (on FrankDennemans blog of Vmotion traffic on VMK0).  Then watching the hosts (adapters VMKernel) we activated Vmotion and the other active management traffic.  No. NIOC is also setup anywhere in this environment.

    I could see why the legacy admin would separate the vmotion and separate management VMK cards to avoid saturating the links over the DRS or vMotions, but it clearly resembles a single point of failure (if a module fails).  I looked for hours today White HP books and documents, and nothing that clearly.  I want to break the vMotion and management on the VLANS separated, but do not know if I have to create 2 more NIC in the virtual connection and use them for vmotion (active / standby) x 2 and use the NIOC - or if I can modify it somehow the above configuration and then select the NIOC.

    I read a lot of articles about this and I'm just trying to eliminate any SPOF and stay in good practices, any help you could offer would be great.  Sorry if I missed any information.

    I could see why the legacy admin would separate the vmotion and separate management VMK cards to avoid saturating the links over the DRS or vMotions, but it clearly resembles a single point of failure (if a module fails).  I looked for hours today White HP books and documents, and nothing that clearly.  I want to break the vMotion and management on the VLANS separated, but do not know if I have to create 2 more NIC in the virtual connection and use them for vmotion (active / standby) x 2 and use the NIOC - or if I can modify it somehow the above configuration and then select the NIOC.

    Vmkernel interface does not represent a single point of failure, as long as the port group underlying is implemented for several cards network with active links or pending. If assets vmnic fails, the vmk will move to the next active vmnic or, failing that, select a vmnic Eve.

    As long as you have one or more of each module FlexFabric VMNIC, you get to a high availability solution. If the module fails, or the uplinks on the power supply fail, underlying vmnic poster link to the low status and the hypervisor interface will act accordingly.

  • Best practices for moving a large virtual disk to one Windows Server VM to another?

    Environment
    3 blades HP BL460 G1 using an EMC NX4 for shared storage in a cluster of ESXi 4.1 vSphere

    Description
    We have currently two file Windows Server 2003 important server upgrade to Windows server 2008 R2. Both have a thick secondary virtual disc service that is used exclusively for the file service. The first disc of the virtual secondary server is 500 GB and the second is 1.4 TB. I currently do not have space on our SAN to bring up two new virtual machines with the same storage requirements. What I thought to do is raise two new W2K8R2 VM then disconnect the secondary readers of the VM-W2K3 and reconnect them to the W2K82 virtual machine. I guess that the process would be done like this:

    1. Cancel sharing all files and remove the secondary hard drives in Windows on both machines virtual W2K3
    2. Close W2K3 VM down and remove only secondary hard drives in vSphere
    3. Move the secondary vmdk file of each W2k3 VM file in the folder of the virtual of W2k8R2 machine that will replace
    4. Attach the respective secondary virtual drive to each VM W2K8R2. Check that it appears in the BONE of the VM and file data and authorization are intact
    5. Power on the VM-W2K3, rename and delete the domain. When finished, turn off the two
    6. Rename the two W2K8R2 VM to match name W2K3 VM they replaced, then restart the name change to
    7. After the restart to recreate and test access to folders shared

    This sounds like the right way to go on this kind of upgrade? Y at - it a simpler way or a step I'm missing? Thanks in advance!

    The process seems good. I guess these separate the VMDK disk data is NOT stored with the correct current VM? It seems that you are saying that they are simply located on the separate volumes, if that's the case, then Yes, this process won't work.

    The only piece that CAN be useful for you, I don't know how much stock windows you have on this volume of data (by the sounds of the size probably a little) you can export only the actions of lanman of the original registry settings host and import this registry key on the new virtual machine. Just make sure you MERGE them, and disk locations are the same. This is several times this way and worked perfectly. Much easier, and then re-create shares permissions and all that.

    Hope it's of help.

    Jonathan

  • What is the best practice to only uninstall certain programs CS4 (Win 7 PC)

    I recently updated for CS4 to CS5.5 and wanted free space hard disk on my Windows 7 PC. I wanted to uninstall only a few programs but CS4, such as Photoshop, Illustrator, Flash and bridge. What is the best way to do this without forgetting approval, deactivation, and removal of components? I have the original installation disc for CS4 if necessary. Thanks for any help!

    I will give you the ability to disable all run through the uninstall process.  Simply go to start > control panels > programs & features.  You can find Adobe's CS4 and select uninstall it or remove the option.  Then follow through the guests.

  • Best practices for the application of page multi Landscape/Portrait

    Hello
    I am looking for information on track to develop auto guide demand in pure actionscript with new components of qnx.fuse, but there is not a good example in real code. Every time I tried to make it resizable layout to get deformated fluid only components in portrait or landscape mode.

    I have a simple application with the point main and 3 displays:

    public class Main extends NavigatorSprite
    {
        public function Main()
        {
            addEventListener(Event.ADDED_TO_STAGE, init); 
    
            stage.nativeWindow.visible = true;
            stage.scaleMode = StageScaleMode.NO_SCALE;
            stage.align = StageAlign.TOP_LEFT;
            stage.nativeWindow.activate();
        }
        private function init(e:Event):void
        {
            removeEventListener(Event.ADDED_TO_STAGE, init);
            navigator.pushView(View1);
        }
    }
    
    public class View1 extends ViewSprite
    {
    
        private var container:Container;
        private var button_two:LabelButton;
        private var button_three:LabelButton;
    
        public function View1
        {
            addEventListener(Event.ADDED_TO_STAGE, init);
        }
    
        private function init(e:Event):void
        {
            removeEventListener(Event.ADDED_TO_STAGE, init);
    
            container = new Container();
            var layout:RowLayout = new RowLayout();
            container.layout = layout;
    
            button_two = new LabelButton();
            button_two.label = "to page 2";
            button_two.width = 150;
            button_two.height = 45;
            button_two.addEventListener(MouseEvent.CLICK, handleTwoClicked);
            container.addChild(button_two);
    
            button_three = new LabelButton();
            button_three.label = "to page 3";
            button_three.width = 150;
            button_three.height = 45;
            button_three.addEventListener(MouseEvent.CLICK, handleThreeClicked);
            container.addChild(button_three);
    
            addChild(container);
        } 
    
        private function handleTwoClicked(e:Event):void
        {
            navigator.pushView(View2);
        }
    
        private function handleThreeClicked(e:Event):void
        {
            navigator.pushView(View3);
        }
    }
    
    public class View2 extends ViewSprite
    {
    
        private var container:Container;
        private var back:BackButton;
    
        public function View2
        {
            addEventListener(Event.ADDED_TO_STAGE, init);
        }
    
        private function init(e:Event):void
        {
            removeEventListener(Event.ADDED_TO_STAGE, init);
    
            container = new Container();
            var layout:RowLayout = new RowLayout();
            container.layout = layout;
    
            back = new BackButton();
            back.label = "Back";
            back.width = 100;
            back.height = 45;
            back.addEventListener(MouseEvent.CLICK, goBack);
            container.addChild(back);
    
            addChild(container);
        } 
    
        private function goBack(e:Event):void
        {
            navigator.popView();
        }
    }
    
    public class View3 extends ViewSprite
    {
    
        private var container:Container;
        private var back:BackButton;
    
        public function View3
        {
            addEventListener(Event.ADDED_TO_STAGE, init);
        }
    
        private function init(e:Event):void
        {
            removeEventListener(Event.ADDED_TO_STAGE, init);
    
            container = new Container();
            var layout:RowLayout = new RowLayout();
            container.layout = layout;
    
            back = new BackButton();
            back.label = "Back";
            back.width = 100;
            back.height = 45;
            back.addEventListener(MouseEvent.CLICK, goBack);
            container.addChild(back);
    
            addChild(container);
        } 
    
        private function goBack(e:Event):void
        {
            navigator.popView();
        }
    }
    

    Is there for example some best practices how to modify this code to have pages and components with the same sizes in portrait and landscape? On presentation buttons size always 150 width and height 45 and wil containers have stageWidth and stageHeight.

    Thank you if someone could help with this problem

    Hello

    Try listening to a shift in focus screen with this code:

    stage.addEventListener(Event.RESIZE, onResizeHandler, false, 0, true);
    

    You can only change the width/height of your components to the event based on the width/height of the floor.

    I will guard against specifying specific sizes, if you want your code to work on devices BB10. I recommend using %'s.

    Kind regards

    Dustin

  • OEM 12 c Best Practice follow-up 11.1 DB RAC env. + datagurd

    OEM 12 c 5 release is the only monitoring in our environment... is there a better model of practice on what aspects need to be monitored and their default values?

    This doc for 12 c DB is very useful, it's best practices for high availability. They talk a lot about the RAC/DG monitoring.  https://docs.Oracle.com/database/121/HABPT/monitor.htm#HABPT003

    version 11.2 is here https://docs.oracle.com/cd/E11882_01/server.112/e10803/monitor.htm#g1011041, I read them both though, as there are some new features in version 12 c who may still apply to 11 g.

    Regarding the parameters/models go, if you create a template of the target type (monitoring sc_results.php-> create-select target type-> type > select category/target), this will include all the parameters of the type of target (including the CEO) and as close as you'll have to 'default thresholds' Oracle.  It is the best branch of the teams effort produced.   Of course, they will not be perfect for everyone, but it's a starting point!

  • vSpere 5 Networking of best practices for the use of 4 to 1 GB NIC?

    Hello

    I'm looking for a networking of best practices for the use of 4-1 GB NIC with vSphere 5. I know there are a lot of good practice using 10 GB, but our current config does support only 1 GB. I need to include the management, vMotion, Virtual Machine (VM) and iSCSi. If there are others you would recommend, please let me know.

    I found a diagram that resembles what I need, but it's for 10 GB. I think it works...

    vSphere 5 - 10GbE SegmentedNetworks Ent Design v0_4.jpg(I had this pattern HERE - rights go to Paul Kelly)

    My next question is how much of a traffic load is each object take through the network, percentage wise?

    For example, 'Management' is very small and the only time where it is in use is during the installation of the agent. Then it uses 70%.

    I need the percentage of bandwidth, if possible.

    If anyone out there can help me, that would be so awesome.

    Thank you!

    -Erich

    Without knowing your environment, it would be impossible to give you an idea of the uses of bandwidth.

    That said if you had about 10-15 virtual machines per host with this configuration, you should be fine.

    Sent from my iPhone

  • Best practices for the use of reserved words

    Hello
    What is the best practice for the use of the reserved words as column names.
    For example if I insisted on the use of the word to a column name comment as follows:

    CREATE TABLE...
    VARCHAR2 (4000) "COMMENT."
    ...

    What is the impact on the track I could expect and what problems should I be informed when doing something like that?

    Thank you
    Ben

    The best practice is NOT to use reserved words anywhere.
    Developers are human beings human. Humans have their moments to forget things.
    They will not forget to use the "", or you can force it to use the "' everywhere.
    The two methods are Oracle certified ways to end up in hell.

    ----------
    Sybrand Bakker
    Senior Oracle DBA

  • Best practices using clusters to create the queue/notifier/bundles?

    I'm in a block diagram, a queue, the notifier and several instances of cluster of bundle

    that all use the same data structure.   There is a typedef of cluster for the data structure.

    Of course, each of these objects (define the queue, set notifier, bundle)

    you want to know how do you define the cluster.

    What is considered best practices?

    (1) create a dummy instance of the cluster across data structure

    definition is necessary (and hide all on the public Service)

    (2) create only one instance and son at all places, it is necessary

    But there is no stream on this thread: it's only the cluster * definition *.

    which is used, so this seems to clutter the comic.

    (3) create only one instance of the cluster control and use local variables

    everywhere else the definition of cluster is required.  It's _value_ is never

    assigned or given read-so no problem with race conditions.

    (4) another way?

    If you were to clean up someone else's code, how do you expect

    See this Treaty?

    It occurred to me during this writing that here where I

    "unbundle...... code bundle" I could wire the original beam to the

    the two "unbundle" and "bundle" - but that would be too complicated

    and the size of the comics with useless thread?

    Thank you and best regards,

    -- J.

    Hi Jeff,

    I think that this question is about "sharing" the typedef and not how share data (?)  If the cluster control is registered as a typedef (or a strict typedef) but NOT SIMPLY as a CONTROL, then when a Diagram-constant of the typedef is created, it will be updated when you update the .ctl typedef!  (and there is no FP control to hide )  Of course if the typdef is already available "close" if necessary, you will be able to use instead - save a spacer of diagram.

    See you soon.

  • Spectrum X 360 (N1W02PA #UUF): best practices for the use of the power supply battery for laptop (spectrum X 360)

    Hello.

    I know the best practice to use the power supply to charge the battery? I heard that keep charging your battery while using Notepad deteriorate autonomy. I don't know if that's true, but I do not charge my spectrum X 360 at 20% power level.

    Kindly need some expert advice. Thank you.

    Hello:

    My recommendation is to follow the instructions provided in this document from HP to address... paying particular attention to the info listed according to the recommended battery care practices.

    http://h20564.www2.HP.com/hpsc/doc/public/display?docid=c00596784

  • Best practices for color use in Adobe CC?

    Hi all

    Is there an article that describes the best practices for use of color in Adobe CC?

    I produce a mixture of viewing online (PDF, for the most part) and real world print projects - often with the obligation for both. I recently updated my PANTONE + bridge books for the first time in ages and I am suddenly confused by the use of Lab colors in the Adobe Suite (Illustrator and InDesign).

    Everything I found online, looks like Lab color mode preferred to use because it is device independent. And perceptual (on screen), it looks much closer to the color, it is trying to represent. But when I mark a Spot color Illustrator rectangle using laboratory coordinates, to the sides of a rectangle using PANTONE + bridge CP and then export it to PDF, the version of CP to mix CMYK color corresponds exactly to my Pantone book - while the version of laboratory (after converted to CMYK using the ink Manager) is far away.

    I have this fantasy to manage only a single Illustrator or InDesign file for both worlds (PDF) printed and online. Is not possible in practice?

    Any info describing the basic definitions of the color modes - or even a book tracing more than use them in the real world - would be much appreciated!

    Thank you

    Bob

    Here are a few best practices you can already do.

    1 make sure that your color settings are synchronized on all applications.

    2. use a CMYK profile appropriate for your print output. Lab spot colors convert to CMYK values based on the CMYK icc profile.

    3. include icc profiles when save or export pdf files

    In theory, your imagination is possible today. It requires color management and the use of icc profiles. You can place RGB images in InDesign and use Pantone colors in your objects. The problem lies in the printers. If a printer uses a RIP with built in Pantone library, the colors will match when printing. Unfortunately, this kind of CUT is more expensive and not enough printers use them. Most of them is always manually approximate CMYK values composition given Pantone colors.

  • I can work on after effects being coded by best practices and Media Encoder file

    I just found out that after effects files can be returned outside the program using the media encoder.  I had been made in after effects of .mov, then open the file in photoshop to render the .mov to a mp4.  Not the process faster, but it worked.  If I use media encoder to make my legacy model would still be able to work in AfterEffects and edit and save the file rendered in media encoding, or it is locked?  I hear also the media encoder is slower than the after effects encoder.  What are the best practices for a comp sequelae which makes a mp4 (h264)?  Thank you...

    Depending on what you do the SOUL can be slower than using index rendering, but that's the only thing that you must use to make H.264 files.

    When you send a model to the SOUL a virtual copy of this composition that is the source for this rendering. You can continue to work on the same computer and additional changes but if you want these changes appears you will need to send this model to the SOUL again after making the changes.

    Almost without exception, I'm working on plans not and certainly never movies sequences in After Effects. My average computer is probably seven seconds, my average film is probably 30 minutes so I use AE to work on plans for effects which cannot be treated in my NLE. I almost always send a model to the SOUL to render a h.264 or a suitable production master, or both, and then I continue working in AE because I can't afford to wait for a rendering time. On almost all of it is the more efficient workflow.

  • Using PowerPoint and Captivate together - what are your best practices?

    HI - here are my two questions...

    (1) it seems that when you insert PowerPoint slides in CP7 and duplicate a slide - slide 2 is not a fresh new creation.  It is always related to the original slide & all changes to one of them in PowerPoint, a direct impact on other related slides.  I realize now that I can go back in PP and duplicate it... But it just seems like extra which steps.  Am I missing something here?

    (2) I would like to hear how others approach developers creating a new project of CP, using PowerPoint as a starting point.  Go you back or do you create new themes based on the drawings of PP and then copy and paste the content?  I guess I'm looking here for best practices.

    I appreciate your help!

    Denise

    Hello

    If you start from scratch, PowerPoint is a terrible thing to consider. Don't get me wrong it's a great tool for what it does. But the reason we see even any possibility for Captivate shoot in a PowerPoint presentation is because there are still masses of people out there who have hundreds of thousands of PowerPoint presentations they want to reallocate in e-learning. So it is to get this way managed job 'quick and dirty '.

    The process of importing a PowerPoint performs a conversion of the PowerPoint slide in Flash SWF file. Then, the SWF file is configured as the subject of the slide background. That's why when you duplicated the slide, you have seen the behaviour you have done.

    Here is that if you start from scratch, start with a blank Captivate project. Use PPT if you wish, but only as a design tool. Copy the images of PPT, then insert into Captivate.

    See you soon... Rick

Maybe you are looking for