<commit_before>(ns 
 #^{:author "<NAME>" :doc "Demo Server for DADA"}
 org.dada.demo.server
 (:use
  [org.dada web]
  [org.dada core])
 (:import
  [java.util.concurrent
   Executors
   ExecutorService]
  [javax.jms
   ConnectionFactory]
  [org.springframework.context.support
   ClassPathXmlApplicationContext]
  [org.springframework.beans.factory
   BeanFactory]
  [org.dada.core
   SessionManager
   SessionManagerNameGetter
   SessionManagerImpl
   View
   ViewNameGetter]
  [org.dada.jms
   MessageStrategy
   BytesMessageStrategy
   SerializeTranslator
   Translator
   ServiceFactory
   JMSServiceFactory]
  [org.springframework.beans.factory
   BeanFactory])
 )

(if (not *compile-files*)
  (do
    (let [^ConnectionFactory connection-factory (.getBean #^BeanFactory (ClassPathXmlApplicationContext. "server.xml") "connectionFactory")
	  ^javax.jms.Connection connection (doto (.createConnection connection-factory) (.start))
	  ^javax.jms.Session jms-session (.createSession connection false (javax.jms.Session/DUPS_OK_ACKNOWLEDGE))
	  num-threads 16		;TODO - hardwired
	  timeout 10000			;TODO - hardwired
	  ^ExecutorService thread (Executors/newFixedThreadPool num-threads)
	  ^MessageStrategy strategy (BytesMessageStrategy.)
	  ^Translator translator (SerializeTranslator.)
	  ^ServiceFactory service-factory (JMSServiceFactory. jms-session thread strategy translator timeout)]
      (def ^SessionManager session-manager (SessionManagerImpl. "SessionManager.POJO" service-factory *metamodel*)))

    ;; move this into SessionManagerImpl
    (def jetty (start-jetty 8888))
    ))<commit_msg>fix typo<commit_after>(ns 
 #^{:author "<NAME>" :doc "Demo Server for DADA"}
 org.dada.demo.server
 (:use
  [org.dada web]
  [org.dada core])
 (:import
  [java.util.concurrent
   Executors
   ExecutorService]
  [javax.jms
   ConnectionFactory]
  [org.springframework.context.support
   ClassPathXmlApplicationContext]
  [org.springframework.beans.factory
   BeanFactory]
  [org.dada.core
   SessionManager
   SessionManagerNameGetter
   SessionManagerImpl
   View
   ViewNameGetter]
  [org.dada.jms
   MessageStrategy
   BytesMessageStrategy
   SerializeTranslator
   Translator
   ServiceFactory
   JMSServiceFactory]
  [org.springframework.beans.factory
   BeanFactory])
 )

(if (not *compile-files*)
  (do
    (let [^ConnectionFactory connection-factory (.getBean #^BeanFactory (ClassPathXmlApplicationContext. "server.xml") "connectionFactory")
	  ^javax.jms.Connection connection (doto (.createConnection connection-factory) (.start))
	  ^javax.jms.Session jms-session (.createSession connection false (javax.jms.Session/DUPS_OK_ACKNOWLEDGE))
	  num-threads 16		;TODO - hardwired
	  timeout 10000			;TODO - hardwired
	  ^ExecutorService threads (Executors/newFixedThreadPool num-threads)
	  ^MessageStrategy strategy (BytesMessageStrategy.)
	  ^Translator translator (SerializeTranslator.)
	  ^ServiceFactory service-factory (JMSServiceFactory. jms-session threads strategy translator timeout)]
      (def ^SessionManager session-manager (SessionManagerImpl. "SessionManager.POJO" service-factory *metamodel*)))

    ;; move this into SessionManagerImpl
    (def jetty (start-jetty 8888))
    ))
{'fraction_non_alphanumeric': 0.09865750858570091, 'fraction_numerical': 0.006868560724320949, 'mean_word_length': 4.524137931034483, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3743702', 'n_tokens_mistral': 1027, 'n_tokens_neox': 956, 'n_words': 209}