Baike.dev
All toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
O

obsidian

> 后端框架
Open source

GraphQL, built for Deno - a native GraphQL caching client and server module

765 stars0 likes0 views
WebsiteGitHub

About

GraphQL, built for Deno - a native GraphQL caching client and server module

Features

  • (New!) Support for W-TinyLFU client-side cache that brings great hit-ratio performance with minimal memory overhead
  • (New!) Option to provide Obsidian with the search types your application uses, allowing data cached from complete dataset pulls to be accessible later on in searches for individual items
  • (New!) Refactored server-side caching with Redis
  • (New!) Rebuilt developer tool for Obsidian 8.0 for testing and analytics related to the new client caching options
  • (New!) Option for persistent queries, allowing only a smaller hash to be sent to the server on client-side cache misses, minimizing the cost of queries. Note that while this will increase the overall performance for frequent, repeat queries.
  • Flexible cache responds only with data requested from selected fields
  • GraphQL query abstraction and caching improving the performance of your app
  • SSR React wrapper, allowing you to cache in browser
  • Configurable caching options, giving you complete control over your cache
  • Fullstack integration, leveraging client-side and server-side caching to streamline your caching strategy
  • Support for the full GraphQL convention
  • Support for client-side and server-side cache invalidation
  • Optional GraphQL DoS attack mitigation security module

Overview

Obsidian is Deno's first native GraphQL caching client and server module. Boasting lightning-fast caching and fetching capabilities alongside headlining normalization and rebuilding strategies, Obsidian is equipped to support scalable, highly performant applications.

With additional support for use in server-side rendered React apps built with Deno, full stack integration of Obsidian enables a fast and flexible caching solution.

Installation

Creating the Router

…

Selecting options for the Router

…

Creating the Wrapper

import { ObsidianWrapper } from 'https://deno.land/x/obsidian/clientMod.ts';

const App = () => {
  return (
    
      
    
  );
};

Selecting options for the Wrapper


  

Making a Query

import { useObsidian } from 'https://deno.land/x/obsidian/clientMod.ts';

const MovieApp = () => {
  const { query } = useObsidian();
  const [movies, setMovies] = (React as any).useState('');

  const queryStr = `query {
      movies {
        id
        title
        releaseYear
        genre
      }
    }
  `;

  return (
    
{movies}

     {
        query(queryStr)
        .then(resp => setMovies(resp.data))
      }}
    >Get Movies
  );
};

Making a Mutation

import { useObsidian } from 'https://deno.land/x/obsidian/clientMod.ts';

const MovieApp = () => {
  const { mutate } = useObsidian();
  const [movies, setMovies] = (React as any).useState('');

  const queryStr = `mutation {
    addMovie(input: {title: "Cruel Intentions", releaseYear: 1999, genre: "DRAMA" }) {
      id
      title
      releaseYear
      genre
    }
  }
  `;

  return (
    
{movies}

     {
        mutate(queryStr)
        .then(resp => setMovies(resp.data))
      }}
    >Get Movies
  );
}

Setting up Redis

In order to utilize server side caching, a Redis instance must be available and running. Redis installation and quick-start documentation can be found here. Make sure to keep a redis instance running whenever the application is utilizing server side caching to avoid running into issues.

To connect Obsidian to Redis, create a .env file in the root directory of the application with the following information:

REDIS_HOST= //string of redis host name, typically defaulted to '127.0.0.1' by Redis

Be sure to also specify the Redis TCP port by passing in the port number as an argument into Obsidian Router (see Selecting options for the Router above).

Documentation

getobsidian.io

Developer Tool

Information and instructions on how to use our developer tool can be found here

works with Obsidian 8.0

open-source-labs/obsidian-developer-tool

Obsidian 8.0 Demo

Github for a demo with some example code to play with:

oslabs-beta/obsidian-demo-8.0

Features In Progress

  • Server-side caching improvements
  • More comprehensive mutation support
  • searchTerms option optimization
  • Ability to store/read only the whole query
  • Hill Climber optimization for W-TinyLFU cache size allocation
  • Developer Tool server-side cache integration
  • Developer Tool View Cache component, and Playground component

Authors

David Kim
David Norman
Eileen Cho
Joan Manto
Alex Lopez
Kevin Huang
Matthew Weisker
Ryan Ranjbaran
Derek Okuno
Liam Johnson
Josh Reed
Jonathan Fangon
Liam Jeon
Yurii Shchyrba
Linda Zhao
Ali Fay
Anthony Guan
Yasir Choudhury
Yogi Paturu
Michael Chin
Dana Flury
Sardor Akhmedov
Christopher Berry
Olivia Yeghiazarian
Michael Melville
John Wong
Kyung Lee
Justin McKay
Patrick Sullivan
Cameron Simmons
Raymond Ahn
Alonso Garza
Burak Caliskan
Matt Meigs
Travis Frank
Lourent Flores
Esma Sahraoui
Derek Miller
Eric Marcatoma
Spencer Stockton

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

TypeScriptdenographqljavascripttypescript

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category后端框架
PricingOpen source

> Related tools

N
Node.js
基于 V8 的 JavaScript 运行时
D
Django
Python 高级 Web 框架
S
Spring Boot
Java 生态主流微服务框架