Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create 2023-11-28-server-recon-explained.md #145

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

StreamingDataApps
Copy link
Collaborator

draft 1 of server.recon explainer

draft 1 of server.recon explainer
src/_posts/2023-11-28-server-recon-explained.md Outdated Show resolved Hide resolved
src/_posts/2023-11-28-server-recon-explained.md Outdated Show resolved Hide resolved
src/_posts/2023-11-28-server-recon-explained.md Outdated Show resolved Hide resolved
src/_posts/2023-11-28-server-recon-explained.md Outdated Show resolved Hide resolved
src/_posts/2023-11-28-server-recon-explained.md Outdated Show resolved Hide resolved
src/_posts/2023-11-28-server-recon-explained.md Outdated Show resolved Hide resolved
src/_posts/2023-11-28-server-recon-explained.md Outdated Show resolved Hide resolved

Here, `id` is a route variable used to uniquely identify a given `CityAgent`.

The second approach consists of specify the underlying web address for a specific agent. When using this, it is customary to specify a `seed` field for the corresponding `@agent` attribute that populates a `seed` field with configuration info, such as the name of a file. `swim.api.agent.AbstractAgent.getProp("seed")` can then be invoked on the Web Agent to retrieve the configuration information.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd add an example for this

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or link to the cellular repo

Copy link
Collaborator Author

@StreamingDataApps StreamingDataApps Feb 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In same cases, it may be desirable to specify multiple `@agent` attributes for the same configuration. This allows a component approach that separates concerns, such as having both a core agent and a logging agent. What happens is that each Web Agent implementation is matched against `@SwimLane` defined on each Web Agent, and each corresponding lane match is invoked. As a result, multiple Web Agents may run concurrently as a single Web Agent entity.

## Kernel Directives

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd detail what a kernel is here

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

StreamingDataApps and others added 7 commits December 8, 2023 06:55
apply suggested edit about recon

Co-authored-by: Thomas Klapwijk <[email protected]>
apply change to uppercase bullet items

Co-authored-by: Thomas Klapwijk <[email protected]>
accdept edit for bundled UIs

Co-authored-by: Thomas Klapwijk <[email protected]>
accept suggested edits for describing websocket attribute

Co-authored-by: Thomas Klapwijk <[email protected]>
remove text as suggested regarding server compression

Co-authored-by: Thomas Klapwijk <[email protected]>
correct mispelling of example

Co-authored-by: Thomas Klapwijk <[email protected]>
accept added text detailing resources directory

Co-authored-by: Thomas Klapwijk <[email protected]>
I have relocated recon server configuration to the recon related reference page. #130
Give an example of specify a seed for an agent and explain what a kernel is.
Copy link
Member

@ajay-gov ajay-gov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@StreamingDataApps the structure of the site here is quite different from the live site. Seems like you are using an older version. Can you merge main into your branch and then make the changes in the right place. That way it will be easier to review. Thanks

Copy link
Member

@ajay-gov ajay-gov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • We need a separate section for this called "Server Configuration". It doesn't fit into theRecon section since that section describes theRecon grammar and syntax. The server configuration just happens to be in recon format
  • Will be good to mention that the Swim Server looks for the server.recon in the classpath (not just src/main/resources). Also we should describe how the config file can be loaded using the `swim.config`` system property
  • DocumentRoot is superseded by the UIRouter, let's remove references to it
  • "The value of this field will be the same name used when defining the fabric attribute"- this is super important and should be highlighted or emphasized. Might be good to mention this again in the @fabric section. Have wasted a lot of time debugging only because these two didn't match
  • "When the server is run, the plane’s main() method will be invoked to instantiate the server application"- this isn't true. The main method can be defined in any class. It will be good to menti that typically we add the main method to the Plane class where we load the kernel using ServerLoader (maybe a reference to the right section about this as well?)
  • In the @node section, we should also mention node uri patterns dynamic agent instantiaton, node uris for automatic agent instatntiation with that uri and traits where there are multiple class definition for a single node uri (dynamic polymorphism). It can be brief and we should link to the relevant section on these items

Most of the requested fixes:

- Will be good to mention that the Swim Server looks for the server.recon in the classpath (not just src/main/resources). Also we should describe how the config file can be loaded using the `swim.config`` system property
- DocumentRoot is superseded by the UIRouter, let's remove references to it
- "The value of this field will be the same name used when defining the fabric attribute"- this is super important and should be highlighted or emphasized. Might be good to mention this again in the @fabric section. Have wasted a lot of time debugging only because these two didn't match
- "When the server is run, the plane’s main() method will be invoked to instantiate the server application"- this isn't true. The main method can be defined in any class. It will be good to menti that typically we add the main method to the Plane class where we load the kernel using ServerLoader (maybe a reference to the right section about this as well?)
Copy link

netlify bot commented Mar 12, 2024

Deploy Preview for scintillating-strudel-60ff56 ready!

Name Link
🔨 Latest commit 9a358f5
🔍 Latest deploy log https://app.netlify.com/sites/scintillating-strudel-60ff56/deploys/65f08e8faa5ac90008efd239
😎 Deploy Preview https://deploy-preview-145--scintillating-strudel-60ff56.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@ajay-gov ajay-gov self-assigned this Mar 15, 2024
@StreamingDataApps StreamingDataApps removed their assignment May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants