Commit Graph

330 Commits

Author SHA1 Message Date
Joris Vink e3ae1b4e2d Implement some great SPDY improvements.
* Bump spdy announcement to the correct draft version
* When receiving a RST, clean out the netbuf chain of that stream
2014-08-07 10:22:54 +02:00
Joris Vink 966ed3d20d Rename the two functions used to read/set headers.
Rename http_request_header_get() to http_request_header().
Rename http_response_header_add() to http_response_header().
2014-08-05 14:26:31 +02:00
Joris Vink 0413de6a8f fatal if the return value from a page handler isn't what we want. 2014-08-05 14:17:23 +02:00
Joris Vink b27322933b The default pid file is kore.pid so no need to set that explicitely 2014-08-05 13:11:53 +02:00
Joris Vink 577462379d Deprecate ssl_no_compression config option, its always on. 2014-08-05 13:07:32 +02:00
Joris Vink b0700162c4 Make http_post_data_bytes() and http_post_data_text() available 2014-08-04 21:03:26 +02:00
Joris Vink 9b3ff7db53 Lowercase the HTTP headers sent in normal HTTP responses.
SPDY already had this, as required by the spec.
2014-08-04 20:12:31 +02:00
Joris Vink 4010bdd58d Remove kore_cb and its related settings.
After revisiting why this exists in Kore I decided it
does not belong in this platform and instead of letting
it sit there staring at me I rather just kill it.
2014-08-04 19:54:32 +02:00
Joris Vink 0b36877736 Change kore_buf_appendv() to use vasprintf(). 2014-08-04 18:59:59 +02:00
Joris Vink 7b9b1d5c2c sprinkle more const chars 2014-08-04 12:40:21 +02:00
Joris Vink 31eac77cd2 sprinkle const char where appropriate 2014-08-04 09:48:41 +02:00
Joris Vink d39246e0e2 static.h -> assets.h 2014-08-03 18:22:12 +02:00
Joris Vink 3bb77bbb9f Even if we skip files to be built, they still gotta be linked in 2014-08-03 18:18:48 +02:00
Joris Vink e906aab445 Be careful that f isn't uninitialized 2014-08-03 17:50:04 +02:00
Joris Vink f4f8b1e8b0 Allow users to set ldflags via KORE_LDFLAGS 2014-08-03 17:44:29 +02:00
Joris Vink 2b40672ba1 When compiling with PGSQL, note the include dir for "kore build" 2014-08-03 17:33:40 +02:00
Joris Vink 73b0569fe0 Missing fclose() 2014-08-03 17:17:11 +02:00
Joris Vink 8bcfb6cbb3 Be consistent with the help text 2014-08-03 17:11:02 +02:00
Joris Vink 93fd33e00e Big changes to how we handle "static" files.
* Rename static files to assets
* static_* has become asset_*
* Always generate asset.h with the right external symbols
2014-08-03 16:55:16 +02:00
Joris Vink 380b7dc1d7 Improvement on the cli commands a bit.
* kore build will now only rebuild what was changed (checking on
  last modified timestamp, not 100% accurate but it'll do).

* introduce kore clean which cleans out object files and the
  resulting .so file
2014-08-03 16:36:16 +02:00
Joris Vink e74921222c Check if conf/appl.conf exists before continuing with build or run 2014-08-03 15:30:53 +02:00
Joris Vink f538e92172 Correct typo 2014-08-03 15:22:08 +02:00
Joris Vink 0e2f478c75 Fix http_argument_get_*() integer functions. 2014-08-03 15:20:20 +02:00
Joris Vink a2897f790c Better sane defaults for kore build (gen certs + ssl_no_compression) 2014-08-03 15:17:03 +02:00
Joris Vink 5b8c880a62 Don't write the static output to a tmp buf, just write it to disk 2014-08-01 20:25:02 +02:00
Joris Vink 6495e84005 Show the uri to the running kore instance in foreground mode 2014-08-01 20:00:09 +02:00
Joris Vink 23164f636f Sprinkle KORE_BENCHMARK through cli.c 2014-08-01 17:17:34 +02:00
Joris Vink 38edc7d23b Add a warning about the generated certificates 2014-08-01 17:13:38 +02:00
Joris Vink 47ad4fbc28 Have "kore build" generate temp certs as well 2014-08-01 17:10:47 +02:00
Joris Vink 448f1a7912 Don't run cli_cleanup_files() in cli_fatal if theres no rootdir 2014-08-01 16:39:12 +02:00
Joris Vink 5fa964c5c0 gettimeofday() requires sys/time.h 2014-08-01 16:10:37 +02:00
Joris Vink 67c3bd84ba Make cli compile under freebsd 2014-08-01 16:01:33 +02:00
Joris Vink e29a5461ca Allow kore build to compile static files 2014-08-01 15:55:09 +02:00
Joris Vink 61f56b8da0 Bump copyright 2014-08-01 14:14:46 +02:00
Joris Vink 5d8c29af13 Allow kore build to take compiler via KORE_COMPILER 2014-08-01 14:09:57 +02:00
Joris Vink ea5b89d20b Move orbit functionality into kore directly.
Makes more sense and reads easier:

kore create myapp
kore build myapp
kore run myapp

Note that kore retains its cli options (if no command was given),
meaning you can still start kore in the traditional way as well.

The command options are simply to make development easier.
2014-08-01 13:59:47 +02:00
Joris Vink 818dd84acd No longer generate .objs as a default for orbit create. 2014-08-01 12:45:31 +02:00
Joris Vink e57a91a4e0 Create .objs when doing orbit build if it doesnt exist 2014-08-01 12:40:37 +02:00
Joris Vink 0c21c08b6d Hook orbit into the build 2014-08-01 10:46:50 +02:00
Joris Vink a2a87adf19 Euhm, revert last commit. 2014-08-01 10:33:26 +02:00
Joris Vink cee7d34020 Properly check for EWOULDBLOCK as well 2014-08-01 10:32:31 +02:00
Joris Vink c2e4d55235 Add a BENCHMARK compile option which compiles without OpenSSL.
Personally use this for testing Kore its performance without
letting the OpenSSL stack get in the way too much.

Note that it leaves data structures as is, and just removes
any calls to OpenSSL (and removes the linking vs OpenSSL).
2014-08-01 10:22:32 +02:00
Joris Vink 8ff870a352 Remove the ability to pass libs on the cli again.
Sorry, this no longer makes sense in terms of what
orbit is suppose to be doing.
2014-08-01 09:39:09 +02:00
Joris Vink d6f0b8f8fe Start kore from inside the rootdir when doing orbit run 2014-08-01 09:05:14 +02:00
Joris Vink 65a28e3db3 Allow orbit to build things under OSX 2014-07-31 23:19:18 +02:00
Joris Vink 7a038fce91 Add initial orbit code.
Orbit is a tool used to create/build/run kore code
in a more straight forward way.

Right now, orbit can do the following:

orbit create myapp
orbit build myapp
orbit run myapp

All in the motivation of making it easier to get
started with building Kore libraries and making
life easier on the people hacking Kore things.
2014-07-31 23:12:14 +02:00
Joris Vink b17eefde1f Allow developers to pass the lib to load on the cli.
When running in -f (foreground) you can now specify
the library Kore needs to load on the command line:

kore -fnc module.conf myapp.so

This has the benefit that your configuration file no
longer needs the load directive when hacking on your code.

Note that you can still specify load in your config file
regardless, if you so chose.

All of this is being done in order to try and move away
from the backwards way of getting up and running with Kore.
2014-07-31 17:15:51 +02:00
Joris Vink 105fb272a0 In foreground mode don't show kore_log() in fatal 2014-07-31 15:12:05 +02:00
Joris Vink 20e2447c90 When running Kore in foreground mode, log to stdout 2014-07-31 14:26:51 +02:00
Joris Vink ef49a0d4e1 Don't use pidfile if we're in foreground mode 2014-07-31 14:02:33 +02:00