Skip to content

Latest commit

 

History

History
1082 lines (651 loc) · 63.2 KB

File metadata and controls

1082 lines (651 loc) · 63.2 KB

SCION Microfrontend Platform

SCION Microfrontend Platform Projects Overview Changelog Contributing Sponsoring

Changelog

1.3.0 (2024-06-04)

Features

  • platform: provide method to get a specific application (c917433)

1.2.2 (2023-11-10)

Bug Fixes

  • platform: support navigating to blob URL (5bbb1e0)

1.2.1 (2023-11-02)

Bug Fixes

  • platform/client: show splash if instructed by the navigator, but only if not navigating to the same capability, if any (a91286d)

1.2.0 (2023-10-31)

Bug Fixes

Features

  • platform/client: enable microfrontend to display a splash until loaded (f44087f)
  • devtools: display splash while loading (11f0a53)
  • devtools: migrate to new theme of @scion/components (88f4ce5)

1.1.0 (2023-07-21)

Bug Fixes

  • platform/client: add missing method overload to ContextService#lookup (29d4e09)

Features

  • platform: allow associating arbitrary metadata with platform-specific capabilities (6eca043)
  • platform: provide API to check if application is qualified for capability (2204eff)

1.0.0 (2023-05-15)

chore

  • platform: drop deprecated API and backward compatibility (ccae819), closes #196

BREAKING CHANGES

  • platform: dropping deprecated API and backward compatibility introduced a breaking change for host and client applications.

    To migrate:

    • Update host and clients to version 1.0.0-rc.13 or higher.
    • Deprecated property ManifestService.lookupApplications$ has been removed; use ManifestService.applications instead.
    • Deprecated property Capability.requiredParams has been removed; declare required parameters via Capability.params instead and mark it as required.
    • Deprecated property Capability.optionalParams has been removed; declare optional parameters via Capability.params instead and mark it as non-required.

1.0.0-rc.13 (2023-03-10)

Performance Improvements

  • platform: increase broker gateway message throughput (579c125), closes #90

1.0.0-rc.12 (2022-12-21)

Bug Fixes

  • platform/client: do not provide HttpClient in client as only used in the host (e47ed8b)
  • platform/client: remove startup progress monitor from client (755422e)
  • platform/host: remove ManifestObject from public API since internal (36f0dd8)

Performance Improvements

  • platform: reduce library bundle size in client application (fff9953), closes #174

BREAKING CHANGES

  • platform: reducing the bundle size in client applications introduced a breaking change for host and client applications. The communication protocol between host and client has not changed, i.e., host and clients can be updated independently to the new version.

    To enable tree-shaking of the SCION Microfrontend Platform, the platform was split into three separate entry points. This reduced the raw size of the library in a client application by more than 50%, from 120 KB to 40 KB.

    Platform Entry Points:

    • MicrofrontendPlatformHost to configure and start the platform in the host application;
    • MicrofrontendPlatformClient to connect to the platform from a microfrontend;
    • MicrofrontendPlatform to react to platform lifecycle events and stop the platform;

    To migrate the host application:

    • start the platform via MicrofrontendPlatformHost.start instead of MicrofrontendPlatform.startHost
    • monitor startup progress via MicrofrontendPlatformHost.startupProgress$ instead of MicrofrontendPlatform.startupProgress$

    To migrate the client application:

    • connect to the host via MicrofrontendPlatformClient.connect method instead of MicrofrontendPlatform.connectToHost
    • test if connected to the host via MicrofrontendPlatformClient.isConnected method instead of MicrofrontendPlatform.isConnectedToHost
  • platform/client: removing client startup progress introduced a breaking change in the client.

    To reduce the size of the client bundle, the API for monitoring the startup progress in the client has been removed. This API is useful in the host, but not in the client, because the client only connects to the host and does not perform any long-running operation. There is no replacement.

  • platform/host: removing ManifestObject from public API introduced a breaking change.

    The ManifestObject interface is the internal representation of capabilities and intensions in the platform host. It was never intended to be public API.

    To migrate:

    • In the unlikely event that you use this interface, replace it with the following union type: Capability | Intention.

1.0.0-rc.11 (2022-12-06)

Bug Fixes

  • platform/host: add secondary origin to allowed origins (61cddc0), closes #197
  • platform/host: validate params of intent before passing it to interceptors (1f5f5e5)
  • platform/host: assert topic not to contain empty segments (f8c47e3)
  • platform/client: stop platform in beforeunload to avoid posting messages to disposed window (3969c17), closes #168
  • platform: do not break clients not supporting the ping liveness protocol (6d4eb78), closes #178
  • platform: do not unregister clients after resuming the computer from hibernation (a210d4b), closes #178

Features

  • platform/client: provide API for microfrontend to monitor focus (e5dc6c2)
  • platform/host: support for intercepting messages after platform-internal interceptors (bbfac42)
  • platform: drop support for wildcard capability qualifiers and optional wildcard intention qualifiers (9713cf0), closes #163
  • platform/client: provide hook to decorate observable emissions (4e0e9b4)

Performance Improvements

  • platform: optimize focus tracking and mouse event dispatching (daff4f0), closes #172

BREAKING CHANGES

  • platform/host: Property for configuring a secondary origin has been renamed from messageOrigin to secondaryOrigin. This breaking change only refers to the host.

    To migrate, configure the additional allowed origin via the secondaryOrigin property instead of messageOrigin, as following:

    await MicrofrontendPlatform.startHost({
      applications: [
        {symbolicName: 'client', manifestUrl: 'https://app/manifest.json', secondaryOrigin: 'https://secondary'},
      ],
    });
  • platform/host: The host now performs liveness probes to detect and remove stale clients, instead of relying on the heartbeats emitted by the clients of previous versions.

    The breaking change only refers to the host. The communication protocol between host and client has NOT changed. You can independently update host and clients to the new version.

    To migrate setting of a custom probe configuration in the host, specify the liveness instead of heartbeatInterval property, as follows:

    MicrofrontendPlatform.startHost({
      liveness: {interval: 60, timeout: 10},
      // omitted rest of the config
    });
  • platform: Optimization of mouse event dispatching introduced a breaking change for Angular applications.

    IMPORTANT: For Angular applications, we strongly recommend replacing zone-specific decorators for MessageClient and IntentClient with an ObservableDecorator. Otherwise, you may experience performance degradation due to frequent change detection cycles.

    It turned out that Angular zone synchronization with decorators for MessageClient and IntentClient is not sufficient and that observables should emit in the same Angular zone in which the subscription was performed. Using the new ObservableDecorator API, Angular zone synchronization can now be performed in a single place for all observables exposed by the SCION Microfrontend Platform.

    To migrate:

    • Remove decorators for MessageClient and IntentClient including their registration in the bean manager (e.g., NgZoneMessageClientDecorator and NgZoneIntentClientDecorator).
    • Provide a NgZoneObservableDecorator and register it in the bean manager before starting the platform. Note to register it as a bean, not as a decorator.

    For a complete example and detailed instructions, see https://scion-microfrontend-platform-developer-guide.vercel.app/#chapter:angular-integration-guide:synchronizing-rxjs-observables-with-angular-zone.

    Example of a decorator for synchronizing the Angular zone

    /**
    * Mirrors the source, but ensures subscription and emission {@link NgZone} to be identical.
    */
    export class NgZoneObservableDecorator implements ObservableDecorator {
    
      constructor(private zone: NgZone) {
      }
    
      public decorate$<T>(source$: Observable<T>): Observable<T> {
        return new Observable<T>(observer => {
          const insideAngular = NgZone.isInAngularZone();
          const subscription = source$
            .pipe(
              subscribeInside(fn => this.zone.runOutsideAngular(fn)),
              observeInside(fn => insideAngular ? this.zone.run(fn) : this.zone.runOutsideAngular(fn)),
            )
            .subscribe(observer);
          return () => subscription.unsubscribe();
        });
      }
    }

    Registration of the decorator in the bean manager

    const zone: NgZone = ...;
    
    // Register decorator
    Beans.register(ObservableDecorator, {useValue: new NgZoneObservableDecorator(zone)});
    // Connect to the host from a micro app
    zone.runOutsideAngular(() => MicrofrontendPlatform.connectToHost(...));
    // Start platform host in host app
    zone.runOutsideAngular(() => MicrofrontendPlatform.startHost(...));
  • platform: dropping support for wildcard capability qualifiers and optional wildcard intention qualifiers introduced a breaking change in the Intention API.

    To migrate:

    • Replace asterisk (*) wildcard capability qualifier entries with required params.
    • Replace optional (?) wildcard capability qualifier entries with optional params.
    • If using QualifierMatcher to match qualifiers, construct it without flags. The matcher now always evaluates asterisk wildcards in the pattern passed in the constructor.

    The following snippets illustrate how a migration could look like:

    Before migration

    Capability in Manifest of App 1

    {
      "name": "App 1",
      "capabilities": [
        {
          "type": "microfrontend",
          "qualifier": {
            "entity": "person",
            "id": "*",
            "readonly": "?"
          },
          "private": false,
          "properties": {
            "path": "person/:id?readonly=:readonly"
          }
        }
      ]
    }

    Intention in Manifest of App 2

    {
      "name": "App 2",
      "intentions": [
        {
          "type": "microfrontend",
          "qualifier": {
            "entity": "person",
            "id": "*",
            "readonly": "?"
          }
        }
      ]
    }

    Sending Intent in App 2

    const intent: Intent = {
      type: 'microfrontend',
      qualifier: {
        entity: 'person',
        id: '123',
        readonly: true
      }
    };
    Beans.get(IntentClient).publish(intent);

    After migration

    Capability in Manifest of App 1

    {
      "name": "App 1",
      "capabilities": [
        {
          "type": "microfrontend",
          "qualifier": {
            "entity": "person"
          },
          "params": [
            {
              "name": "id",
              "required": true
            },
            {
              "name": "readonly",
              "required": false
            }
          ],
          "private": false,
          "properties": {
            "path": "person/:id?readonly=:readonly"
          }
        }
      ]
    }

    Intention in Manifest of App 2

    {
      "name": "App 2",
      "intentions": [
        {
          "type": "microfrontend",
          "qualifier": {
            "entity": "person"
          }
        }
      ]
    }

    Sending Intent in App 2

    const intent: Intent = {
      type: 'microfrontend',
      qualifier: {
        entity: 'person'
      },
      params: new Map().set('id', '123').set('readonly', true)
    };
    Beans.get(IntentClient).publish(intent);

1.0.0-rc.10 (2022-11-08)

Bug Fixes

  • platform/messaging: receive latest retained message per topic in wildcard subscription (b578317)
  • devtools: activate selected tab in application details even after quick navigation (b9e1cff)

Features

  • platform: use unique identifier for capability and intention ID (e2957ba), closes #162 #171
  • platform/messaging: support sending retained intents (08afb72), closes #142
  • platform/messaging: support sending retained requests to a topic (1098f8f)
  • devtools: allow filtering capabilities by id (fff5dd7)
  • devtools: remove logical operator for capability filters where not useful (3909ba3)
  • devtools: render logical operators (OR/AND) in capability filters as toggle button (3130e88)

BREAKING CHANGES

  • platform/messaging: The IntentClient now uses the same options object as the MessageClient to control how to send a message or request. The content of the options object has not changed, only its name, i.e., migration is only required if assigning it to a typed variable or decorating the IntentClient.

    Note that the communication protocol between host and client has NOT changed, i.e., host and clients can be migrated independently.

    To migrate:

    • options for sending an intent was changed from IntentOptions to PublishOptions (IntentClient#publish)
    • options for requesting data was changed from IntentOptions to RequestOptions (IntentClient#request)
  • platform: Using unique identifier for capability and intention ID introduced a breaking change.

    Previously, the IDs used for capabilities and intentions were stable but not unique, which caused problems when deregistering capabilities and intentions. If your application requires stable capability identifiers, you can register a capability interceptor, as follows:

    import {Capability, CapabilityInterceptor} from '@scion/microfrontend-platform';
    import {Crypto} from '@scion/toolkit/crypto';
    import {Beans} from '@scion/toolkit/bean-manager';
    
    Beans.register(CapabilityInterceptor, {
      useValue: new class implements CapabilityInterceptor {
        public async intercept(capability: Capability): Promise<Capability> {
          const stableId = await Crypto.digest(JSON.stringify({
            type: capability.type,
            qualifier: capability.qualifier,
            application: capability.metadata!.appSymbolicName,
          }));
          return {
            ...capability,
            metadata: {...capability.metadata!, id: stableId},
          };
        }
      },
      multi: true
    })

    Note that the communication protocol between host and client has NOT changed. You can independently upgrade host and clients to the new version.

1.0.0-rc.9 (2022-11-02)

Features

  • platform/devtools: display platform version per application in DevTools (1c8d69c)
  • platform: allow intercepting capabilities before their registration (ba423af)

Performance Improvements

  • platform/messaging: index topic subscriptions for faster resolution (e8c2178)
  • platform/messaging: subscribe for replies when posting the request in request-response communication (cb23da3)
  • platform/messaging: track the number of subscriptions based on subscription change events (8b3c877)

1.0.0-rc.8 (2022-10-27)

Features

  • platform/router-outlet: set name of the iframe to the name of the outlet (1aa566d)

Performance Improvements

  • platform/messaging: transport intents to subscribed clients only (4247e9d), closes #124

1.0.0-rc.7 (2022-10-07)

Bug Fixes

  • platform/router-outlet: size outlet to the reported initial size of embedded content (49f036d)
  • platform/router: do not patch URL if protocol is "blob" (064f1f3)
  • platform: mirror Observable if replying with an Observable in message or intent callback (d0b8e27), closes #164
  • platform: report message rejection of asynchronous interceptors back to the sender (1517366), closes #147

Performance Improvements

  • platform/client: resend connect request only if loaded into the topmost window (ba4e9a2)

BREAKING CHANGES

  • platform: Fixing message rejection reporting of interceptors introduced a breaking change in the Interceptor API.

    This breaking change only refers to the host. The communication protocol between host and client HAS NOT CHANGED. Host and clients can be updated independently to the new version.

    In order to report asynchronous message rejection correctly, the Interceptor API has been changed from synchronous to asynchronous message interception. To migrate, change the return type of your interceptors from void to Promise<void> and change the implementation accordingly.

    The following snippets illustrate how a migration could look like:

    Before migration
    class MessageLoggerInterceptor implements MessageInterceptor {
      public intercept(message: TopicMessage, next: Handler<TopicMessage>): void {
        console.log(message);
    
        // Passes the message along the interceptor chain.
        next.handle(message);
      }
    }
    After migration
    class MessageLoggerInterceptor implements MessageInterceptor {
      public intercept(message: TopicMessage, next: Handler<TopicMessage>): Promise<void> {
        console.log(message);
    
        // Passes the message along the interceptor chain.
        return next.handle(message);
      }
    }

1.0.0-rc.6 (2022-06-04)

Bug Fixes

  • platform/config: use the application's symbolic name as application name if not configured (2058d99)
  • platform/router: do not discard supposedly identical navigations (5adba59)
  • platform/router: route the primary outlet if in the context of an activator and if not specified a target outlet (e99ee13)

Features

  • platform/devtools: facilitate integration in a router outlet or workbench view using intent-based navigation (bcc0718), closes #45
  • platform/router: facilitate intent-based navigation (052dd4c), closes #154
  • platform/router: remove matrix and query parameters not passed for substitution (b424647), closes #155

1.0.0-rc.5 (2022-05-18)

Dependencies

  • platform: migrate to the framework-agnostic package @scion/toolkit (2b53137)

BREAKING CHANGES

  • platform: Migrating to the framework-agnostic package @scion/toolkit introduced a breaking change.

    Previously, framework-agnostic and Angular-specific tools were published in the same NPM package @scion/toolkit, which often led to confusion and prevented framework-agnostic tools from having a release cycle independent of the Angular project. Therefore, Angular-specific tools have been moved to the NPM package @scion/components. Framework-agnostic tools continue to be released under @scion/toolkit, but now starting with version 1.0.0 instead of pre-release versions.

    The breaking change only refers to updating @scion/toolkit to version 1.0.0. API and communication protocol have not changed or are backward compatible. Host and clients can be updated independently to the new version.

    To migrate:

1.0.0-rc.4 (2022-05-02)

Bug Fixes

  • platform: discard intent parameter if set to undefined (873541d), closes #146
  • platform: remove semver dependency to avoid bundle optimization bailouts (bf44720), closes #141

1.0.0-rc.3 (2022-04-01)

Bug Fixes

  • devtools: allow integrating devtools into the browser window (af142e9)
  • platform: connect to the host periodically when starting the platform (788a444)

Features

  • platform: allow configuring the message origin for an application (c8a5bf3)

1.0.0-rc.2 (2022-03-18)

Dependencies

BREAKING CHANGES

  • platform: Upgrading @scion/microfrontend-platform to RxJS 7.x introduced a breaking change.

    The breaking change only refers to updating RxJS to version 7.5. API and communication protocol have not changed or are backward compatible. Host and clients can be updated independently to the new version.

    To migrate, upgrade your application to RxJS 7.5; for detailed migration instructions, refer to https://rxjs.dev/6-to-7-change-summary.

1.0.0-rc.1 (2022-03-15)

Bug Fixes

  • platform: allow publishing messages during platform shutdown (0cc9e2d), closes #83
  • platform: comply with the API of MessageClient and IntentClient regarding termination of its Observables (9bbc4a5)
  • platform: detect and remove stale client registrations (1b21bad)

Features

  • platform: detect the version of @scion/microfrontend-platform an application has installed (c891223)

1.0.0-beta.20 (2022-02-01)

Bug Fixes

  • ensure the SciRouterOutlet to be instantiated after initialization of the platform (f1514bd)

Code Refactoring

  • platform: consolidate API for configuring the platform (142ce8e), closes #39 #96
  • platform: remove gateway iframe in client-broker communication (0a4b4b0), closes #14

BREAKING CHANGES

  • platform: Removing the gateway communication iframe introduced a breaking change in the host/client communication protocol.

    You need to upgrade the version of SCION Microfrontend Platform in host and client applications at the same time. The breaking change refers only to the communication protocol, the API of the SCION Microfrontend Platform has not changed.

    To migrate, upgrade to the newest version of @scion/microfrontend-platform in the host and client applications.

  • platform: Consolidation of the API for configuring the platform host introduced a breaking change. The communication protocol between host and client is not affected by this change.

    Host App Migration

    • API for loading the platform config via a config loader has been removed; to migrate, load the config before starting the platform;
    • API for passing an app list to MicrofrontendPlatform.startHost has been removed; to migrate, register applications via MicrofrontendPlatformConfig object, as follows: MicrofrontendPlatformConfig.applications;
    • manual registration of the host application has been removed as now done implicitly; to migrate:
      • remove host app from the app list;
      • configure host privileges via HostConfig object, as follows:
        • MicrofrontendPlatformConfig.host.scopeCheckDisabled
        • MicrofrontendPlatformConfig.host.intentionCheckDisabled
        • MicrofrontendPlatformConfig.host.intentionRegisterApiDisabled
      • specify message delivery timeout in MicrofrontendPlatformConfig.host.messageDeliveryTimeout;
      • provide the host's manifest, if any, via MicrofrontendPlatformConfig.host.manifest, either as object literal or as URL;
      • specify the host's symbolic name in MicrofrontendPlatformConfig.host.symbolicName; if not specified, defaults to host;
    • the Activator API can now be disabled by setting the flag MicrofrontendPlatformConfig.activatorApiDisabled instead of PlatformConfig.platformFlags.activatorApiDisabled;
    • the interface ApplicationManifest has been renamed to Manifest;
    • the bean MicroApplicationConfig has been removed; you can now obtain the application's symbolic name as following: Beans.get<string>(APP_IDENTITY)

    Client App Migration

    • the micro application must now pass its identity (symbolic name) directly as the first argument, rather than via the options object;
    • the options object passed to MicrofrontendPlatform.connectToHost has been renamed from MicroApplicationConfig to ConnectOptions and messaging options are now top-level options; to migrate:
      • set the flag MicrofrontendPlatformConnectOptions.connect instead of MicroApplicationConfig.messaging.enabled to control if to connect to the platform host;
      • specify 'broker discovery timeout' in MicrofrontendPlatformConnectOptions.brokerDiscoverTimeout instead of MicroApplicationConfig.messaging.brokerDiscoverTimeout;
      • specify 'message delivery timeout' in MicrofrontendPlatformConnectOptions.messageDeliveryTimeout instead of MicroApplicationConfig.messaging.deliveryTimeout;
    • the bean MicroApplicationConfig has been removed; you can now obtain the application's symbolic name as following: Beans.get<string>(APP_IDENTITY)

    The following snippets illustrate how a migration could look like:

    Host App: Before migration

    const applications: ApplicationConfig[] = [
      {symbolicName: 'host', manifestUrl: '/manifest.json'}, // optional
      {symbolicName: 'app1', manifestUrl: 'http://app1/manifest.json'},
      {symbolicName: 'app2', manifestUrl: 'http://app2/manifest.json'},
    ];
    await MicrofrontendPlatform.startHost(applications, {symbolicName: 'host'});

    Host App: After migration

    await MicrofrontendPlatform.startHost({
      host: {
        symbolicName: 'host',
        manifest: '/manifest.json'
      },
      applications: [
       {symbolicName: 'app1', manifestUrl: 'http://app1/manifest.json'},
       {symbolicName: 'app2', manifestUrl: 'http://app2/manifest.json'}
      ]
    });

    Host App: After migration if inlining the host manifest

    await MicrofrontendPlatform.startHost({
      host: {
        symbolicName: 'host',
        manifest: {
          name: 'Host Application',
          capabilities: [
            // capabilities of the host application
          ],
          intentions: [
            // intentions of the host application
          ]
        }
      },
      applications: [
       {symbolicName: 'app1', manifestUrl: 'http://app1/manifest.json'},
       {symbolicName: 'app2', manifestUrl: 'http://app2/manifest.json'}
      ],
    });

    Client App: Before migration

    await MicrofrontendPlatform.connectToHost({symbolicName: 'shopping-cart-app'});

    Client App: After migration

    await MicrofrontendPlatform.connectToHost('shopping-cart-app');

1.0.0-beta.19 (2021-11-05)

Bug Fixes

  • platform: do not transport intents to other applications if not declaring a respective intention (24681e3)

1.0.0-beta.18 (2021-09-10)

Bug Fixes

  • platform: allow interceptors to reply to requests if no consumer is running (f22c947)

1.0.0-beta.17 (2021-07-12)

Bug Fixes

  • devtools: resolve dependent app also if declaring a wildcard intention (f321c5b)

Features

  • devtools: activate a dependency's counterpart tab when navigating to the dependent application (10dda73)
  • devtools: allow for quick filtering of capabilities (85abd52)
  • devtools: use larger initial width for the main display area (f96e826)
  • platform: allow associating metadata with a capability param (05952bc), closes #77

1.0.0-beta.16 (2021-07-02)

chore

  • update project workspace to Angular 12 (31c81c8), closes #76

1.0.0-beta.15 (2021-05-20)

Features

  • platform: allow setting a timeout for loading manifests and activators (fe26507), closes #6
  • platform: report platform startup progress (0e9300d), closes #18

chore

  • platform: compile with TypeScript strict checks enabled (bc390a8), closes #55

1.0.0-beta.14 (2021-04-22)

Features

  • platform: pass intent with resolved capability to intent interceptors (b51959d), closes #72

1.0.0-beta.13 (2021-04-12)

Bug Fixes

  • platform: allow context key names containing forward slashes or starting with a colon (5637832), closes #49
  • platform: remove ES2015 import cycles (5dfc7f6), closes #42

Features

  • platform: add wildcard support for unregistering capabilities and intentions (4d22403), closes #61

BREAKING CHANGES

  • platform: Allowing context key names containing forward slashes or starting with a colon introduced a breaking change in the host/client communication protocol.

    The messaging protocol between host and client HAS CHANGED for context value lookup using the ContextService. Therefore, you must update the host and affected clients to the new version together. The API has not changed; the breaking change only applies to the @scion/microfrontend-platform version.

    To migrate:

  • platform: Adding wildcard support for unregistering capabilities and intentions introduced a breaking change.

    To migrate:

    • upgrade host and client apps to use @scion/[email protected]
    • When searching for capabilities with a qualifier filter that contains scalar qualifier values, only capabilities with exactly those values are now returned. This is different from previous versions where a qualifier filter like {entity: 'person', id: '5'} matched capabilities with exactly that qualifier, as well as capabilities containing a wildcard (* or ?) in the qualifier, such as {entity: 'person', id: '*'} or {entity: 'person', id: '?'}. To keep the old lookup behavior, do not pass a qualifier filter and filter the capabilities yourself, e.g. by using the QualifierMatcher, as follows:
        Beans.get(ManifestService).lookupCapabilities$({type: 'view'})
        .pipe(filterArray(capability => new QualifierMatcher(capability.qualifier, {evalOptional: true, evalAsterisk: true}).matches({entity: 'person', id: '5'})))

1.0.0-beta.12 (2021-02-22)

Bug Fixes

  • platform: allow preventing default action of registered keystrokes (8ae8595), closes #32
  • platform: propagate topic subscription errors in context service (08bbaf7)

chore

  • migrate Vercel deployments to the updated Vercel URL format (f31fe5d), closes #56

Features

  • platform: allow collecting values on contextual data lookup (2e87b51)

BREAKING CHANGES

1.0.0-beta.11 (2021-02-03)

Features

  • platform: add convenience API to reduce code required to respond to requests (d0eeaf5), closes #43
  • platform: allow to specify a generic when registering a capability to increase type safety (4af9433), closes #60
  • platform: let the message/intent replier control the lifecycle of the requestor’s Observable (77a4dd9)

BREAKING CHANGES

  • platform: Adding the convenience API for responding to requests introduced the following breaking change for Angular projects.

    Note: The messaging protocol between the host and client HAS NOT CHANGED. Thus, you can upgrade the host and clients to the new version independently.

    To migrate:

  • platform: Enabling the message/intent replier to control the requestor’s Observable lifecycle introduced a breaking change in the host/client communication protocol.

    Note: The messaging protocol between host and client HAS CHANGED for registering/unregistering capabilities/intentions using the ManifestService. Therefore, you must update the host and affected clients to the new version together. The API has not changed; the breaking change only applies to the @scion/microfrontend-platform version.

    To migrate:

    • Upgrade host and clients (which use the ManifestService) to @scion/[email protected].
    • Remove the throwOnErrorStatus SCION RxJS operator when using IntentClient#request$ or MessageClient#request$ as already installed by the platform.

1.0.0-beta.10 (2021-01-25)

Bug Fixes

  • start platform outside angular zone in testing app and devtools (f017422), closes #53

1.0.0-beta.9 (2021-01-18)

Bug Fixes

  • devtools: perform scope check when computing dependencies between micro applications (5e43bc3)
  • platform: resolve host startup promise only once applications and properties are available (f4067c2)

Features

  • platform: allow monitoring sci-router-outlet whether embedded content has gained or lost focus (14fb178)
  • platform: allow passing params in an intent (b82b343), closes #44
  • platform: open shadow DOM of the router outlet (cb10c32)

1.0.0-beta.8 (2020-12-18)

Bug Fixes

  • platform: allow empty path as url for outlet navigation (8a0a70b)
  • platform: ensure trailing slash in application base URLs (62a7a92)
  • platform: make platform startup more robust (0d30b72), closes #40 #41

Features

  • devtools: add devtools micro application (19db8bf), closes #4
  • platform: provide a static list of installed applications in the manifest service (b60015f)

BREAKING CHANGES

  • platform: The HostPlatformState bean has been removed as no longer necessary, because activator microfrontends are now installed after completing host platform startup, and because the startup Promise waits until connected to the host.

To migrate: Instead of listening for the host platform to enter the 'started' state, wait for the startup Promise to resolve. Note: You can independently upgrade host and clients to the new version because the platform was not using the platform status at all.

1.0.0-beta.7 (2020-11-05)

Code Refactoring

  • platform: move bean manager to @scion/toolkit (aa00b7e), closes #33

BREAKING CHANGES

  • platform: The bean manager was moved from @scion/microfrontend-platform to @scion/toolkit NPM module.

Note: The messaging protocol between host and client HAS NOT CHANGED. You can therefore independently upgrade host and clients to the new version.

To migrate:

  • Update @scion/toolkit to version 10.0.0-beta.3.
  • Import following symbols from @scion/toolkit/bean-manager instead of from @scion/microfrontend-platform: BeanManager, Beans, Initializer, InitializerFn, BeanDecorator, PreDestroy, BeanInstanceConstructInstructions, Type, AbstractType.
  • Replace InstanceConstructInstructions with BeanInstanceConstructInstructions.
  • Use static methods of the MicrofrontendPlatform class to interact with states of the platform lifecycle (formerly via PlatformState bean), e.g., to wait for the platform to enter a specific state. In this change, we changed the bean PlatformState to an enum to represent platform states (formerly PlatformStates). Migrate as follows:
    • Beans.get(PlatformState).whenState -> MicrofrontendPlatform.whenState, e.g., Beans.get(PlatformState).whenState(PlatformStates.Starting) -> MicrofrontendPlatform.whenState(PlatformStates.Starting)
    • Beans.get(PlatformState).state -> MicrofrontendPlatform.state
    • Beans.get(PlatformState).state$ -> MicrofrontendPlatform.state$
  • Replace occurrences of PlatformStates with PlatformState.
  • Control bean destruction order by setting its destroyOrder in the options object when registering the bean (formerly by setting the destroy phase). Beans with a lower destroy order are destroyed before beans with a higher destroy order. Beans of the same destroy order are destroyed in reverse construction order. By default, the destroy order is 0.
  • Registering a bean now returns a handle to unregister the bean (formerly void). If registering a bean inside a void expression, register it inside a void operator, as follows: void (Beans.register(Bean))

1.0.0-beta.6 (2020-09-30)

Bug Fixes

  • platform: substitute falsy values in named parameters of URL (96c84db), closes #24

Features

  • platform: allow registering beans under a symbol (98bf890), closes #28
  • platform: separate message and intent communication APIs (7610eb0)

BREAKING CHANGES

  • platform: Use MessageClient for topic-based messaging, and IntentClient for intent-based messaging

Note: The messaging protocol between host and client HAS NOT CHANGED. You can therefore independently upgrade host and clients to the new version.

Breaking changes in MessageClient

Moved or renamed the following methods:

  • MessageClient#onMessage$ -> MessageClient.observe$
  • MessageClient#issueIntent -> IntentClient.publish
  • MessageClient#requestByIntent$ -> IntentClient.request$
  • MessageClient#onIntent$ -> IntentClient.observe$
  • MessageClient#isConnected -> MicrofrontendPlatform.isConnectedToHost

Renamed options object of the following methods:

  • MessageClient#request$: MessageOptions -> RequestOptions
  • IntentClient#publish: MessageOptions -> IntentOptions
  • IntentClient#request$: MessageOptions -> IntentOptions

Breaking change for decorating MessageClient and IntentClient bean

For Angular developers, see Preparing the MessageClient and IntentClient for use with Angular how to decorate the MessageClient and IntentClient for making Observables to emit inside the Angular zone.

Breaking change for disabling messaging in tests

Messaging can now be deactivated via options object when starting the platform. Previously you had to register a NullMessageClient bean. MicrofrontendPlatform.connectToHost({messaging: {enabled: false}}

1.0.0-beta.5 (2020-07-17)

chore

  • update project workspace to Angular 10 (20a3266), closes #19

BREAKING CHANGES

  • esm5 and fesm5 format is no longer distributed in @scion/microfrontend-platform’s NPM package

We no longer include the distributions for esm5 and fesm5 in the @scion/microfrontend-platform’s NPM package. Only the formats for esm2015, fesm2015, and UMD are distributed. Consequently, the module field in package.json now points to the fesm2015 distribution.

To migrate:

  • If requiring esm5 or fesm5, you will need to downlevel to ES5 yourself. If using Angular, the Angular CLI will automatically downlevel the code to ES5 if differential loading is enabled in the Angular project, so no action is required from Angular CLI users.

1.0.0-beta.4 (2020-07-14)

Bug Fixes

  • testapp: do not render the application shell in activator microfrontends (2180257)

Features

  • platform: enable activators to signal their readiness (5beb278), closes #6

1.0.0-beta.3 (2020-06-30)

1.0.0-beta.2 (2020-06-29)

1.0.0-beta.1 (2020-06-21)

Features

  • platform: move SCION Microfrontend Platform to a separate Git repository (b191ccd)
  • platform: provide services to manage and query capabilities and intentions (3923331)