18
Packaging for Packaging for Voracity Solutions Voracity Solutions Control Panel Control Panel David Turner David Turner

Packaging for Voracity Solutions Control Panel David Turner

Embed Size (px)

Citation preview

Page 1: Packaging for Voracity Solutions Control Panel David Turner

Packaging for Packaging for Voracity SolutionsVoracity SolutionsControl PanelControl Panel

David TurnerDavid Turner

Page 2: Packaging for Voracity Solutions Control Panel David Turner

Folder StructureFolder StructureCreate a PluginSource folderCreate a PluginSource folder

Create a [Plugin] FolderCreate a [Plugin] Folder

Create a folder for each Create a folder for each specific Arena version that specific Arena version that you will be supportingyou will be supporting

Create a folder for the version Create a folder for the version of your pluginof your plugin

Page 3: Packaging for Voracity Solutions Control Panel David Turner

Package FilesPackage FilesCopy all the required Arena Copy all the required Arena files to the version subfolderfiles to the version subfolder

Create any required Create any required [version].sqlscript and [version].sqlscript and [version].portalconfig files[version].portalconfig files

Page 4: Packaging for Voracity Solutions Control Panel David Turner

[version].sqlscript Files[version].sqlscript FilesAny SQL Scripts that should Any SQL Scripts that should be run when your plugin is be run when your plugin is installed should be included installed should be included in a [version].sqlscript filein a [version].sqlscript file

The files will be run in version The files will be run in version orderorder

Only those files with a version Only those files with a version number greater than the number greater than the user’s current database user’s current database version for the plugin will be version for the plugin will be runrun

Each SQL statement in the Each SQL statement in the script file should be delimited script file should be delimited by “--||” charactersby “--||” characters

Page 5: Packaging for Voracity Solutions Control Panel David Turner

[version].portalconfig [version].portalconfig FilesFiles

Any portal configuration that is Any portal configuration that is required for your plugin should required for your plugin should be included in a be included in a [version].portalconfig file[version].portalconfig file

This includes creation of portal, This includes creation of portal, pages, modules, roles, etc.pages, modules, roles, etc.

The files will be run in version The files will be run in version orderorder

Only those files with a version Only those files with a version number greater than the user’s number greater than the user’s current database version for current database version for the plugin will be runthe plugin will be run

Contains XML generated by Contains XML generated by custom voracity custom voracity “PageXML.ascx” user control“PageXML.ascx” user control

Page 6: Packaging for Voracity Solutions Control Panel David Turner

PackagingPackagingOnce you’ve created all the Once you’ve created all the files, they should be zipped files, they should be zipped up as a [Plugin].zip fileup as a [Plugin].zip file

This zip file will then need to This zip file will then need to be uploaded to the Voracity be uploaded to the Voracity server as a plugin package server as a plugin package file file

The Voracity server keeps all The Voracity server keeps all package files in the App_Data package files in the App_Data folder grouped by Plugin and folder grouped by Plugin and Version Version

Page 7: Packaging for Voracity Solutions Control Panel David Turner

Plugin DatabasePlugin DatabaseVoracity Voracity Solutions keeps Solutions keeps a database of a database of available available plugins and plugins and authorized authorized users (partners)users (partners)

When a new When a new plugin is plugin is packaged it packaged it needs to be needs to be entered into entered into this databasethis database

Page 8: Packaging for Voracity Solutions Control Panel David Turner

Control Panel OverviewControl Panel OverviewThe Voracity Solutions Control The Voracity Solutions Control Panel allows for “one-click” Panel allows for “one-click” installation of packaged installation of packaged “plugins”“plugins”

To begin, Arena User installs a To begin, Arena User installs a default.aspx file to a default.aspx file to a “Voracity” subfolder under “Voracity” subfolder under the Arena installationthe Arena installation

The default.aspx page The default.aspx page downloads additional client-downloads additional client-side files that communicate side files that communicate with the Voracity web service with the Voracity web service and database to display list of and database to display list of plugins available to userplugins available to user

Page 9: Packaging for Voracity Solutions Control Panel David Turner

Default.aspx - Partner IDDefault.aspx - Partner IDThe first thing that the The first thing that the Default.aspx page does is Default.aspx page does is check to see if a Voracity check to see if a Voracity Partner ID has been saved. If Partner ID has been saved. If not, it will prompt user for not, it will prompt user for their Partner IDtheir Partner ID

Will verify that the ID they Will verify that the ID they enter is a valid Voracity enter is a valid Voracity Partner ID Partner ID

If the ID is valid, a new If the ID is valid, a new organization setting (and organization setting (and category) will be created to category) will be created to save the IDsave the ID

Page 10: Packaging for Voracity Solutions Control Panel David Turner

Default.aspx - LoginDefault.aspx - LoginAfter verifying Partner ID, After verifying Partner ID, Default.aspx will then check if Default.aspx will then check if a valid login id and password a valid login id and password have been entered yet during have been entered yet during the current session the current session

A valid network login and A valid network login and password are required for password are required for impersonation so that files impersonation so that files can be installed to the Arena can be installed to the Arena foldersfolders

Page 11: Packaging for Voracity Solutions Control Panel David Turner

Default.aspx - File Default.aspx - File UpdatesUpdates

After validating the login and After validating the login and password, Default.aspx will then password, Default.aspx will then download several files from the download several files from the Voracity server to the local Arena Voracity server to the local Arena installationinstallation

Default.aspx and Default.aspx and PluginManager.aspx will be PluginManager.aspx will be updated in the Arena\Voracity updated in the Arena\Voracity folder (PluginManager.aspx is what folder (PluginManager.aspx is what the “Administrate Website the “Administrate Website Modules” option links to)Modules” option links to)

VoracityPlugin.dll, VoracityPlugin.dll, VoracityPlugin.XmlSerializers.dll, VoracityPlugin.XmlSerializers.dll, and VoracityPlugin.dll.config will be and VoracityPlugin.dll.config will be updated in the Arena\Bin folderupdated in the Arena\Bin folder

Files are only downloaded if a Files are only downloaded if a newer version exists on the newer version exists on the Voracity serverVoracity server

Page 12: Packaging for Voracity Solutions Control Panel David Turner

PluginManager.aspxPluginManager.aspxPluginManager.aspx is the PluginManager.aspx is the page that is run when user page that is run when user clicks the “Administrate clicks the “Administrate Website Modules” option on Website Modules” option on the Default.aspx pagethe Default.aspx page

It displays a list of the It displays a list of the available plugins based on available plugins based on the Partner ID and the current the Partner ID and the current Arena versionArena version

Page 13: Packaging for Voracity Solutions Control Panel David Turner

PluginManager.aspx - PluginManager.aspx - File UpdatesFile Updates

Before displaying the list of Before displaying the list of plugins, PluginManager.aspx will plugins, PluginManager.aspx will also check to see if any files also check to see if any files need to be downloadedneed to be downloaded

PluginManager.aspx will be PluginManager.aspx will be updated in the Arena\Voracity updated in the Arena\Voracity folderfolder

VoracityPlugin.dll, VoracityPlugin.dll, VoracityPlugin.XmlSerializers.dll, VoracityPlugin.XmlSerializers.dll, VoracityPlugin.dll.config, and VoracityPlugin.dll.config, and Ionic.Zip.dll will be updated in Ionic.Zip.dll will be updated in the Arena\Bin folderthe Arena\Bin folder

An Image and PageConfig file will An Image and PageConfig file will be downloaded and a “Voracity be downloaded and a “Voracity Solutions” page will be created in Solutions” page will be created in the administrative area of Arenathe administrative area of Arena

Page 14: Packaging for Voracity Solutions Control Panel David Turner

PluginManager.aspx -PluginManager.aspx -PluginsPlugins

After the necessary support After the necessary support files have been downloaded, files have been downloaded, PluginManager.aspx displays a PluginManager.aspx displays a list of available pluginslist of available plugins

List is based on the Partner ID List is based on the Partner ID and the current Arena versionand the current Arena version

On the Voracity server, each On the Voracity server, each plugin version is configured plugin version is configured with a minimum Arena version with a minimum Arena version and flag indicating whether it is and flag indicating whether it is freely available or notfreely available or not

If the plugin is not freely If the plugin is not freely available, specific partner ID’s available, specific partner ID’s are configured with access to are configured with access to the pluginthe plugin

Page 15: Packaging for Voracity Solutions Control Panel David Turner

Currently Installed Currently Installed VersionVersion

Because a plugin is installed Because a plugin is installed to both the file system and the to both the file system and the database, these versions are database, these versions are stored independently and may stored independently and may not always be the samenot always be the same

A plugin’s current file system A plugin’s current file system version is saved in an Arena\version is saved in an Arena\Plugins\[plugin_name]\Plugins\[plugin_name]\InstalledVersion.txt fileInstalledVersion.txt file

A plugin’s current database A plugin’s current database version is saved as a version is saved as a “Voracity_[plugin_name]_Versi“Voracity_[plugin_name]_Version” org settingon” org setting

Page 16: Packaging for Voracity Solutions Control Panel David Turner

Plugin InstallationPlugin InstallationWhen user selects a plugin to install, the Control Panel will go through When user selects a plugin to install, the Control Panel will go through these steps when installing:these steps when installing:

Verify user is authorized for PluginVerify user is authorized for Plugin

Create an Arena\Plugins\[Plugin] folder if it doesn’t existCreate an Arena\Plugins\[Plugin] folder if it doesn’t exist

Download plugin’s package file to Arena\Plugins\[Plugin]\[Plugin].zipDownload plugin’s package file to Arena\Plugins\[Plugin]\[Plugin].zip

Iterate through each file in package zip fileIterate through each file in package zip file

If a *.portalconfig or *.sqlscript file, extract to the Arena\Plugins\If a *.portalconfig or *.sqlscript file, extract to the Arena\Plugins\[Plugin] folder[Plugin] folder

Otherwise, if user’s current file version of plugin is less than the Otherwise, if user’s current file version of plugin is less than the plugin version being installed, and file does not exist or is older plugin version being installed, and file does not exist or is older than file from package then extract filethan file from package then extract file

Page 17: Packaging for Voracity Solutions Control Panel David Turner

Plugin Installation (cont)Plugin Installation (cont)Create (or update) the Arena\Plugins\[Plugin]\InstalledVersion.txt Create (or update) the Arena\Plugins\[Plugin]\InstalledVersion.txt file with the current version of the plugin being installed file with the current version of the plugin being installed

Run the SQL scripts in each of the *.sqlscript files in the Arena\Run the SQL scripts in each of the *.sqlscript files in the Arena\Plugins\[Plugin] folder if the version is greater than the user’s Plugins\[Plugin] folder if the version is greater than the user’s current database version of the plugincurrent database version of the plugin

Process each of the *.portalconfig files in the Arena\Plugins\[Plugin] Process each of the *.portalconfig files in the Arena\Plugins\[Plugin] folder if the version is greater than the user’s current database folder if the version is greater than the user’s current database version of the pluginversion of the plugin

Update the current database version of the plugin by Update the current database version of the plugin by adding/updating the Voracity_[Plugin]_Version organization settingadding/updating the Voracity_[Plugin]_Version organization setting

Page 18: Packaging for Voracity Solutions Control Panel David Turner

PortalConfig PortalConfig For each modules/module node add a new module to Arena. Will not For each modules/module node add a new module to Arena. Will not add module if one already exists with same urladd module if one already exists with same url

For each roles/role node add a new role to Arena. Will not add new role For each roles/role node add a new role to Arena. Will not add new role if one already exists with same name or guidif one already exists with same name or guid

For each templates/template node add a new template to Arena. Will For each templates/template node add a new template to Arena. Will not add new template if one already exists with same namenot add new template if one already exists with same name

For the root page node (and all child pages) adds a new page to Arena. For the root page node (and all child pages) adds a new page to Arena. Will not add a new page if one already exists with the same guid.Will not add a new page if one already exists with the same guid.

Root page will be added as a child to an existing Arena page with the Root page will be added as a child to an existing Arena page with the same guid as specified by the parent_page_guid attribute on the root same guid as specified by the parent_page_guid attribute on the root page nodepage node

If a portal node exists will create a new portal in Arena. Will not add a If a portal node exists will create a new portal in Arena. Will not add a new portal if one already exists with the same namenew portal if one already exists with the same name