Encontrar

Artículo
· 21 hr atrás Lectura de 14 min

High Availability IAM

One of the recommendations when deploying InterSystems Technologies for production is to set up High Availability. The recommended API Manager for these InterSystems Technologies is the InterSystems API Manager (IAM). IAM (essentially Kong Gateway) has multiple deployment topologies.

If you are looking for high availability you could use:

a) Kong Traditional Mode: Multiple Node Clusters

b) Hybrid Mode

c) DB-less Mode

Before we break them down let's first understand the out of the box deployment that is provided by InterSystems: Installing IAM Version 3.10.

Kong Traditional Mode

This is the Kong Traditional Mode: Single Node Cluster. If you haven't yet, go over the great article by @Guillaume RongierIAM (InterSystems API Manager), Zero to Hero which does a great job explaining how to get IAM up and working with InterSystems IRIS. 

The Kong Traditional Mode Single Node Cluster is the only currently supported IAM deployment option via IKO at this time, check out the docs for deploying that here.

Note that in the YAML of Guillaume's article (section 2.4.4 of the article or 3.4.4 of the attached OpenExchange Application's GitHub Repository's README) , we have 3 containers:

  • iam-migrations (an initialization of the empty postgres database)
  • iam (IAM itself!)
  • db (the postgres database)

In Traditional Mode all configuration is done via the IAM container and all requests are sent to this container as well.

This can be scaled up so we are less reliant on a single IAM container: 

It is very simple, you just add another IAM section! So if you are working on just one YAML you could have:

  • iam-migrations
  • iam1
  • iam2
  • db

Note that if you are working on just one YAML you must make sure you give IAM1 different ports than IAM2.

 
Spoiler (Traditional)

Ideally, you would like for the database (including the migrations bootstrap) and each Kong node to be running on independent servers. In this case the ports would not be a problem, but you would have to make sure to change the KONG_PG_HOST environment variable to point to the host the database is running on.

Now you have High Availability, though this is Active/Active as opposed to the IRIS/HealthConnect Active/Passive Mirroring. You can go ahead and set up any configuration on either IAM1 or IAM2 and since they share a database the other will be updated and store the same information. 

If you would like independent databases you would have to have 2 individual single node clusters. Note that Kong does not have an option to "mirror" databases such as IRIS so you would need to create a pipeline to automate the configuration (or configure everything twice, or get rid of the DB entirely - see DB-less Mode). In the above diagram provided by Kong, we see that they would have just had 3 IAMs instead of 2. You would also want to add a load balancer as well as a health check probe on each IAM node, with the environment variable KONG_STATUS_LISTEN: 0.0.0.0:8100. 

A significant advantage to the Traditional Mode is:

Traditional mode is the only deployment topology that supports plugins that require a database, like rate limiting with the cluster strategy, or OAuth2.

But it comes with downsides as well:

  • When running in traditional mode, every Kong Gateway node runs as both a Control Plane (CP) and Data Plane (DP). This means that if any of your nodes are compromised, the entire running gateway configuration is compromised.
  • If you’re running Kong Gateway Enterprise with Kong Manager, request throughput may be reduced on nodes running Kong Manager due to expensive calculations being run to render analytics data and graphs.

The following modes solve these issues.

Kong Hybrid Mode

Hybrid Mode splits what we previously referred to as the IAM container into two: the Control Plane (CP) and the Data Plane (DP).

The CP is where the administration of Kong is hosted, such as the Kong Manager (this is the "management portal" of Kong, by default accessed on port 8002 or 8445). The control plane is connected to the database and sends its configuration out to the DPs. The DPs do not have any of the responsibility for managing Kong, only for implementing the configurations. All client API requests via Kong are sent directly to the DPs without going through the CP (this is the routes, by default at port 8000 or 8443). This resolves the downsides introduced by Traditional Mode Multi Node Clusters. An imperfect InterSystems analogy to Hybrid Mode is that of ECP.  The client interacts with the fast running DP who's only purpose is to serve the application, while we leave everything else, such as management, and rendering of data and graphs to the CP.

 

Have a look at what the Control and Data Plane YAMLs look like below. 

 
Spoiler (Control Plane)
Note that for the first time we have introduced some some certificates and keys. For the sake of simplicity I will try to avoid them in this article and write about how to properly set up secure communication in an upcoming article. That being said, Hybrid Mode requires that the CP and DP communicate via mTLS hence it was necessary.
 
Spoiler (Data Plane)
 
As before you would want to make sure to set up a load balancer. This is my preferred Highly Available Deployment Topology for IAM as I am a fan of working with the GUI, but enjoy the compartmentalization in that administration is on the control plane, while the client/application connects to the data plane. Have a look through at the other benefits of this mode:
 
  • Deployment flexibility: Users can deploy groups of Data Planes in different data centers, geographies, or zones without needing a local clustered database for each DP group.
  • Increased reliability: The availability of the database doesn’t affect the availability of the Data Planes. Each DP caches the latest configuration it received from the Control Plane on local disk storage, so if CP nodes are down, the DP nodes keep functioning.
    • While the CP is down, DP nodes constantly try to reestablish communication.
    • DP nodes can be restarted while the CP is down, and still proxy traffic normally.
  • Traffic reduction: Drastically reduces the amount of traffic to and from the database, since only CP nodes need a direct connection to the database.
  • Increased security: If one of the DP nodes is compromised, an attacker won’t be able to affect other nodes in the Kong Gateway cluster.
  • Ease of management: Admins only need to interact with the CP nodes to control and monitor the status of the entire Kong Gateway cluster.

DB-less mode

The third and final Kong Gateway Deployment Topology available is DB-less mode There is no database because all of the configuration is done declaratively in a YAML, and the application runs ephemerally (with no persistent storage). 

This of course comes with the following downsides:

  • The Admin API is read only.
  • Any plugin that stores information in the database, like rate limiting (cluster mode), doesn’t fully function.

But there is upsides as well:

  • Reduced number of dependencies: no need to manage a database installation if the entire setup for your use case fits in memory.
  • Your configuration is always in a known state. There is no intermediate state between creating a Service and a Route using the Admin API.
  • DB-less mode is a good fit for automation in CI/CD scenarios. Configuration for entities can be kept in a single source of truth managed via a Git repository.

Note that this time the YAML has no database, and hence no iam-migrations either. 

 
Spoiler (DB-less)

And of course we would need the declarative configuration of Kong. See an example YAML of this below.

 
Spoiler (kong.yml)

To summarize, there are three deployment topologies you can use for IAM to achieve HA, each with its advantages and disadvantages. I encourage you to check out the attached Open Exchange Application which takes you through deploying these topologies one by one. 

Comentarios (0)1
Inicie sesión o regístrese para continuar
Pregunta
· 21 hr atrás

The Essential Hoodie for All-Day Comfort and Effortless Style

When it comes to wardrobe staples, few items are as universally loved and versatile as the hoodie. Whether you're lounging at home, heading out for a casual errand, or layering up for colder weather, the hoodie has proven itself to be more than just a simple garment. It has become an essential piece of clothing for people of all ages and lifestyles. In this blog, we’ll delve into why the hoodie is an irreplaceable part of modern fashion, its evolution, and how to style it for all-day comfort and effortless chic.

A History of the Hoodie: From Practicality to Iconic Fashion

The hoodie has humble beginnings that date back to the 1930s, initially designed for practicality rather than style. The first hoodie was created by a clothing manufacturer called Champion for workers in cold warehouses.Essential Hoodie The intention was to provide a functional, warm, and comfortable garment that protected workers from the elements without sacrificing mobility. This utilitarian purpose was soon realized by athletes, particularly in American football, who began wearing them for warm-ups and training.

However, the hoodie’s journey didn’t stop there. By the 1970s, the hoodie was embraced by streetwear culture, particularly in the urban areas of New York City. Hip-hop artists, skaters, and various subcultures adopted the hoodie as a symbol of rebellion, anonymity, and coolness. The hoodie became synonymous with countercultures, giving it a mystique and edge that it still carries today. As it gained popularity, high fashion designers started incorporating it into their collections, further solidifying its place in mainstream fashion.

The Comfort Factor: Why Hoodies Are Perfect for All-Day Wear

One of the key reasons the hoodie continues to be a favorite item for everyday wear is its unparalleled comfort. Made from soft, breathable materials such as cotton, fleece, or blended fabrics, a good hoodie offers warmth without being overly heavy. It’s perfect for layering during cooler months or wearing alone during milder weather. The addition of a hood provides extra warmth for your head and neck, making it an ideal piece for those chilly mornings or evenings when you just want to stay cozy.

Unlike other garments, the hoodie offers a perfect balance between freedom of movement and snugness. The slightly relaxed fit ensures that you don’t feel constricted, yet it still offers a comforting embrace. This makes it an excellent choice for long hours of wear, whether you’re working from home, attending classes, or simply running errands. Plus, the presence of a front pocket, often referred to as a "kangaroo pocket," adds another level of practicality. You can easily stash your phone, keys, or hands in the pocket for extra warmth without needing to carry a bag.

Versatility: Dressing Up or Down

Another reason the hoodie has maintained its status in modern wardrobes is its versatility. A hoodie can be dressed up or down to suit almost any occasion, making it an excellent addition to your collection of essentials.

Casual Comfort

For a laid-back, casual look, hoodies pair seamlessly with jeans, leggings, or joggers. The simple combination of a hoodie and your favorite pair of sneakers will keep you comfortable and stylish whether you're running errands, catching up with friends, or enjoying a day off. With the right accessories, such as a sleek backpack, a cap, or some minimal jewelry, you can elevate the look without sacrificing comfort.

Layering for Style

Hoodies are also fantastic for layering, allowing you to create a more put-together look while still staying cozy. Consider pairing your hoodie with a stylish jacket, like a denim or bomber jacket, for a relaxed yet fashionable vibe. Alternatively, you can layer it under a trench coat or a tailored blazer to add an element of sophistication. The contrast between the sporty vibe of the hoodie and the elegance of a tailored piece creates an interesting, fashionable tension that works well for both casual and semi-formal settings.

The Athleisure Look

The rise of athleisure—a trend that combines athletic wear with casual or even formal pieces—has further cemented the hoodie’s place in fashion. You can wear a hoodie with sleek, form-fitting leggings and a pair of trainers to create an effortlessly stylish look that’s perfect for a workout, a quick coffee run, or simply lounging around. The athleisure look is all about blending comfort with fashion, and the hoodie is an essential part of this trend. With the addition of a stylish pair of sunglasses or a bold crossbody bag, you can take the hoodie from casual to chic in an instant.

Streetwear Influence

Hoodies have a long-standing connection to streetwear culture, and many of the world’s top fashion brands, such as Supreme, Off-White, and Balenciaga, have made the hoodie an essential part of their collections. Streetwear outfits often consist of oversized hoodies, paired with statement sneakers, bucket hats, and accessories that contribute to the overall cool and edgy vibe. The hoodie, in this context, becomes more than just a comfortable garment—it’s a statement piece that adds authenticity and edge to the wearer’s style.

Choosing the Right Hoodie: Quality and Fit Matter

Not all hoodies are created equal, and when it comes to comfort and style, quality and fit are paramount. While it’s tempting to pick up a hoodie for a bargain, investing in a high-quality hoodie can make a significant difference in both durability and comfort. Look for hoodies made from premium cotton or blended fabrics like organic cotton or bamboo for added breathability and softness. A high-quality hoodie will maintain its shape and feel good against your skin even after multiple washes.

Fit is another important factor to consider when purchasing a hoodie. While oversized hoodies have their place in fashion, you may want to opt for a more tailored fit if you prefer something that looks more polished and structured. The right fit should allow for ease of movement while still feeling comfortable. Pay attention to the sleeve length, shoulder seams, and overall length of the hoodie to ensure it complements your body type.

Sustainable Hoodies: Eco-Friendly Choices

As sustainability becomes an increasingly important factor in fashion, many clothing brands are opting to create eco-friendly hoodies made from recycled materials, organic cotton, or sustainable fabrics. These hoodies not only contribute to reducing environmental impact but often offer the same level of comfort and style as their conventional counterparts.

When shopping for a sustainable hoodie, consider looking for certifications such as GOTS (Global Organic Textile Standard) or OEKO-TEX, which guarantee that the materials used are eco-friendly and safe for the environment. Sustainable hoodies are available in various styles and colors, ensuring that you don’t have to compromise on fashion while making a more responsible choice.

The Hoodie in Popular Culture

The hoodie has been a constant presence in popular culture, further solidifying its status as an iconic piece of clothing. Celebrities, musicians, and athletes have all embraced the hoodie as a symbol of casual chic.  Essentials Sweatpants   From Kanye West’s Yeezy collection to Rihanna’s Fenty line, high-end designers have put their own spin on the classic hoodie, turning it into a statement piece that’s equally at home on the runway as it is on the streets.

Additionally, the hoodie has been featured in numerous movies and TV shows, often associated with characters who embody coolness, independence, or rebellion. Think of characters like Jason Bourne or The Fresh Prince of Bel-Air—both icons in their own right, whose hoodie-wearing personas have become ingrained in our collective pop culture consciousness.

Conclusion: The Hoodie’s Enduring Appeal

The hoodie is a fashion staple that has stood the test of time for good reason. It combines practicality, comfort, and versatility in a way that few other garments can. Whether you’re lounging at home, layering it for a chic look, or embracing it as part of streetwear culture, the hoodie’s enduring appeal lies in its ability to be both functional and fashionable. It’s a garment that can be worn by anyone, anywhere, and still look effortlessly cool. In a world where comfort is key and style is a priority, the hoodie will always be an essential part of the modern wardrobe.

So, next time you pull on your favorite hoodie, know that you're not just wearing a piece of clothing; you’re participating in a cultural phenomenon that has evolved into a symbol of effortless style and all-day comfort.

Comentarios (0)1
Inicie sesión o regístrese para continuar
Pregunta
· 22 hr atrás

cake boxes

Looking for cake boxes that really stand out? Hi Custom Boxes’ range delivers—whether you need tall boxes for celebratory layer cakes or cute, individual-sized ones for cupcakes. With custom shapes, eco-friendly materials, and finishes like matte, gloss, or kraft, they make packaging that protects the treat and enhances your brand. Perfect for bakeries, events, or even home bakers who want their cakes to arrive looking as good as they taste.

Comentarios (0)1
Inicie sesión o regístrese para continuar
Artículo
· 22 hr atrás Lectura de 4 min

Run Your AI Agent with InterSystems IRIS and Local Models using Ollama

In the previous article, we saw how to build a customer service AI agent with smolagents and InterSystems IRIS, combining SQL, RAG with vector search, and interoperability.

In that case, we used cloud models (OpenAI) for the LLM and embeddings.

This time, we’ll take it one step further: running the same agent, but with local models thanks to Ollama.

Comentarios (0)1
Inicie sesión o regístrese para continuar
Artículo
· 23 hr atrás Lectura de 18 min
Comentarios (0)0
Inicie sesión o regístrese para continuar