From f76fee63ed9cb3a30d3c0c092d860b1cb93a481b Mon Sep 17 00:00:00 2001
From: Gerard Smyth <gerard.smyth@gmail.com>
Date: Thu, 08 May 2014 13:09:30 -0400
Subject: [PATCH] Updated the SyndicationServlet to provide an additional option to return details of the tags in the repository instead of the commits. This uses a new 'ot' request parameter to indicate the object type of the content to return, which can be ither TAG or COMMIT. If this is not provided, then COMMIT is assumed to maintain backwards compatability. If tags are returned, then the paging parameters, 'l' and 'pg' are still supported, but searching options are currently ignored.

---
 src/main/java/com/gitblit/fanout/FanoutSocketService.java |   26 +++++++++++++-------------
 1 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/src/main/java/com/gitblit/fanout/FanoutSocketService.java b/src/main/java/com/gitblit/fanout/FanoutSocketService.java
index 07c18f9..342b277 100644
--- a/src/main/java/com/gitblit/fanout/FanoutSocketService.java
+++ b/src/main/java/com/gitblit/fanout/FanoutSocketService.java
@@ -34,7 +34,7 @@
  * This implementation creates a master acceptor thread which accepts incoming
  * fanout connections and then spawns a daemon thread for each accepted connection.
  * If there are 100 concurrent fanout connections, there are 101 threads.
- *   
+ *
  * @author James Moger
  *
  */
@@ -50,10 +50,10 @@
 		pubsub.setAllowAllChannelAnnouncements(false);
 		pubsub.start();
 	}
-	
+
 	/**
 	 * Create a multi-threaded fanout service.
-	 * 
+	 *
 	 * @param port
 	 *            the port for running the fanout PubSub service
 	 * @throws IOException
@@ -64,7 +64,7 @@
 
 	/**
 	 * Create a multi-threaded fanout service.
-	 * 
+	 *
 	 * @param bindInterface
 	 *            the ip address to bind for the service, may be null
 	 * @param port
@@ -74,12 +74,12 @@
 	public FanoutSocketService(String bindInterface, int port) {
 		super(bindInterface, port, "Fanout socket service");
 	}
-	
+
 	@Override
 	protected boolean isConnected() {
 		return serviceSocket != null;
 	}
-		
+
 	@Override
 	protected boolean connect() {
 		if (serviceSocket == null) {
@@ -88,7 +88,7 @@
 				serviceSocket.setReuseAddress(true);
 				serviceSocket.setSoTimeout(serviceTimeout);
 				serviceSocket.bind(host == null ? new InetSocketAddress(port) : new InetSocketAddress(host, port));
-				logger.info(MessageFormat.format("{0} is ready on {1}:{2,number,0}", 
+				logger.info(MessageFormat.format("{0} is ready on {1}:{2,number,0}",
 						name, host == null ? "0.0.0.0" : host, serviceSocket.getLocalPort()));
 			} catch (IOException e) {
 				logger.error(MessageFormat.format("failed to open {0} on {1}:{2,number,0}",
@@ -140,17 +140,17 @@
 			// ignore accept timeout exceptions
 		}
 	}
-	
+
 	/**
 	 * FanoutSocketConnection handles reading/writing messages from a remote fanout
 	 * connection.
-	 * 
+	 *
 	 * @author James Moger
 	 *
 	 */
 	class FanoutSocketConnection extends FanoutServiceConnection implements Runnable {
 		Socket socket;
-		
+
 		FanoutSocketConnection(Socket socket) {
 			super(socket);
 			this.socket = socket;
@@ -205,7 +205,7 @@
 
 			logger.info(MessageFormat.format("thread for fanout connection {0} is finished", id));
 		}
-				
+
 		@Override
 		protected void reply(String content) throws IOException {
 			// synchronously send reply
@@ -218,7 +218,7 @@
 			}
 			os.flush();
 		}
-		
+
 		protected void closeConnection() {
 			// close the connection socket
 			try {
@@ -226,7 +226,7 @@
 			} catch (IOException e) {
 			}
 			socket = null;
-			
+
 			// remove this connection from the service
 			removeConnection(this);
 		}

--
Gitblit v1.9.1