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

the auto_publish config not work #1502

Closed
ljh2057 opened this issue Sep 5, 2024 · 1 comment
Closed

the auto_publish config not work #1502

ljh2057 opened this issue Sep 5, 2024 · 1 comment

Comments

@ljh2057
Copy link

ljh2057 commented Sep 5, 2024

this is my config

auto_publish:
    from_schemas:
      - public
    functions:
      source_id_format: '{schema}.{function}'

then i create a function

CREATE OR REPLACE
    FUNCTION f_agp(z integer, x integer, y integer)
    RETURNS bytea AS $$
DECLARE
  mvt bytea;
BEGIN
  SELECT INTO mvt ST_AsMVT(tile, 'f_agp', 4096, 'geom') FROM (
    SELECT
      ST_AsMVTGeom(
          ST_Transform(geometry, 3857),
          ST_TileEnvelope(z, x, y),
          4096, 64, true) AS geom,name,class,gnid,xzname
    FROM pdc_agp
    WHERE geometry&& ST_Transform(ST_TileEnvelope(z, x, y), 4490)
  ) as tile WHERE geom IS NOT NULL;
  RETURN mvt;
END
$$ LANGUAGE plpgsql IMMUTABLE STRICT PARALLEL SAFE;

However, i visit /catalog did not take effect

@ljh2057
Copy link
Author

ljh2057 commented Sep 5, 2024

Sorry, it's due to cache.

@ljh2057 ljh2057 closed this as completed Sep 5, 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

No branches or pull requests

1 participant