Uploaded image for project: 'IGB'
  1. IGB
  2. IGBF-2084

Refactor App Store release and app models

    Details

    • Type: Task
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
      None

      Description

      Our current App Store code assumes that mutable App details such as Bundle_Description, short title, authors, user ratings (stars), authors, short title, screen captures, license URL, etc. are shared across all versions of an App.

      However, this is problematic because some information might change between releases of an App.

      For example, version 2.0.0 of "AnApp" could use a different license than "AnApp" version 1.0.0. Version 2.0.0 might also have different authors. Or it could require a different version of the IGB platform itself.

      We need to refactor the App Store to enable different content to appear for different versions of the same App. Also, the content shown will depend on which version of IGB (if any) is running on the user's desktop.

      When a user launches a particular version of IGB and then visits the App Store page for "AnApp" in their Web browser, details for the highest version of "AnApp" compatible with that particular version of IGB should be displayed. To find out which version that is, App Store can use function "get_app_info" implemented in appstore/static/apps/js/app_page.js, which hits an IGB REST endpoint sending the Bundle_SymbolicName as a parameter.

      To save time for developers, we should migrate much of the information for the highest current release of "AnApp" over to new releases. For example, we should "copy over" details such as the source code URL, authors, etc, excluding content that gets imported directly from the uploaded jar file, e.g., BundleName and BundleDescription. The developer will then be able to edit details for the newly released App using the previously entered information as a starting point.

      When displaying ratings (stars) and number of downloads for "AnApp", the summary views should show the total across all releases of the same App.
      We can provide more details, fine-grained statistics via a "Download Stats" button similar to Cytoscape App Store.

      Tasks:

      • Refactor app models.py to capture immutable App release information in the "releases" table, user-editable details needed to build the page in EditableAppDetails
      • Ensure that BundleDescription field is initially populated from the repository.xml file uploaded with the bundle jar
      • Ensure that IGB App Manager and IGB App Store are showing the same BundleDescription

        Attachments

          Issue Links

            Activity

            Hide
            ann.loraine Ann Loraine added a comment -

            Models:

            App - captures information about an OSGi bundle that IGB can install.
            Within IGB, or any OGSi-based application, two attributes of a bundle together uniquely identify it:

            • Bundle_SymbolicName
            • Bundle_Version

            In keeping with this, App Store's database will capture these two values as a compound primary key using "unique together" in App class:

            from: https://stackoverflow.com/questions/2201598/how-to-define-two-fields-unique-as-couple

            class Meta:
            unique_together = ('field1', 'field2',)

            Fields:

            • Bundle_Name
            • Bundle_SymbolicName
            • Bundle_Version
            • Bundle_Description (first parsed from the jar file, but can be edited by a user)
            Show
            ann.loraine Ann Loraine added a comment - Models: App - captures information about an OSGi bundle that IGB can install. Within IGB, or any OGSi-based application, two attributes of a bundle together uniquely identify it: Bundle_SymbolicName Bundle_Version In keeping with this, App Store's database will capture these two values as a compound primary key using "unique together" in App class: from: https://stackoverflow.com/questions/2201598/how-to-define-two-fields-unique-as-couple class Meta: unique_together = ('field1', 'field2',) Fields: Bundle_Name Bundle_SymbolicName Bundle_Version Bundle_Description (first parsed from the jar file, but can be edited by a user)
            Hide
            ann.loraine Ann Loraine added a comment -

            We developed new App and Release models for the database. See linked ticket.

            Show
            ann.loraine Ann Loraine added a comment - We developed new App and Release models for the database. See linked ticket.

              People

              • Assignee:
                ann.loraine Ann Loraine
                Reporter:
                ann.loraine Ann Loraine
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: