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

Make Spark Serving Easier to Use #347

Open
3 of 5 tasks
mhamilton723 opened this issue Jul 17, 2018 · 0 comments
Open
3 of 5 tasks

Make Spark Serving Easier to Use #347

mhamilton723 opened this issue Jul 17, 2018 · 0 comments
Assignees

Comments

@mhamilton723
Copy link
Collaborator

mhamilton723 commented Jul 17, 2018

  • Add option to fail when it cannot parse the input
  • Add tests on ADB
  • Add syntactic sugars for adding input parsers
  • Add ability to reply with other types
  • Fix offsets commited out of order exception

Repro:

import mmlspark
from pyspark.sql.functions import length, col, lit, from_json
from pyspark.sql.types import *

df = spark.readStream.server() \
    .address("localhost", 8888, "my_api") \
    .load()

server = df.withColumn("reply", length(col("value"))) \
    .withColumn("replyString", col("reply").cast(StringType()))\
    .writeStream \
    .server() \
    .option("name", "my_api") \
    .queryName("my_query") \
    .option("replyCol", "replyString") \
    .option("checkpointLocation", "checkpoints") \
    .start()


import requests

r = requests.post(data="{foo:1}", url="http://localhost:8888/my_api")
print(r.text)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant