{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-guides/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"Ocean plug-in licensing","description":"Accelerate E&P application development and protect your innovation by consuming our Data and Domain APIs / Platform APIs.","lang":"en-US","meta":[{"name":"robots","content":"noindex"}],"llmstxt":{"hide":true,"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"ocean-plug-in-licensing","__idx":0},"children":["Ocean plug-in licensing"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"ocean-plug-in-licensing-1","__idx":1},"children":["Ocean plug-in licensing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Licensing has been a feature of software applications for a long time. Most applications use licensing to control who may run the application or which features may be used. Petrel uses several licenses to provide access to all of the Petrel features. This allows Petrel users to save money by purchasing only the features they want. To be consistent with this paradigm, Ocean provides an API for licensing plug-ins."]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image11.a008a3bc517df07af222484f8293bd9b393afa3f8cca3be98ae8ffa300653ff6.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑1 License selection dialog box with Ocean framework license selected",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Petrel uses a combination of a CodeMeter hardware key from WIBU Systems and the Ocean-supported licensing software approach, called the FlexFeature approach. Your plug-in cannot be started outside Petrel, and Petrel checks for the presence of the CodeMeter key."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Licensing is applied at either the plug-in level or the module level of an Ocean plug-in, depending on the licensing needs of your plug-in. You handle the licensing of your plug-in in one of two ways:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Bundled licensing"]},": All of the modules in a plug-in are bundled together and licensed as a single entity."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Individual licensing:"]}," Individual modules within a plug-in are licensed separately and individually, allowing several different licenses to access all of the plug-in features."]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["From a deployment standpoint, neither method is preferred over the other; the deployment method is left up to you and how you want to license your plug-in functionality."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["This topic is also covered in the \"Implementing License for Plug-ins\" white paper in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["OceanForPetrel.chm"]}," file."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"allow-read-only-mode","__idx":2},"children":["Allow read-only mode"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["When designing your module, consider allowing some pieces to operate in read-only mode."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["As an example, consider a scenario where only a couple of licenses for a plug-in are purchased, but these licenses are shared among members of an asset team. Some members of the team create and update custom domain objects with the module in the plug-in. Others view the custom domain object data, but because it is outside their expertise they do not create or edit it. If the plug-in operates in a read-only mode when no license is available then the second group of members of the team may also use the plug-in. The science in the plug-in module to be protected in this scenario is the creation and editing of the custom domain object. This scenario also works if the license cannot be checked out due to expiration to allow access to view data in the Petrel project."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The example code in this chapter demonstrates a module that works with read-only mode enabled."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Another way to accomplish read-only mode is to create two classes that both implement ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["IModule"]},":"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The first module does not have any licensing requirement and is responsible for the access to the data defined by the plug-in."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The second module is licensed and provides the features of the plug-in related to creating the data."]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"avoid-data-corruption","__idx":3},"children":["Avoid data corruption"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["It is possible that data could be corrupted if a scenario that followed these steps were encountered and the modules in a plug-in did not implement read-only mode."]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The user starts Petrel with the plug-in licensed, creates data with     the plug-in, saves the project, and exits Petrel."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The user restarts Petrel, but this time does not load the plug-in     because the license is not available or because the check box for     the module in the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog is not     selected."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The user then opens the project that contains the plug-in data and     saves the project."]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If read-only mode is implemented in the plug-in design, the plug-in must not damage the project data if the user opens and saves the data without a license."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"license-appearance","__idx":4},"children":["License appearance"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["You control the appearance of your plug-in in the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If your ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["IModule"]}," implementation class is licensed, ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["ModuleAppearanceAttribute"]}," determines the text and bitmap shown in the dialog box. This topic is discussed in the \"Module appearance\" section of ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["Ocean for Petrel Developer's Guide Volume 2: Core and Services"]},"."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If your ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class is licensed, the text comes from the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin.Name"]}," property and the image comes from the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["ImageResourceName"]}," property, as this example with are lease date of July 2017 shows:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_MYSUITE\", 2017.07f)]\npublic class MyOceanPlugin : Slb.Ocean.Core.Plugin\n{ // ...\n  public override string Name\n  {\n    get { return \"My Ocean Plugin\"; }\n  }\n  public override string ImageResourceName\n  {\n    get { return \"MyNamespace.MyResource.logo.bmp\"; }\n  }\n}\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["All other licensing examples in this volume also show a release date of July 2017."]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image12.07b02ad58f97b7fb66ad2f9d2808401ca84fe6f1c30fe2c20744ee0918e120bb.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑2 My Ocean Plugin displayed in the License selection dialog box",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["ImageResourceName"]}," property provides the full path to an embedded resource that is a bitmap to be displayed. Provide the full namespace qualified name of the resource. If the bitmap is not found, the default Ocean bitmap is used."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["In the Visual Studio Properties pane for the bitmap file, follow these steps:"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Set ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Build Action"]}," to ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Embedded Resource"]},"."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Set ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Copy to Output Directory"]}," to ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Do not copy"]},"."]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image13.e97ee28546b15955b71699aaba06cf5bfa5802cbf7b1be5bf1ddb94492bf12fa.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑3 Bitmap properties in Visual Studio",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"flexfeature-licensing","__idx":5},"children":["FlexFeature licensing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The FlexFeature licensing approach uses a FLEXlm license from Macrovision to control access to the Ocean plug-in features. Ocean plug-ins that are available through the Ocean Store must use this same licensing approach."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["When this approach is used, Petrel is responsible for performing the check out and check in of licenses, and your plug-in's licensing behavior is like that of native Petrel modules."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The FlexFeature approach operates under these general rules:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["If the license is not available then the plug-in is disabled. In the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box, the plug-in is shown as unavailable (the name is displayed in gray). This occurs when the license is already in use by another Petrel instance or when the plug-in is installed but the license is not on the license server."]}]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image14.51b4b4cc200ff60166f602275c72c8f7599d8438a3402cf8e25ca3a22c23146e.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑4 License not available on server is grayed",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If the license appears to be available and the check box is selected but for some reason the license cannot be obtained from the server, the user is informed of the issue and Petrel redisplays the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["When a module has a license that is will expire within fourteen days, a pop-up message appears to notify the user of the impending expiration. Petrel uses the same notification."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If Petrel enters standby mode, Petrel is responsible for checking in the license for the Ocean plug-in. Petrel checks out the license again when Petrel comes out of standby mode. Petrel goes into standby mode when the machine hibernates or sleeps."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The module is always loaded into Petrel; it does not matter whether or not the module is selected in the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box."]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"create-a-flexfeature-license-name","__idx":6},"children":["Create a FlexFeature license name"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["FlexFeature is the required licensing approach for plug-ins going on the Ocean Store (",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"http://www.ocean.slb.com"},"children":["http://www.ocean.slb.com"]},"). When a plug-in is purchased, the Ocean Store creates and emails the license to the user for the CodeMeter dongle ID provided by the user at the time of purchase. To perform this action, the Ocean Store must have the name of the FlexFeature to generate the license."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The Ocean Store Operations Manager works with you to create the FlexFeature license for your plug-in. Contact the Operations Manager at ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"mailto:OceanPartnerProgram@slb.com"},"children":["OceanPartnerProgram@slb.com"]},"."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The license feature name uses this naming convention:"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["OCEAN_XXX_YYYYYYYYYYYYYYYYYYYY"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["where:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["XXX"]},": Is a three-character mnemonic for the company name (for example, ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["SLB"]}," for Schlumberger)."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["YYYYYYYYYYYYYYYYYYYY"]},": Is up to twenty characters and names the module to be licensed."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Both fields must be all uppercase characters."]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For example, the Schlumberger PowerPoint Creator plug-in license has this FlexFeature name: ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["OCEAN_SLB_PETREL2PPT"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"flexfeatureattribute","__idx":7},"children":["FlexFeatureAttribute"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Whether you are using bundled licensing or individual licensing, the mechanism is the same in the code: you use the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FlexFeatureAttribute"]}," in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Slb"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Ocean"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Petrel"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Basics"]}," namespace and apply it toyour ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class, your ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," classes, or both."]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FlexFeatureAttribute"]}," is created with:"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The FlexFeature license/feature name. (This was explained previously.)"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The version number. By convention, this is set to the release date expressed as a float in the format ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["YYYY.MM"]},"."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["One optional flag indicates whether the FlexFeature is shared with another module or plug-in."]}]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"public sealed class FlexFeatureAttribute : Attribute\n{ ...\n  FlexFeatureAttribute(string name, float versionNumber);\n  FlexFeatureAttribute(string name, float versionNumber,bool isShared);\n}\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"version-numberrelease-date","__idx":8},"children":["Version number/release date"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["This example shows a plug-in that uses bundled licensing with a version number/release date of 2017.07 (July 2017):"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_MYFEATURENAME\", 2017.07f)]\npublic class MyPlugin : Slb.Ocean.Core.Plugin\n{ /* implementation ... */\n}\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Both Petrel and Ocean plug-in license files include a maintenance date in addition to the expiration date. The licensing code now checks that the license maintenance date is later than the FlexFeature version number/release date. For example, if the license file has a maintenance date of Oct 2017 then the end user may run the plug-in above. If a later version of the plug-in has a FlexFeature release date of ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["2017"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["12f"]}," then the end user cannot run the later version with the same license file because the maintenance date is before the release date."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If you deploy a patch release for your plug-in, the version number/release date must have the same version number/release dates as the plug-in being patched."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["You are not required to set a version number/release date; if you do not wish to use this functionality, continue to set the version number/release date to ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["0"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["0f"]},":"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_MYFUNCNORELEASEDATE\", 0.06f)]\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"share-a-license-feature-among-modules-or-plug-ins","__idx":9},"children":["Share a license feature among modules or plug-ins"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Two or more modules and/or plug-ins may share the same license feature and thus use the same single license on the license server. To share the license feature, these criteria must be met:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The value of the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["[FlexFeature]"]}," attribute ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["IsShared"]}," property must be true on all ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," and/or ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," classes sharing the license feature."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The value of the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["[FlexFeature]"]}," attribute ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FeatureName"]}," property must be equal on all ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," and/or ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," classes sharing the license feature."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The value of the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["[FlexFeature]"]}," attribute ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FeatureVersion"]}," property must be equal on all ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," and/or ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," classes sharing the license feature."]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["When multiple modules/plug-ins that share the same license feature are selected in the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box, the shared license feature is checked out only once."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_SHAREDFEATURE\", 2017.07f, true)]\npublic class MyModule : IModule\n{ /* implementation ... */ }\n  [FlexFeature(\"OCEAN_SLB_SHAREDFEATURE\", 2017.07f, true)]\n  public class MyModule2 : IModule\n  { /* implementation ... */\n  }\n  [FlexFeature(\"OCEAN_SLB_SHAREDFEATURE\", 2017.07f, true)]\n  public class MyModule3 : IModule\n  { /* implementation ... */\n  }\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["IsShared"]}," is ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["false"]}," (the default), the license feature cannot be shared with other modules, and each additional module that uses the same license feature causes an additional license to be checked out if one is available."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"bundled-licensing","__idx":10},"children":["Bundled licensing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["In bundled licensing, all of the modules in a plug-in are bundled together and licensed as a single entity. They are licensed at the parent ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," level. To enable bundled licensing, include the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["[FlexFeature]"]}," attribute on your ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_MYFEATURENAME\", 2017.07f)]\npublic class MyPlugin : Slb.Ocean.Core.Plugin\n{ /* implementation ... */ }\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For end users, bundled licensing means that they have to buy a bundled license to gain access to all features from all the modules in the plugin. When the licensing mode is bundled licensing, any child modules cannot be checked out individually. Bundled licensing looks the same in the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box. When bundled license mode is used, the check-out option is available for the plug-in and checking out the license provides a license for all child modules."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"individual-module-licensing","__idx":11},"children":["Individual module licensing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["In individual module licensing, individual modules in a plug-in are licensed separately and individually no matter which plug-in contains the module. To enable individual module licensing, put the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["[FlexFeature]"]}," attribute on each ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," class you want to be licensed, on ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," classes only. Modules have their own license features to check out, and these license features are likely different from each other."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_MYFEATURE1\", 2017.07f)]\npublic class MyModuleForFeature1 : IModule\n{ /* implementation ... */ }\n  [FlexFeature(\"OCEAN_SLB_MYFEATURE2\", 2017.07f)]\n  public class MyModuleForFeature2 : IModule\n  { /* implementation ... */\n  }\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For end users, individual module licensing means that users must buy an individual license for specific modules or for all the modules in the plug-in that they want to use. When the licensing mode is individual licensing, the check-out option is available on modules only. Figure 1‑5 shows individual module licensing in the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box."]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image15.cbeb2cace9299bcf7f9294f21c8fa171040fe9d2cf8d752069619c71e399d150.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑5 Individual module licensing",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box displays the plug-in as a parent node of its modules but has no check-out option for the plug-in. When individual module license mode is used, the check-out option is available on modules only, and the license check out is completed separately for each module."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"both-bundled-and-individual-module-licensing","__idx":12},"children":["Both bundled and individual module licensing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Your plug-in may support both bundled and individual module licensing. In this case, put the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["[FlexFeature]"]}," attribute on both your ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class and on at least one ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," class (for each one that you want to be individually licensed)."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_PLUGINFEATURE\", 2017.07f)]\npublic class MyPluginForFeature : Slb.Ocean.Core.Plugin\n{ /* implementation ... */ }\n  [FlexFeature(\"OCEAN_SLB_MYFEATURE1\", 2017.07f)]\n  public class MyModuleForFeature1 : IModule\n  { /* implementation ... */ }\n    [FlexFeature(\"OCEAN_SLB_MYFEATURE2\", 2017.07f)]\n    public class MyModuleForFeature2 : IModule\n    { /* implementation ... */\n    }\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog shows checkboxes for both a plug-in and individual modules. If the end user selects the bundled license on a ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]},", individual licenses are not selected/checked. The bundled license is checked out which is valid for all the modules in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]},". If the end user selects individual modules, it unchecks the plug-in checkbox, and only individual module licenses are checked out."]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image16.daf16ad36dc5bf1b0a312be911c95ac3c9656b1ee5cb89f2d6b6e4ecdfff6d9f.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑6 Select bundled license",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image17.fbc7d433e6bc9e338e153405f613f3601c498aadd0ef6d6bbb5c9c756f965878.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑7 Select individual module license",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"licensing-summary","__idx":13},"children":["Licensing summary"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Table 1 summarizes ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["[FlexFeature]"]}," attribute use and supported licensing modes."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Table 1"]}," [FlexFeature] attributes"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"align":"left","data-label":"[FlexFeature] attribute location"},"children":["[FlexFeature] attribute location"]},{"$$mdtype":"Tag","name":"th","attributes":{"align":"left","data-label":"Licensing Mode supported"},"children":["Licensing Mode supported"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["On ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class only"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Bundled licensing only"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["On ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," classes only"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Individual module licensing only"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["On ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class and ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," classes"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Bundled and individual module licensing"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"check-license-availability","__idx":14},"children":["Check license availability"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["To check out a license, use methods in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Slb"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Ocean"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Petrel"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Licensing"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicensingService"]}," class.Check whether Petrel has obtained a Petrel license, a module license, a plug-in license, or a particular flex feature of a module. The specific method you use for license checking depends on what licensing functionality you are supporting."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Typically this check is performed once in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["IModule"]}," ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Initialize"]}," method, and a private variable is used to retain the license state. This example is for a plug-in that supports both bundled licensing and individual module licensing."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"// using Slb.Ocean.Petrel.Basics;\n// using Slb.Ocean.Petrel.Licensing;\n[FlexFeature(\"OCEAN_SLB_INDIVIDUAL-A\", 2017.07f, false)]\npublic class MyModuleA : IModule\n{\n  private bool m_hasModLicense = false;\n  private bool m_hasPluginLicense = false;\n  public void Initialize()\n  {\n    LicensingService ls = PetrelSystem.LicensingService;\n    // assembly qualified type name of parent plugin\n    string p =\"LicensingSample.BundledPluginA, LicensingSample\";\n    // See if module or plugin license has been obtained.\n    m_hasPluginLicense = ls.HasPluginLicense(p);\n    m_hasModLicense = ls.HasModuleLicense(typeof(Module));\n  }\n  public void Integrate()\n  {\n    if (m_hasModLicense || m_hasPluginLicense)\n    {\n      // Add services provided by this module\n    }\n    else\n    {\n      // Do read only work or nothing... please consider that\n      // existing projects may be around with serialized data\n      // produced by this plugin. Even if license has expired,\n      // deserialization of those data is usually necessary.\n    }\n  }\n  // Do same for other Module methods...\n  public void Dispose()\n  {\n    // No license to dispose\n  }\n}\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["And the containing ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[FlexFeature(\"OCEAN_SLB_BUNDLED-A\", 2017.07f)]\npublic class BundledPluginA : Slb.Ocean.Core.Plugin\n{ /* implementation ... */ }\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["See additional examples in the \"Implementing License for Plug-ins\" white paper in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["OceanForPetrel.chm"]}," file."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"well-known-petrel-licenses","__idx":15},"children":["Well-known Petrel licenses"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The Ocean API exposes well-known Petrel licenses with the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["WellKnownPetrelLicenses"]}," class. You access the Petrel license from the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["static"]}," properties on the class, and you access the corresponding ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["string"]}," identifiers for each license through the nested ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Identifiers"]}," class."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"public static class WellKnownPetrelLicenses\n{ ...\n  public static PetrelLicense CombinedCore { get; }\n  public static PetrelLicense DataAnalysis { get; }\n  public static PetrelLicense GeoscienceCore { get; }\n  public static PetrelLicense FaultAnalysis { get; }\n  public static class Identifiers\n  { ...\n    public const string CombinedCore;\n    public const string DataAnalysis;\n    public const string GeoscienceCore;\n    public const string FaultAnalysis;\n  }\n}\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The identifier is the display name, which is typically displayed in the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["License selection"]}," dialog box. For all available licenses and identifiers, see the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["OceanForPetrel.chm"]}," file."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["These identifiers are also used as ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["PetrelLicense"]}," attributes (as ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Module"]}," Names) to license Ocean plug-ins that are allowed to be licensed both from the Ocean store and/or as part of a Petrel package/SOS license. This example demonstrates use of ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["WellKnownPetrelLicenses"]},". ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Identifiers"]}," as a code attribute to markan Ocean plug-in as dependent on the Petrel ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FaciesModeling"]}," modulelicense."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"public class MyPluginUsesPetrelLicense : Slb.Ocean.Core.Plugin\n{ /* implementation ... */\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["If the plug-in depends on the availability of a Petrel license, use these identifier values when setting the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Licensing"]}," attribute for a command or resource in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Configuration Designer"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"licenseprovider-licensing","__idx":16},"children":["LicenseProvider licensing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Before 2012, an additional licensing software approach called ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseProvider"]}," was supported; however, Petrel support for this approach has been dropped."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Plug-ins that use this licensing approach are not placed on the Ocean Store. You may use this approach if your plug-in will not be available on the Ocean store."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseProvider"]}," approach to licensing your module requires much more code on your part to manage the license; no support from Ocean is provided at all. You are required to handle all aspects of the licensing feature, including license verification and license check-out and check-in mechanisms. In this case, the license check out is performed in the constructor of your module. You must dispose of the license to check it back in during your ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Dispose"]}," method."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"code-for-licenseprovider-licensing","__idx":17},"children":["Code for LicenseProvider licensing"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Implementing the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseProvider"]}," style of licensing requires you to handle all of the licensing code yourself. You must implement a ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseProvider"]}," class. In your code that implements ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["IModule"]}," you must follow these tasks:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Add a ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseProvider"]}," attribute to your module to indicate it implements its own ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseProvider"]},"."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Declare a private member variable of type ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["System.ComponentModel.License"]},"; this is used to allow read-only operation of your module, if desired."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Initialize your license variable and checkout the license in the constructor of your class."]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Release the license in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Dispose"]}," method to ensure the license is correctly checked in."]}]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[LicenseProvider(typeof(MyOwnLicenseProvider)]\npublic class MyModuleWithOwnLicenseProvider : IModule\n{\n  private System.ComponentModel.License m_License = null;\n  public MyModuleWithOwnLicenseProvider()\n  {\n    // Try to obtain license ...\n    {\n      CoreLogger.Info(\"Module is licensed with key: \" +\n      m_License.LicenseKey);\n      // Add services provided by this module ...\n    }\n    // if could not get license ...\n    {\n      CoreLogger.Info(\"License is not valid.\");\n      // Possibly work with no license required ...\n    }\n  }\n  public void Initialize()\n  {\n    if (m_License != null)\n    {\n      // Do something adding feature to Petrel ...\n    }\n    else\n    {\n      // Possibly work with no license required ...\n    }\n  }\n  // Do same for other Module methods...\n  public void Dispose()\n  {\n    // Must dispose of license if it exists.\n    if (m_License != null)\n    {\n      m_License.Dispose();\n      m_License = null;\n    }\n    // Perform any other cleanup for module\n  }\n}\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note:"]}," In this example, the license validation is performed in the constructor for the module. If the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["IsValid"]}," method fails to get a license and returns ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["false,"]}," the module continues to load and run in a read-only mode."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["See additional examples and information in the \"Implementing License for Plug-ins\" white paper in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["OceanForPetrel.chm"]}," file."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"warm-license-checkout","__idx":18},"children":["Warm license checkout"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Warm license checkout allows users to start Petrel with a minimal set of licenses and later check out additional licenses during runtime to enable features when needed. This introduces a behavioral change when licenses are checked out. To support warm checkout Ocean developers have to enable all components of their plug-ins unconditionally and then protect each one by license checks. It is optional for plug-ins to support warm license checkout."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"enabling-warm-checkout","__idx":19},"children":["Enabling warm checkout"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["A new ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseAttribute"]}," has been introduced to indicate that an Ocean plug-in supports warm checkout. Current Ocean plug-ins only need to replace the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FlexFeatureAttribute"]}," with the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseAttribute"]},"."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"java","header":{"controls":{"copy":{}}},"source":"[License(\"OCEAN_SLB_MYSUITE\", 2017.07f)]\npublic class MyOceanPlugin : Slb.Ocean.Core.Plugin\n{\n  /* implementation */\n}\n[License(\"OCEAN_SLB_MYSUITE\", 2017.07f)]\npublic class MyOceanPlugin : Slb.Ocean.Core.Plugin\n{\n  /* implementation */\n","lang":"java"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Note:"]}," Ensure consistent usage of ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseAttribute"]},". When a plug-in has been updated to support warm checkout, all occurrences of the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FlexFeatureAttribute"]}," in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Plugin"]}," class and module classes must be replaced with ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseAttribute"]},". A plug-in that has been partially updated is not supported. The behavior might have unexpected side effects."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For more information on how to add license checks in commands, worksteps, custom windows and more, see the \"Warm License Checkout for Plug-ins\" white paper in the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["OceanForPetrel.chm"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"notification-about-warm-license-checkout","__idx":20},"children":["Notification about warm license checkout"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Use the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicensingUpdaterService"]}," to request a callback when a warm checkout of a license happens. This allows a module to piggy back on a Petrel license and only function if a particular Petrel license is available. To request a callback, you need to register a ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseUpdaterManifest"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"check-out-license-at-petrel-startup","__idx":21},"children":["Check out license at Petrel startup"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["On Petrel startup Ocean plug-ins that do not support warm checkout are displayed with an info icon and a tooltip. The tooltip explains that the plug-in needs to be checked out at startup and cannot be checked out later. Ocean plug-ins supporting warm checkout are displayed without any info."]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image18.034b94e8dd6e3bdb95dd80ddfb00c1be184372b46da7a497ffcb2d79c1496f32.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑8 Plug-in that supports warm checkout and one that does not",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"check-out-license-with-petrel-running","__idx":22},"children":["Check out license with Petrel running"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The Petrel end user may check out a license after Petrel is up and running, by launching the License dialog from ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["File > License modules"]},". Ocean plug-ins using the ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["LicenseAttribute"]}," are displayed as selectable and ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FlexFeatureAttribute"]}," plug-ins selected at startup are displayed without a check box. Ocean plug-ins using ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["FlexFeatureAttribute"]}," that were not checked out during startup are not displayed."]},{"$$mdtype":"Tag","name":"p","attributes":{"align":"center"},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image19.077c4424543bb5b579184147bce05550ed79f5be244ff30bb13a30a85acb243e.24bc979a.png"},"children":[]},{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]},"Figure 1‑9 SampleWarmPlugin available for warm checkout",{"$$mdtype":"Tag","name":"br","attributes":{},"children":[]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["It is important to note that once a license has been checked out it cannot be checked back in. Petrel needs to be restarted to free-up the license(s)."]}]},"headings":[{"value":"Ocean plug-in licensing","id":"ocean-plug-in-licensing","depth":1},{"value":"Ocean plug-in licensing","id":"ocean-plug-in-licensing-1","depth":2},{"value":"Allow read-only mode","id":"allow-read-only-mode","depth":3},{"value":"Avoid data corruption","id":"avoid-data-corruption","depth":3},{"value":"License appearance","id":"license-appearance","depth":3},{"value":"FlexFeature licensing","id":"flexfeature-licensing","depth":2},{"value":"Create a FlexFeature license name","id":"create-a-flexfeature-license-name","depth":3},{"value":"FlexFeatureAttribute","id":"flexfeatureattribute","depth":3},{"value":"Version number/release date","id":"version-numberrelease-date","depth":4},{"value":"Share a license feature among modules or plug-ins","id":"share-a-license-feature-among-modules-or-plug-ins","depth":4},{"value":"Bundled licensing","id":"bundled-licensing","depth":3},{"value":"Individual module licensing","id":"individual-module-licensing","depth":3},{"value":"Both bundled and individual module licensing","id":"both-bundled-and-individual-module-licensing","depth":3},{"value":"Licensing summary","id":"licensing-summary","depth":3},{"value":"Check license availability","id":"check-license-availability","depth":3},{"value":"Well-known Petrel licenses","id":"well-known-petrel-licenses","depth":3},{"value":"LicenseProvider licensing","id":"licenseprovider-licensing","depth":2},{"value":"Code for LicenseProvider licensing","id":"code-for-licenseprovider-licensing","depth":3},{"value":"Warm license checkout","id":"warm-license-checkout","depth":2},{"value":"Enabling warm checkout","id":"enabling-warm-checkout","depth":3},{"value":"Notification about warm license checkout","id":"notification-about-warm-license-checkout","depth":3},{"value":"Check out license at Petrel startup","id":"check-out-license-at-petrel-startup","depth":3},{"value":"Check out license with Petrel running","id":"check-out-license-with-petrel-running","depth":3}],"frontmatter":{"seo":{"title":"Ocean plug-in licensing"}},"lastModified":"2026-02-06T15:20:37.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/solutions/ocean-petrel/dev-guide/11_licensingdeploymentunittesting/11_licensingdeploymentunittesting_1","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}